aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHarunobu Kurokawa <harunobu.kurokawa.dn@renesas.com>2019-08-06 13:07:20 +0900
committerScott Murray <scott.murray@konsulko.com>2019-08-20 19:58:45 +0000
commit80f21c014fc13dbd624e3ed6346b3d991615e28c (patch)
tree0597186f2903bb756ee8f23b00e37d0160bdac63
parentacc3a8ec6102fb9bad15ad31f0c1afcdf40cb772 (diff)
qtlocation: Fix unstable rotation using pinch zoom
This patch is merged in 5.11 branch, however it was not in 5.11.3. https://codereview.qt-project.org/c/qt/qtlocation/+/244889 Bug-AGL: SPEC-2709 Change-Id: I90a914b1a1fd21b1a181a50749ed91e90960021d Signed-off-by: Harunobu Kurokawa <harunobu.kurokawa.dn@renesas.com> Signed-off-by: Scott Murray <scott.murray@konsulko.com> (cherry picked from commit 4fccf34ac71bd65d10d74c0b00446c4a6d40043f)
-rw-r--r--recipes-qt/qt5/qtlocation/0001-Fix-unstable-rotation-gesture.patch30
-rw-r--r--recipes-qt/qt5/qtlocation_git.bbappend5
2 files changed, 35 insertions, 0 deletions
diff --git a/recipes-qt/qt5/qtlocation/0001-Fix-unstable-rotation-gesture.patch b/recipes-qt/qt5/qtlocation/0001-Fix-unstable-rotation-gesture.patch
new file mode 100644
index 000000000..164c9f0e5
--- /dev/null
+++ b/recipes-qt/qt5/qtlocation/0001-Fix-unstable-rotation-gesture.patch
@@ -0,0 +1,30 @@
+From 85df79b094d1097108a28424d6f9b3b76b3aee62 Mon Sep 17 00:00:00 2001
+From: Tasuku Suzuki <tasuku.suzuki@qt.io>
+Date: Thu, 8 Nov 2018 15:26:57 +0900
+Subject: [PATCH] Fix unstable rotation gesture
+
+Order of touch events are not sorted on some platform. When touch point
+1 and
+2 are swapped, map is rotated 180 degrees in a moment
+
+Change-Id: I9c308b805a6ca54519f26a9ff19217de7f947c17
+Reviewed-by: Paolo Angelelli <paolo.angelelli@qt.io>
+---
+ src/location/declarativemaps/qquickgeomapgesturearea.cpp | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/src/location/declarativemaps/qquickgeomapgesturearea.cpp b/src/location/declarativemaps/qquickgeomapgesturearea.cpp
+index c6f4b42..576aeee 100644
+--- a/src/location/declarativemaps/qquickgeomapgesturearea.cpp
++++ b/src/location/declarativemaps/qquickgeomapgesturearea.cpp
+@@ -1087,6 +1087,7 @@ void QQuickGeoMapGestureArea::update()
+ m_allPoints << m_touchPoints;
+ if (m_allPoints.isEmpty() && !m_mousePoint.isNull())
+ m_allPoints << *m_mousePoint.data();
++ std::sort(m_allPoints.begin(), m_allPoints.end(), [](const QTouchEvent::TouchPoint &tp1, const QTouchEvent::TouchPoint &tp2) { return tp1.id() < tp2.id(); });
+
+ touchPointStateMachine();
+
+--
+2.7.4
+
diff --git a/recipes-qt/qt5/qtlocation_git.bbappend b/recipes-qt/qt5/qtlocation_git.bbappend
new file mode 100644
index 000000000..e0f3a6b2e
--- /dev/null
+++ b/recipes-qt/qt5/qtlocation_git.bbappend
@@ -0,0 +1,5 @@
+FILESEXTRAPATHS_prepend := "${THISDIR}/${BPN}:"
+
+SRC_URI += " \
+ file://0001-Fix-unstable-rotation-gesture.patch \
+"