AndroidViewAnimations icon indicating copy to clipboard operation
AndroidViewAnimations copied to clipboard

Help to stop annimation

Open AskMeCode opened this issue 6 years ago • 3 comments

Hello all how i can stop animation please:

YoYo.with(animationView).duration(1000).repeat(100).withListener(new Animator.AnimatorListener() { @Override public void onAnimationStart(Animator animation) { } @Override public void onAnimationEnd(Animator animation) { } @Override public void onAnimationCancel(Animator animation) { } @Override public void onAnimationRepeat(Animator animation) { } }).playOn(view);

AskMeCode avatar Jun 19 '18 15:06 AskMeCode

Assign it to a YoYoString variable. YoYo.YoYoString yoyoString = YoYo.with(animationView) .duration(1000) .repeat(100) .withListener(so on).playOn(view); then later on your code you can call yoyoString.stop().

KieuQ avatar Jul 18 '18 07:07 KieuQ

@KieuQ YoYo.YoYoString yoyoString = YoYo.with(Techniques.Tada).duration(1000).repeat(-1).playOn(mBox);

yoyoString.stop() no stop.

giantss avatar Oct 29 '19 03:10 giantss

assigning animation to yoyoString prevents the animation from starting.

Peterragheb avatar Jun 24 '20 14:06 Peterragheb