aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/quick/qquickanimatedimage/data/currentframe.qml
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/quick/qquickanimatedimage/data/currentframe.qml')
-rw-r--r--tests/auto/quick/qquickanimatedimage/data/currentframe.qml13
1 files changed, 13 insertions, 0 deletions
diff --git a/tests/auto/quick/qquickanimatedimage/data/currentframe.qml b/tests/auto/quick/qquickanimatedimage/data/currentframe.qml
new file mode 100644
index 0000000000..b679da2a99
--- /dev/null
+++ b/tests/auto/quick/qquickanimatedimage/data/currentframe.qml
@@ -0,0 +1,13 @@
+import QtQuick 2.0
+
+AnimatedImage {
+ property int currentFrameChangeCount: 0
+ property int frameChangeCount: 0
+ source: "stickman.gif"
+ onCurrentFrameChanged: if (currentFrame > 0) ++currentFrameChangeCount;
+ onFrameChanged: if (currentFrame > 0) ++frameChangeCount;
+ function scriptedSetCurrentFrame(frame) {
+ currentFrame = frame;
+ }
+}
+