summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorMichal Klocek <michal.klocek@theqtcompany.com>2015-03-26 11:01:02 +0100
committerAlex Blasche <alexander.blasche@theqtcompany.com>2015-04-01 10:58:48 +0000
commit2d467627ea371af16ef39498b748fe1843d8d89a (patch)
tree761d049bf73bcf16aa00a0ed214f6ad98341c64d /tests
parent31b85d235575c72274a57e894645720fe470ddc5 (diff)
downloadqtlocation-2d467627ea371af16ef39498b748fe1843d8d89a.tar.gz
Change mouse and touch handling in Map QML component.
Rewrite events handling in the map. This commit assumes, that first touch point is always synthesized to mouse event. Initial touch event is not handled, and map interaction is started by mouse event. This approach fits better for interaction with QML components, where mouse is primary way of control and simplifies mouse grabbing/ungrabbing. Moreover: * fixes issue, where grabbed synthesized mouse event is handled by top most element. * fixes correct value for previous zoomLevel in pinch update event. * fixes correct value for touch center in pinch end event. This commit on xcb platform depends on QTBUG-30417. Change-Id: Ic07dfa4bfaea20b4491135248abed44b25b2b950 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/auto/declarative_ui/tst_map_mouse.qml5
1 files changed, 4 insertions, 1 deletions
diff --git a/tests/auto/declarative_ui/tst_map_mouse.qml b/tests/auto/declarative_ui/tst_map_mouse.qml
index 0c6ddb14..c49c2c1a 100644
--- a/tests/auto/declarative_ui/tst_map_mouse.qml
+++ b/tests/auto/declarative_ui/tst_map_mouse.qml
@@ -535,6 +535,8 @@ Item {
compare(mouseLowerPressedSpy.count, 1)
compare(mouseLowerReleasedSpy.count, 1)
+
+ compare(mouseOverlapperPressedSpy.count, 0)
mousePress(map, 55, 75)
compare(mouseUpperPressedSpy.count, 2)
compare(mouseLowerPressedSpy.count, 1)
@@ -545,7 +547,8 @@ Item {
compare(mouseUpperReleasedSpy.count, 2)
compare(mouseLowerPressedSpy.count, 1)
compare(mouseLowerReleasedSpy.count, 1)
- compare(mouseOverlapperReleasedSpy.count, 1)
+ //this should follow the same logic as Flickable
+ compare(mouseOverlapperReleasedSpy.count, 0)
}
function test_basic_click() {