From 8673ae8bb6d4bac01cc54638a7d617072299a808 Mon Sep 17 00:00:00 2001 From: Martin Jones Date: Wed, 8 Jan 2014 17:04:35 +1000 Subject: Fix Flickable generated release event with pressDelay. Map mouse position to grabber when forwarding release event due to release before pressDelay timeout. Task-number: QTBUG-34570 Change-Id: I7214077c9ac95f77407cf66f9dad52f577eccd79 Reviewed-by: Matthew Vogt --- tests/auto/quick/qquickflickable/data/pressDelay.qml | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'tests/auto/quick/qquickflickable/data/pressDelay.qml') diff --git a/tests/auto/quick/qquickflickable/data/pressDelay.qml b/tests/auto/quick/qquickflickable/data/pressDelay.qml index 18a5840504..a69c4af6de 100644 --- a/tests/auto/quick/qquickflickable/data/pressDelay.qml +++ b/tests/auto/quick/qquickflickable/data/pressDelay.qml @@ -8,6 +8,11 @@ Flickable { contentHeight: 400 pressDelay: 100 + property real pressX + property real pressY + property real releaseX + property real releaseY + MouseArea { id: ma objectName: "mouseArea" @@ -16,6 +21,15 @@ Flickable { width: 240 height: 100 + onPressed: { + pressX = mouse.x + pressY = mouse.y + } + onReleased: { + releaseX = mouse.x + releaseY = mouse.y + } + Rectangle { anchors.fill: parent color: parent.pressed ? 'blue' : 'green' -- cgit v1.2.3