1
0
mirror of https://gitlab.com/kelteseth/ScreenPlay.git synced 2024-09-15 06:52:34 +02:00

Fix background vars

This commit is contained in:
Elias 2018-12-04 18:27:19 +01:00
parent 062d6d6f71
commit 9a8f2334ea

View File

@ -7,13 +7,19 @@ Item {
id: element
anchors.fill: parent
state: "init"
onStateChanged: print(state)
onStateChanged: {
if (state === "init") {
colorShaderCreateTimer.stop()
} else {
colorShaderCreateTimer.start()
}
}
property var myDate: new Date()
Timer {
id: colorShaderCreateTimer
interval: 16
running: true
repeat: true
onTriggered: colorShaderCreate.time = myDate.getMilliseconds()
}
@ -50,25 +56,22 @@ Item {
Transition {
from: "init"
to: "create"
reversible: true
PropertyAnimation {
target: colorShaderCreateWrapper
target: colorShaderCreate
property: "shaderOpacity"
duration: 200
easing.type: Easing.InOutQuad
duration: 400
easing.type: Easing.OutQuart
}
},
Transition {
from: "create"
to: "*"
reversible: true
PropertyAnimation {
target: colorShaderCreateWrapper
target: colorShaderCreate
property: "shaderOpacity"
duration: 50
easing.type: Easing.InOutQuad
duration: 0
}
}
]