Closed averroes96 closed 4 years ago
Hi, you can use this function : setResetOnFinished(true)
.
It will reset the node position when it's finished or when you call stop()
I basically tried this one earlier, just after instanciating the animation :
AnimateFX animField = new Shake(field);
animField.setResetOnFinished(true)
Still didn't work.
Description
I'm trying to animate a field using methods
onKeyPressed
,onKeyTyped
andonKeyReleased
so that whenever the entered value is invalid or wrongly typed, it basically starts an animation indicating that you're making an error, but once the entered value is valid i basically call thestop
method to end the animation but sometimes it stops the field in a different position than the his initial postion. i looked if there's another method that do reset the field to its initial postion but found none.