summaryrefslogtreecommitdiffstats
path: root/src/widgets
diff options
context:
space:
mode:
authorAndrew den Exter <andrew.den-exter@nokia.com>2011-08-04 10:58:26 +1000
committerQt by Nokia <qt-info@nokia.com>2011-12-12 13:19:28 +0100
commit28165d54467179c7c16c38cea2a5f6e43367f385 (patch)
tree5894540b7bc4c52d8e750d8130d7cea93c27ce12 /src/widgets
parent734033e71d76e02f63a46c7d8f68b7cf404667fe (diff)
Move cursorDelegate with the mouse selection of read only text input.
Task-number: QTBUG-20719 Task-number: QTBUG-19109 Reviewed-by: Martin Jones Change-Id: I2cec51eb5b01dc5750614edf5b39d6a3da661fc6 Reviewed-by: Joona Petrell <joona.t.petrell@nokia.com>
Diffstat (limited to 'src/widgets')
-rw-r--r--src/widgets/widgets/qwidgettextcontrol.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/widgets/widgets/qwidgettextcontrol.cpp b/src/widgets/widgets/qwidgettextcontrol.cpp
index c63dcf0318..2a6831eb93 100644
--- a/src/widgets/widgets/qwidgettextcontrol.cpp
+++ b/src/widgets/widgets/qwidgettextcontrol.cpp
@@ -1696,8 +1696,10 @@ void QWidgetTextControlPrivate::mouseMoveEvent(QEvent *e, Qt::MouseButton button
#endif //QT_NO_IM
} else {
//emit q->visibilityRequest(QRectF(mousePos, QSizeF(1, 1)));
- if (cursor.position() != oldCursorPos)
+ if (cursor.position() != oldCursorPos) {
emit q->cursorPositionChanged();
+ emit q->microFocusChanged();
+ }
}
selectionChanged(true);
repaintOldAndNewSelection(oldSelection);
@@ -1744,8 +1746,10 @@ void QWidgetTextControlPrivate::mouseReleaseEvent(QEvent *e, Qt::MouseButton but
repaintOldAndNewSelection(oldSelection);
- if (cursor.position() != oldCursorPos)
+ if (cursor.position() != oldCursorPos) {
emit q->cursorPositionChanged();
+ emit q->microFocusChanged();
+ }
if (interactionFlags & Qt::LinksAccessibleByMouse) {
if (!(button & Qt::LeftButton))