diff options
Diffstat (limited to 'tests/auto/quick/qquickmousearea/data')
-rw-r--r-- | tests/auto/quick/qquickmousearea/data/hoverAfterPress.qml | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/tests/auto/quick/qquickmousearea/data/hoverAfterPress.qml b/tests/auto/quick/qquickmousearea/data/hoverAfterPress.qml new file mode 100644 index 0000000000..69ec8fbd47 --- /dev/null +++ b/tests/auto/quick/qquickmousearea/data/hoverAfterPress.qml @@ -0,0 +1,29 @@ +import QtQuick 2.0 + +Item { + width: 500 + height: 500 + + Rectangle { + width: 300 + height: 300 + color: "grey" + x: 100 + y: 100 + + MouseArea { + id: mouseArea + objectName: "mouseArea" + anchors.fill: parent + hoverEnabled: true + onPressed: mouse.accepted = false + //onContainsMouseChanged: print("containsMouse changed =", containsMouse) + + Rectangle { + visible: parent.containsMouse + color: "red" + width: 10; height: 10 + } + } + } +} |