diff options
author | Jan Arve Saether <jan-arve.saether@qt.io> | 2016-10-18 11:49:13 +0200 |
---|---|---|
committer | Shawn Rutledge <shawn.rutledge@qt.io> | 2016-11-20 21:09:33 +0000 |
commit | 542eda976c2767ed6c1eecb4dbcbf838e0ca5a19 (patch) | |
tree | 1128e69b70be26e13f35a2591c297d43c6414592 /src/quick/handlers/qquickpinchhandler_p.h | |
parent | 0beb79fb0e9ed814b3e9447ccd97a0c099af9e4b (diff) |
Fixed some problems with the centroid in PinchHandler
The centroid was not always mapped to the correct coordinate system
In addition, the return value of startingCentroid() was not always
desirable, because its implementation calls sceneGrabPos(). We therefore
had to get the starting centroid by querying touchPointCentroid() whenever
the handler became active.
Change-Id: I69de6b832b9bda208fda4eb90a8a95cc975405c2
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Diffstat (limited to 'src/quick/handlers/qquickpinchhandler_p.h')
-rw-r--r-- | src/quick/handlers/qquickpinchhandler_p.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/quick/handlers/qquickpinchhandler_p.h b/src/quick/handlers/qquickpinchhandler_p.h index 338b930373..5107a5c50b 100644 --- a/src/quick/handlers/qquickpinchhandler_p.h +++ b/src/quick/handlers/qquickpinchhandler_p.h @@ -155,6 +155,8 @@ private: qreal m_startScale; qreal m_startRotation; qreal m_activeRotation; + QPointF m_startCentroid; + qreal m_startDistance; QVector<PointData> m_startAngles; QMatrix4x4 m_startMatrix; |