Anyone have any idea why after animating, my butto...
# tornadofx
d
Anyone have any idea why after animating, my button jumps back to it's old prefWidth? Does animate not set the property at the end?
Copy code
action {
    if (this.text == "") {
        this.prefWidthProperty().animate(160.0, 500.millis, Interpolator.EASE_BOTH)
    } else {
        this.prefWidthProperty().animate(0.0, 500.millis, Interpolator.EASE_BOTH)
    }
    this.text = if (this.text == "") "Menu" else ""
 }