summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel/qgesture_p.h
diff options
context:
space:
mode:
authorDenis Dzyubenko <denis.dzyubenko@nokia.com>2009-05-08 16:46:44 (GMT)
committerDenis Dzyubenko <denis.dzyubenko@nokia.com>2009-05-11 14:52:04 (GMT)
commit81a64345258f2f2ad5cf77355f7ecbd3ebad9734 (patch)
tree6fa024d2cadedae9ecd4e1718f704281112a78b5 /src/gui/kernel/qgesture_p.h
parent0edf9fc7ede35995ec37197b5fb5ef92a4ccf60f (diff)
downloadQt-81a64345258f2f2ad5cf77355f7ecbd3ebad9734.zip
Qt-81a64345258f2f2ad5cf77355f7ecbd3ebad9734.tar.gz
Qt-81a64345258f2f2ad5cf77355f7ecbd3ebad9734.tar.bz2
Improved gesture propagation.
Each gesture can now be accepted separately and not accepted gestures will be propagated to parent widget that are subscribed to them. Added an internal flag to specify that gesture is a "singleshot" - aka if the gesture is not continious and will not have a GestureStarted state, but only GestureFinished. Asynchronous gestures still need to fixed, as well as QGraphicsView.
Diffstat (limited to 'src/gui/kernel/qgesture_p.h')
-rw-r--r--src/gui/kernel/qgesture_p.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/gui/kernel/qgesture_p.h b/src/gui/kernel/qgesture_p.h
index 22d6d7f..d2d77cc 100644
--- a/src/gui/kernel/qgesture_p.h
+++ b/src/gui/kernel/qgesture_p.h
@@ -66,7 +66,7 @@ class QGesturePrivate : public QObjectPrivate
public:
QGesturePrivate()
- : duration(0) { }
+ : state(Qt::NoGesture), singleshot(0), duration(0) { }
void init(const QPoint &startPos, const QPoint &lastPos,
const QPoint &pos, const QRect &rect,
@@ -86,6 +86,7 @@ public:
Qt::GestureState state;
QPointer<QWidget> widget;
+ uint singleshot:1;
QRect rect;
QPoint hotSpot;