diff options
author | Laszlo Agocs <laszlo.agocs@qt.io> | 2019-05-28 17:59:34 +0200 |
---|---|---|
committer | Laszlo Agocs <laszlo.agocs@qt.io> | 2019-05-28 17:59:40 +0200 |
commit | 0f5c34f2c6b64bae3429706a6c4211334c689092 (patch) | |
tree | b85888d73518f6abc7bbde74ab71a27887682f9d /src/quick/items/qquicktextcontrol.cpp | |
parent | 44ca7e31ee9365a72cd17ecd335ec4d0161420a9 (diff) | |
parent | 9d61684d70c8691d81536b7b519388586e2cbbb8 (diff) |
Merge remote-tracking branch 'origin/dev' into wip/scenegraphng
Change-Id: Ie7dbc5a7d9eccd1613283134a1b47ab597d036d5
Diffstat (limited to 'src/quick/items/qquicktextcontrol.cpp')
-rw-r--r-- | src/quick/items/qquicktextcontrol.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/quick/items/qquicktextcontrol.cpp b/src/quick/items/qquicktextcontrol.cpp index a7a90c9134..caef24293a 100644 --- a/src/quick/items/qquicktextcontrol.cpp +++ b/src/quick/items/qquicktextcontrol.cpp @@ -1297,6 +1297,7 @@ void QQuickTextControlPrivate::inputMethodEvent(QInputMethodEvent *e) || e->preeditString() != cursor.block().layout()->preeditAreaText() || e->replacementLength() > 0; bool forceSelectionChanged = false; + int oldCursorPos = cursor.position(); cursor.beginEditBlock(); if (isGettingInput) { @@ -1365,6 +1366,8 @@ void QQuickTextControlPrivate::inputMethodEvent(QInputMethodEvent *e) QTextCursorPrivate *cursor_d = QTextCursorPrivate::getPrivate(&cursor); if (cursor_d) cursor_d->setX(); + if (cursor.position() != oldCursorPos) + emit q->cursorPositionChanged(); q->updateCursorRectangle(oldPreeditCursor != preeditCursor || forceSelectionChanged || isGettingInput); selectionChanged(forceSelectionChanged); } |