android - Card flip animation on PopupWindow or DialogFragment -


I am trying to implement card flip animation inside PopupWindow on ViewGroup. I am using AnimatorSet to apply the animation to ViewGroup . Animation is happening within window boundaries and clipping the window segment going out of the window. Any suggestions to avoid clipping?

I have a solution, but other solutions are welcome :)

I The properties of scalX and scalY are used by objectAnimator . When the animation starts, I give the window 0.9 to 0.5 for the half of the animation time. And frames between 0.5 and 0.9 for the remaining animation time again. As the size of the window diminishes, the window border is fully fit within the clipping area during animation. This solved my problem from card_flip_right_out.xml to

ObjectAnimator android Android: ValueTrom = "0.9" Android: valueTo = "0.5"> / Code> & nbsp; objectAnimator android: duration = "199" Android: propertyName = "

ScaleY" Android: valueFrom = " 0.5 "Android: valueTo =" 0.9 "& gt; ObjectAnimator & gt; ObjectAnimator android: Period =" 199 "Android: propertyName =" scaleX "Android: valueFrom =" 0.5 "Android: value To = "0.9" & gt; ObjectAnimator & gt; ObjectAnimator android: Period = "1" Android: propertyName = "scaleY" Android: startoffset = "199" Android: valueTo = "1" & gt; ; / ObjectAnimator & gt; ObjectAnimator android: Period = "1" Android: propertyName = "scaleX" Android: startoffset = "199" Android: valueTo = "1" & gt;


Comments