mirror of
https://github.com/recloudstream/cloudstream.git
synced 2026-07-13 00:13:17 +00:00
Compare commits
2 commits
master
...
actor-clic
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
decc1a4178 |
||
|
|
ff6a125913 |
2 changed files with 23 additions and 1 deletions
|
|
@ -5,6 +5,9 @@ import android.content.Intent
|
|||
import android.view.LayoutInflater
|
||||
import android.view.View
|
||||
import android.view.ViewGroup
|
||||
import android.view.animation.Animation
|
||||
import android.view.animation.OvershootInterpolator
|
||||
import android.view.animation.ScaleAnimation
|
||||
import androidx.core.view.isVisible
|
||||
import com.lagradost.cloudstream3.ActorData
|
||||
import com.lagradost.cloudstream3.ActorRole
|
||||
|
|
@ -46,6 +49,24 @@ class ActorAdaptor(
|
|||
}
|
||||
}
|
||||
|
||||
override fun onUpdateContent(holder: ViewHolderState<Any>, item: ActorData, position: Int) {
|
||||
when (val binding = holder.view) {
|
||||
is CastItemBinding -> {
|
||||
val anim: Animation = ScaleAnimation(
|
||||
0.8f, 1f,
|
||||
0.8f, 1f,
|
||||
Animation.RELATIVE_TO_SELF, 0.5f,
|
||||
Animation.RELATIVE_TO_SELF, 0.5f
|
||||
)
|
||||
anim.fillAfter = true
|
||||
anim.duration = 200
|
||||
anim.interpolator = OvershootInterpolator()
|
||||
binding.voiceActorImageHolder2.startAnimation(anim)
|
||||
}
|
||||
}
|
||||
super.onUpdateContent(holder, item, position)
|
||||
}
|
||||
|
||||
override fun onBindContent(holder: ViewHolderState<Any>, item: ActorData, position: Int) {
|
||||
when (val binding = holder.view) {
|
||||
is CastItemBinding -> {
|
||||
|
|
|
|||
|
|
@ -47,6 +47,7 @@
|
|||
</androidx.cardview.widget.CardView>
|
||||
|
||||
<androidx.cardview.widget.CardView
|
||||
android:id="@+id/voice_actor_image_holder2"
|
||||
android:layout_width="70dp"
|
||||
android:layout_height="70dp"
|
||||
android:foreground="@drawable/outline_drawable"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue