From 7ed6a247bfcf314b4a7bc8332b813b3e92997e41 Mon Sep 17 00:00:00 2001 From: Laszlo Agocs Date: Mon, 23 Jan 2012 10:28:58 +0200 Subject: Fix synthesizing mouse events when touches change ordering MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit There is no guarantee the touches will be listed in the same order in an update: the platform/generic plug-in, the drivers, etc. are all free to shuffle the list of touch points in each report (even though the order is fairly stable with most systems). Therefore, to be safe, move and release events should be generated not from the first point in the list but from the one with the matching id. Change-Id: I6615224cbf2cfdc440143eb3191482a23d85c6a4 Reviewed-by: Samuel Rødal --- src/gui/kernel/qguiapplication_p.h | 1 + 1 file changed, 1 insertion(+) (limited to 'src/gui/kernel/qguiapplication_p.h') diff --git a/src/gui/kernel/qguiapplication_p.h b/src/gui/kernel/qguiapplication_p.h index 1e2abb22a0..09db13e28e 100644 --- a/src/gui/kernel/qguiapplication_p.h +++ b/src/gui/kernel/qguiapplication_p.h @@ -206,6 +206,7 @@ private: static QGuiApplicationPrivate *self; static QTouchDevice *m_fakeTouchDevice; + static int m_fakeMouseSourcePointId; }; Q_GUI_EXPORT uint qHash(const QGuiApplicationPrivate::ActiveTouchPointsKey &k); -- cgit v1.2.3