summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel
diff options
context:
space:
mode:
authorDenis Dzyubenko <denis.dzyubenko@nokia.com>2010-02-18 10:21:48 (GMT)
committerDenis Dzyubenko <denis.dzyubenko@nokia.com>2010-02-24 11:35:48 (GMT)
commitb35d2d4717f71b4e519d33160dfce8b23607f9c8 (patch)
treed779da4e4d9b69230236d91d497b4970bddea3f6 /src/gui/kernel
parent5d98d7fb3e961d32819ae9831b715780487612e0 (diff)
downloadQt-b35d2d4717f71b4e519d33160dfce8b23607f9c8.zip
Qt-b35d2d4717f71b4e519d33160dfce8b23607f9c8.tar.gz
Qt-b35d2d4717f71b4e519d33160dfce8b23607f9c8.tar.bz2
Cache scene coordinates of a hotspot in a QGesture.
Reviewed-by: trustme
Diffstat (limited to 'src/gui/kernel')
-rw-r--r--src/gui/kernel/qgesture_p.h2
-rw-r--r--src/gui/kernel/qgesturerecognizer.cpp1
2 files changed, 2 insertions, 1 deletions
diff --git a/src/gui/kernel/qgesture_p.h b/src/gui/kernel/qgesture_p.h
index dee5592..649a310 100644
--- a/src/gui/kernel/qgesture_p.h
+++ b/src/gui/kernel/qgesture_p.h
@@ -69,13 +69,13 @@ public:
QGesturePrivate()
: gestureType(Qt::CustomGesture), state(Qt::NoGesture),
isHotSpotSet(false), gestureCancelPolicy(0)
-
{
}
Qt::GestureType gestureType;
Qt::GestureState state;
QPointF hotSpot;
+ QPointF sceneHotSpot;
uint isHotSpotSet : 1;
uint gestureCancelPolicy : 2;
};
diff --git a/src/gui/kernel/qgesturerecognizer.cpp b/src/gui/kernel/qgesturerecognizer.cpp
index 8735d27..c88a9a7 100644
--- a/src/gui/kernel/qgesturerecognizer.cpp
+++ b/src/gui/kernel/qgesturerecognizer.cpp
@@ -181,6 +181,7 @@ void QGestureRecognizer::reset(QGesture *gesture)
QGesturePrivate *d = gesture->d_func();
d->state = Qt::NoGesture;
d->hotSpot = QPointF();
+ d->sceneHotSpot = QPointF();
d->isHotSpotSet = false;
}
}