diff options
| author | Frederik Gladhorn <frederik.gladhorn@digia.com> | 2013-11-06 00:51:57 +0100 |
|---|---|---|
| committer | The Qt Project <gerrit-noreply@qt-project.org> | 2013-11-06 02:02:30 +0100 |
| commit | 09c931e2abab0bdc7344d6fa83fb7083c3b340ea (patch) | |
| tree | d6cba9d7b594ef74aeb536a7dcb1995b0fd96835 /src/controls/TextField.qml | |
| parent | 792bb911bb5a2af6f00b3d32c654579a700257c6 (diff) | |
Fix input method committing
On mobile devices the virtual keyboard would in some situations not have
words committed yet - this leads to the last word after a space being
cut off when querying for the text property.
Change-Id: I23d81154f3bed1dd287f24c3c5f958cf4335475c
Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
Diffstat (limited to 'src/controls/TextField.qml')
| -rw-r--r-- | src/controls/TextField.qml | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/controls/TextField.qml b/src/controls/TextField.qml index 006ab7dc3..c1e3ddab4 100644 --- a/src/controls/TextField.qml +++ b/src/controls/TextField.qml @@ -586,6 +586,10 @@ Control { renderType: __style ? __style.renderType : Text.NativeRendering - onAccepted: textfield.accepted() + onAccepted: { + Qt.inputMethod.commit() + Qt.inputMethod.hide() + textfield.accepted() + } } } |
