diff options
author | Joona Petrell <joona.t.petrell@nokia.com> | 2011-09-12 21:54:24 +0300 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2011-09-14 21:30:35 +0200 |
commit | 5227ca6ffee3afa2e5c5d7450d80a6ebda44470b (patch) | |
tree | 0d2ff6a28b880dd3c0725c512987d1f2d874d13a /src/gui/text/qtextcontrol.cpp | |
parent | 5926e4041acd3ca43acc54a28548e577d2f5cede (diff) |
Add new composite Qt::ImQueryInput query
When cursor position or editor text changes many input method query attributes like
cursor rectangle, cursor position, surrounding text, current selection and anchor
position change as well. Checking in text control and editor classes what of those
related attributes have exactly changed before calling the update increases code
complexity unnecessarily for a little benefit. Qt::InputMethodQueries flag can still
be used to optimize more independent cases when attributes change individually, which is
more common for input methods hints, fonts, platform data, maximum length or enabled
attributes.
Change-Id: Ic9eee5f1edb6d33ef6c01d2c9c8ad582100c0150
Reviewed-on: http://codereview.qt-project.org/4739
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Diffstat (limited to 'src/gui/text/qtextcontrol.cpp')
-rw-r--r-- | src/gui/text/qtextcontrol.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gui/text/qtextcontrol.cpp b/src/gui/text/qtextcontrol.cpp index 2faa5e2078..17c8d3cb49 100644 --- a/src/gui/text/qtextcontrol.cpp +++ b/src/gui/text/qtextcontrol.cpp @@ -1594,7 +1594,7 @@ void QTextControlPrivate::mouseMoveEvent(QEvent *e, Qt::MouseButton button, cons emit q->cursorPositionChanged(); _q_updateCurrentCharFormatAndSelection(); if (qGuiApp) - qGuiApp->inputPanel()->update(Qt::ImQueryAll); + qGuiApp->inputPanel()->update(Qt::ImQueryInput); } else { //emit q->visibilityRequest(QRectF(mousePos, QSizeF(1, 1))); if (cursor.position() != oldCursorPos) { |