diff options
-rw-r--r-- | tests/auto/quick/touchmouse/data/mouseonflickableonpinch.qml | 27 | ||||
-rw-r--r-- | tests/auto/quick/touchmouse/data/pinchonflickable.qml | 8 |
2 files changed, 21 insertions, 14 deletions
diff --git a/tests/auto/quick/touchmouse/data/mouseonflickableonpinch.qml b/tests/auto/quick/touchmouse/data/mouseonflickableonpinch.qml index 015391f291..0cb67cf62c 100644 --- a/tests/auto/quick/touchmouse/data/mouseonflickableonpinch.qml +++ b/tests/auto/quick/touchmouse/data/mouseonflickableonpinch.qml @@ -1,11 +1,9 @@ import QtQuick 2.0 -import Qt.test 1.0 Rectangle { id: root width: 600 height: 600 - color: "green" PinchArea { objectName: "pincharea" @@ -23,25 +21,34 @@ Rectangle { MouseArea { anchors.fill: parent - onClicked: { - if (rect.color == "#000000") - rect.color = "#00ff00" - else - rect.color = "#000000" + property int nextTimestamp: 0 + Component { + id: clickFeeback + Text { + text: parent.timestamp + Rectangle { + color: "red" + width: 5; height: 5; radius: 2 + x: -2; y: -2 + } + } } + + onClicked: clickFeeback.createObject(parent, { x: mouse.x - 2, y: mouse.y - 2, text: nextTimestamp++ }) } Rectangle { objectName: "rect" id: rect - color: "blue" + color: "lightsteelblue" x: 200 y: 200 width: 400 height: 400 + Text { + text: "pinch, click or flick anywhere\nthis rectangle is the pinch target" + } } } } - } - diff --git a/tests/auto/quick/touchmouse/data/pinchonflickable.qml b/tests/auto/quick/touchmouse/data/pinchonflickable.qml index 2a7a91006e..14a41c522a 100644 --- a/tests/auto/quick/touchmouse/data/pinchonflickable.qml +++ b/tests/auto/quick/touchmouse/data/pinchonflickable.qml @@ -1,11 +1,9 @@ import QtQuick 2.0 -//import Qt.test 1.0 Rectangle { id: root width: 600 height: 600 - color: "green" Flickable { objectName: "flickable" @@ -16,11 +14,14 @@ Rectangle { Rectangle { objectName: "rect" id: rect - color: "blue" + color: "steelblue" x: 200 y: 200 width: 400 height: 400 + Text { + text: "pinch or flick anywhere\nthis rectangle is the pinch target" + } } PinchArea { objectName: "pincharea" @@ -32,4 +33,3 @@ Rectangle { } } } - |