summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel
diff options
context:
space:
mode:
authorDenis Dzyubenko <denis.dzyubenko@nokia.com>2009-03-20 14:33:24 (GMT)
committerDenis Dzyubenko <denis.dzyubenko@nokia.com>2009-05-11 14:51:43 (GMT)
commit76fa94daad48382630a7a1b15dc692c6dcad6b93 (patch)
tree80a7c84a9f062edd119853979085eeffced95be8 /src/gui/kernel
parentd4e64228ef8154a1f69f91cfd6a78f29d89718e1 (diff)
downloadQt-76fa94daad48382630a7a1b15dc692c6dcad6b93.zip
Qt-76fa94daad48382630a7a1b15dc692c6dcad6b93.tar.gz
Qt-76fa94daad48382630a7a1b15dc692c6dcad6b93.tar.bz2
Oops, fixed a memory corruption in Pan gesture due to invalid d-pointer type.
Diffstat (limited to 'src/gui/kernel')
-rw-r--r--src/gui/kernel/qgesture.cpp3
-rw-r--r--src/gui/kernel/qgesture.h3
2 files changed, 4 insertions, 2 deletions
diff --git a/src/gui/kernel/qgesture.cpp b/src/gui/kernel/qgesture.cpp
index ccda805..ac135d7 100644
--- a/src/gui/kernel/qgesture.cpp
+++ b/src/gui/kernel/qgesture.cpp
@@ -250,7 +250,8 @@ QPoint QGesture::pos() const
/*! \internal
*/
QPanningGesture::QPanningGesture(QObject *parent)
- : QGesture(parent, qt_getStandardGestureTypeName(Qt::PanGesture))
+ : QGesture(*new QPanningGesturePrivate, parent,
+ qt_getStandardGestureTypeName(Qt::PanGesture))
{
}
diff --git a/src/gui/kernel/qgesture.h b/src/gui/kernel/qgesture.h
index f98b573..a3d9e43 100644
--- a/src/gui/kernel/qgesture.h
+++ b/src/gui/kernel/qgesture.h
@@ -95,7 +95,8 @@ public:
QPoint pos() const;
protected:
- QGesture(QGesturePrivate &dd, QObject *parent, const QString &type, Qt::GestureState state);
+ QGesture(QGesturePrivate &dd, QObject *parent, const QString &type,
+ Qt::GestureState state = Qt::GestureStarted);
virtual void translate(const QPoint &offset);
private: