Implemented basic animation

This commit is contained in:
2023-02-26 23:10:21 +01:00
parent dcabe003a4
commit 922a96a34d

View File

@@ -45,5 +45,38 @@ Item {
}
}
}
CheckBox {
id: animationCheckbox
text: qsTr('Animation')
}
}
property int test0
onTest0Changed: __controller.setPresetSlider(7, test0);
property int test1
onTest1Changed: __controller.setPresetSlider(15, test1);
property int test2
onTest2Changed: __controller.setPresetSlider(9, test2);
property int test3
onTest3Changed: __controller.setPresetSlider(13, test3);
SequentialAnimation {
loops: Animation.Infinite
running: animationCheckbox.checked
ParallelAnimation {
NumberAnimation { target: homePage; property: "test0"; duration: 2000; from: 10; to: 255; easing.type: Easing.InQuad }
NumberAnimation { target: homePage; property: "test1"; duration: 2000; from: 255; to: 10; easing.type: Easing.InQuad } // blau
NumberAnimation { target: homePage; property: "test2"; duration: 2000; from: 255; to: 10; easing.type: Easing.InQuad } // blau
NumberAnimation { target: homePage; property: "test3"; duration: 2000; from: 10; to: 255; easing.type: Easing.InQuad }
}
PauseAnimation { duration: 1000 }
ParallelAnimation {
NumberAnimation { target: homePage; property: "test0"; duration: 2000; from: 255; to: 10; easing.type: Easing.InQuad }
NumberAnimation { target: homePage; property: "test1"; duration: 2000; from: 10; to: 255; easing.type: Easing.InQuad } // blau
NumberAnimation { target: homePage; property: "test2"; duration: 2000; from: 10; to: 255; easing.type: Easing.InQuad } // blau
NumberAnimation { target: homePage; property: "test3"; duration: 2000; from: 255; to: 10; easing.type: Easing.InQuad }
}
PauseAnimation { duration: 1000 }
}
}