aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/quick/qquickmousearea/data
diff options
context:
space:
mode:
authorMichael Brasser <michael.brasser@live.com>2013-02-12 22:19:10 -0600
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-02-14 15:04:05 +0100
commitb324ee38a67c6e8529023f3f4e34be8af5f60166 (patch)
tree9b6e41ec7c7da4cb63613d3ade4faf3f8d081938 /tests/auto/quick/qquickmousearea/data
parente6aaaca5c1a5d01b8b0ef32abcb8ff6a39d81e3b (diff)
A MouseArea should not receive move or release events if the press was not accepted.
Change-Id: If70650d7150b224f4460697a953611dd37d57af1 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
Diffstat (limited to 'tests/auto/quick/qquickmousearea/data')
-rw-r--r--tests/auto/quick/qquickmousearea/data/moveAndReleaseWithoutPress.qml14
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/auto/quick/qquickmousearea/data/moveAndReleaseWithoutPress.qml b/tests/auto/quick/qquickmousearea/data/moveAndReleaseWithoutPress.qml
new file mode 100644
index 0000000000..6c68f0c7c8
--- /dev/null
+++ b/tests/auto/quick/qquickmousearea/data/moveAndReleaseWithoutPress.qml
@@ -0,0 +1,14 @@
+import QtQuick 2.0
+
+MouseArea {
+ width: 200
+ height: 200
+
+ property bool hadMove: false
+ property bool hadRelease: false
+
+ onPressed: mouse.accepted = false
+ onPositionChanged: hadMove = true
+ onReleased: hadRelease = true
+}
+