aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/quick/qquickmousearea/data/preventStealingListViewChild.qml
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/quick/qquickmousearea/data/preventStealingListViewChild.qml')
-rw-r--r--tests/auto/quick/qquickmousearea/data/preventStealingListViewChild.qml31
1 files changed, 31 insertions, 0 deletions
diff --git a/tests/auto/quick/qquickmousearea/data/preventStealingListViewChild.qml b/tests/auto/quick/qquickmousearea/data/preventStealingListViewChild.qml
new file mode 100644
index 0000000000..3833c5a8a9
--- /dev/null
+++ b/tests/auto/quick/qquickmousearea/data/preventStealingListViewChild.qml
@@ -0,0 +1,31 @@
+import QtQuick 2.15
+
+ListView {
+ id: flick
+ width: 640
+ height: 480
+ model: 100
+
+ delegate: Rectangle {
+ border.color: "#81e889"
+ width: 640; height: 100
+ Text { text: "Row " + index }
+ }
+
+ Rectangle {
+ anchors.right: parent.right
+ anchors.margins: 2
+ color: ma.pressed ? "#81e889" : "#c2f4c6"
+ width: 50; height: 50
+ radius: 5
+ MouseArea {
+ id: ma
+ anchors.fill: parent
+ preventStealing: true
+ drag {
+ target: parent
+ axis: Drag.YAxis
+ }
+ }
+ }
+}