Do stuff after behavior with animation is finished in qml
-
Hi,
I have behavior on a property in qml and i want to do a stuff after the animation is done (is finished).
I have used Behaviour with states.
@
Behavior on height {
SmoothedAnimation{
duration: 250;
}
}@
How can i do that? -
@
Behavior on height {
SmoothedAnimation{
duration: 250;
onRunningChanged: {
if (!running) {
// your code here
}
}
}
}
@ -
Why so much JS?
@Behavior on height {
SequentialAnimation {
SmoothedAnimation { duration: 500 }
ScriptAction {
script: console.log("something changed")
}
}
} @
Also, take a look at PropertyAction type -
So much JS? Both your snippet and mine have exactly 1 line of JS code :P