Reputation: 711
I'm trying to implement animation with delay in android, but in my case the imageview is infinitely rotating, because i don't know how can i dynamically stop and start it.
final RotateAnimation anim = new RotateAnimation(0f, 350f, 15f, 15f);
anim.setInterpolator(new LinearInterpolator());
anim.setRepeatCount(Animation.INFINITE);
anim.setDuration(700);
imageView.startAnimation(anim);
Upvotes: 0
Views: 664
Reputation: 10323
Take a look at setRepeatCount arguments and setStartOffset method. First one allows you to limit repeated animation, second one - introduce a time delay.
Upvotes: 2