summaryrefslogtreecommitdiffstats
path: root/demos/declarative/snake/snake.qml
diff options
context:
space:
mode:
Diffstat (limited to 'demos/declarative/snake/snake.qml')
-rw-r--r--demos/declarative/snake/snake.qml12
1 files changed, 10 insertions, 2 deletions
diff --git a/demos/declarative/snake/snake.qml b/demos/declarative/snake/snake.qml
index 565e92c..46114f5 100644
--- a/demos/declarative/snake/snake.qml
+++ b/demos/declarative/snake/snake.qml
@@ -86,7 +86,7 @@ Rectangle {
onTriggered: { Logic.moveSkull() }
}
Timer {
-
+ id: startNewGameTimer;
interval: 700;
onTriggered: { Logic.startNewGame(); }
}
@@ -177,7 +177,6 @@ Rectangle {
id: progressIndicator
color: "#221edd";
width: 0;
- Behavior on width { NumberAnimation { duration: startHeartbeatTimer.running ? 1000 : 0}}
height: 30;
}
}
@@ -227,4 +226,13 @@ Rectangle {
}
]
+ transitions: [
+ Transition {
+ from: "*"
+ to: "starting"
+ NumberAnimation { target: progressIndicator; property: "width"; duration: 1000 }
+
+ }
+ ]
+
}