aboutsummaryrefslogtreecommitdiffstats
path: root/examples/declarative/snake/snake.qml
diff options
context:
space:
mode:
Diffstat (limited to 'examples/declarative/snake/snake.qml')
-rw-r--r--examples/declarative/snake/snake.qml4
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/declarative/snake/snake.qml b/examples/declarative/snake/snake.qml
index edccd4c9df..03657fec01 100644
--- a/examples/declarative/snake/snake.qml
+++ b/examples/declarative/snake/snake.qml
@@ -39,7 +39,7 @@
**
****************************************************************************/
-import QtQuick 1.0
+import QtQuick 2.0
import "content" as Content
import "content/snake.js" as Logic
@@ -76,7 +76,7 @@ Rectangle {
Timer {
id: heartbeat;
interval: heartbeatInterval;
- running: activeGame && runtime.isActiveWindow
+ running: activeGame && Qt.application.active
repeat: true
onTriggered: { Logic.move() }
}