diff options
author | Qt Continuous Integration System <qt-info@nokia.com> | 2011-02-10 06:17:37 (GMT) |
---|---|---|
committer | Qt Continuous Integration System <qt-info@nokia.com> | 2011-02-10 06:17:37 (GMT) |
commit | abb425e3db6c20c5271788cb1ec4e1fe37b9ea5b (patch) | |
tree | 86b68eb00cd024dc7e6293dcf8329f300c83af48 /src/declarative/graphicsitems/qdeclarativemousearea.cpp | |
parent | fd3b8a0e008dd00e363ac173a2cfcabcab31c454 (diff) | |
parent | 27b71c5b0b432235da1931ae830e9ad52ee450e7 (diff) | |
download | Qt-abb425e3db6c20c5271788cb1ec4e1fe37b9ea5b.zip Qt-abb425e3db6c20c5271788cb1ec4e1fe37b9ea5b.tar.gz Qt-abb425e3db6c20c5271788cb1ec4e1fe37b9ea5b.tar.bz2 |
Merge branch 'qt-master-from-4.7' of scm.dev.nokia.troll.no:qt/qt-integration into master-integration
* 'qt-master-from-4.7' of scm.dev.nokia.troll.no:qt/qt-integration: (182 commits)
Fixes XPASS
Revert part of commit 7c1ab9b6a8
Fixed wrong casing of a Symbian library.
Fixed wrong static library extension on Symbian.
Fixed library casing.
Remove dependencies to pre-Symbian3 platforms from Symbian3 packages
My changes 4.7.2
Don't accept input methods when a TextEdit or TextInput is read only.
Correct error message
On windows xp using a higher port makes the declarativedebug* tests work
Correct assert
Fix qt.sis platform dependencies for Symbian^3 builds.
Fix few QFileDialog static method issues in Symbian^3
Update QDeclarative DEF files for Symbian
Export QDeclarativeRefCount so that symbian compiles.
Make Flickable's wheel handling more like QAbstractScrollArea.
Changing header or footer failed to delete the previous.
Avoid index-out-of bounds related crash in Grid
Move Qt.application docs into Qt global object page
Add initial size to ListView in FolderListModel example
...
Diffstat (limited to 'src/declarative/graphicsitems/qdeclarativemousearea.cpp')
-rw-r--r-- | src/declarative/graphicsitems/qdeclarativemousearea.cpp | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/src/declarative/graphicsitems/qdeclarativemousearea.cpp b/src/declarative/graphicsitems/qdeclarativemousearea.cpp index 4b555d0..273fc53 100644 --- a/src/declarative/graphicsitems/qdeclarativemousearea.cpp +++ b/src/declarative/graphicsitems/qdeclarativemousearea.cpp @@ -583,18 +583,22 @@ void QDeclarativeMouseArea::hoverEnterEvent(QGraphicsSceneHoverEvent *event) Q_D(QDeclarativeMouseArea); if (!d->absorb) QDeclarativeItem::hoverEnterEvent(event); - else + else { + d->lastPos = event->pos(); setHovered(true); + QDeclarativeMouseEvent me(d->lastPos.x(), d->lastPos.y(), Qt::NoButton, Qt::NoButton, event->modifiers(), false, false); + emit mousePositionChanged(&me); + } } void QDeclarativeMouseArea::hoverMoveEvent(QGraphicsSceneHoverEvent *event) { Q_D(QDeclarativeMouseArea); if (!d->absorb) { - QDeclarativeItem::hoverEnterEvent(event); + QDeclarativeItem::hoverMoveEvent(event); } else { d->lastPos = event->pos(); - QDeclarativeMouseEvent me(d->lastPos.x(), d->lastPos.y(), Qt::NoButton, d->lastButtons, d->lastModifiers, false, d->longPress); + QDeclarativeMouseEvent me(d->lastPos.x(), d->lastPos.y(), Qt::NoButton, Qt::NoButton, event->modifiers(), false, false); emit mousePositionChanged(&me); me.setX(d->lastPos.x()); me.setY(d->lastPos.y()); @@ -859,15 +863,16 @@ bool QDeclarativeMouseArea::setPressed(bool p) me.setX(d->lastPos.x()); me.setY(d->lastPos.y()); emit mousePositionChanged(&me); + emit pressedChanged(); } else { emit released(&me); me.setX(d->lastPos.x()); me.setY(d->lastPos.y()); + emit pressedChanged(); if (isclick && !d->longPress && !d->doubleClick) emit clicked(&me); } - emit pressedChanged(); return me.isAccepted(); } return false; |