Animations can be cycled, but while the animation is cycling, there is no way to know when a cycle is complete so that you can do something at that time.
There is an existing onFinished callback for animations, but that is only triggered when the animation finishes playing (i.e. after all cycles have completed).
If there was an onCycleFinished callback, then the callback could be invoked allowing you to take action at the time.
An example usage would be a PauseTransition on an infinite cycle which could trigger a metronome tick at the end of each cycle.
There is an existing onFinished callback for animations, but that is only triggered when the animation finishes playing (i.e. after all cycles have completed).
If there was an onCycleFinished callback, then the callback could be invoked allowing you to take action at the time.
An example usage would be a PauseTransition on an infinite cycle which could trigger a metronome tick at the end of each cycle.
- duplicates
-
JDK-8092408 Animation needs more events
- Open