diff options
author | Denis Dzyubenko <denis.dzyubenko@nokia.com> | 2009-08-04 11:37:35 (GMT) |
---|---|---|
committer | Denis Dzyubenko <denis.dzyubenko@nokia.com> | 2009-08-04 14:22:48 (GMT) |
commit | 47c191d3c6b9c3fbe062068167888bed434ab6e2 (patch) | |
tree | 7b3a6f4b9b7e542bfdd79e09682fcea618e95e43 /src/gui/widgets | |
parent | 6b85ec8790aad8ac01c04f7e7bd4913d8cd8d104 (diff) | |
download | Qt-47c191d3c6b9c3fbe062068167888bed434ab6e2.zip Qt-47c191d3c6b9c3fbe062068167888bed434ab6e2.tar.gz Qt-47c191d3c6b9c3fbe062068167888bed434ab6e2.tar.bz2 |
Removed the startPos/lastPos/pos from the gesture classes.
It doesn't make much sense to have that low-level info neither in the base
QGesture class, nor in the QPanGesture, as the latter one has offset properties
instead.
Reviewed-by: trustme
Diffstat (limited to 'src/gui/widgets')
-rw-r--r-- | src/gui/widgets/qtextedit.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/gui/widgets/qtextedit.cpp b/src/gui/widgets/qtextedit.cpp index e80df92..c095f5c 100644 --- a/src/gui/widgets/qtextedit.cpp +++ b/src/gui/widgets/qtextedit.cpp @@ -2625,12 +2625,12 @@ void QTextEditPrivate::_q_gestureTriggered() return; QScrollBar *hBar = q->horizontalScrollBar(); QScrollBar *vBar = q->verticalScrollBar(); - QPoint delta = g->pos() - (g->lastPos().isNull() ? g->pos() : g->lastPos()); + QSize delta = g->lastOffset(); if (!delta.isNull()) { if (QApplication::isRightToLeft()) - delta.rx() *= -1; - int newX = hBar->value() - delta.x(); - int newY = vBar->value() - delta.y(); + delta.rwidth() *= -1; + int newX = hBar->value() - delta.width(); + int newY = vBar->value() - delta.height(); hbar->setValue(newX); vbar->setValue(newY); } |