Skip to content
This repository has been archived by the owner on Oct 8, 2021. It is now read-only.

Stop animation #74

Open
wyzard opened this issue Jul 22, 2021 · 0 comments
Open

Stop animation #74

wyzard opened this issue Jul 22, 2021 · 0 comments

Comments

@wyzard
Copy link

wyzard commented Jul 22, 2021

Hello!

Thank you for this awesome lib. I have a (maybe dumb) question.
How can I stop a started (infinte) animation?

I temporarily found that if I set the repeatCount field to 0 the animation stops, but I don't know if this is the right solution.

var pulseAnimation = RichPathAnimator.animate(pathName)
	.interpolator(LinearInterpolator())
	.scale(1f, 2f)
	.fillColor(0xFF00A951.toInt(), 0x0000A951)
	.repeatMode(RichPathAnimator.RESTART)
	.repeatCount(RichPathAnimator.INFINITE)
	.duration(1500)

pulseAnimation?.start()

Thank you for your help.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant