summaryrefslogtreecommitdiffstats
path: root/src/gui/inputmethod
diff options
context:
space:
mode:
authorSami Merila <sami.merila@nokia.com>2011-04-14 09:01:01 (GMT)
committerSami Merila <sami.merila@nokia.com>2011-04-14 09:01:01 (GMT)
commitc156280a637abd6acb3894723a9e21ba2abc8fb8 (patch)
tree00df7cde7269a69a8dd57749046370f02ca742d0 /src/gui/inputmethod
parenta5898f33f215ff2ac333be61306a47ca162b2104 (diff)
downloadQt-c156280a637abd6acb3894723a9e21ba2abc8fb8.zip
Qt-c156280a637abd6acb3894723a9e21ba2abc8fb8.tar.gz
Qt-c156280a637abd6acb3894723a9e21ba2abc8fb8.tar.bz2
Splitview: opening a context menu should not re-position of focusItem
When splitview is open and user long taps an text input item, a context menu is opened. This leads to some drawing operations on splitview implementation, even though these should be skipped. The focusItem might even be re-positioned into incorrect position due to the failure. As a fix, check if the focusItem is already positioned correctly and avoid doing anything when it already is. Task-number: QTBUG-18738 Reviewed-by: Guoqing Zhang
Diffstat (limited to 'src/gui/inputmethod')
-rw-r--r--src/gui/inputmethod/qcoefepinputcontext_s60.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/gui/inputmethod/qcoefepinputcontext_s60.cpp b/src/gui/inputmethod/qcoefepinputcontext_s60.cpp
index 8574f2c..b64ce0c 100644
--- a/src/gui/inputmethod/qcoefepinputcontext_s60.cpp
+++ b/src/gui/inputmethod/qcoefepinputcontext_s60.cpp
@@ -538,11 +538,11 @@ void QCoeFepInputContext::ensureFocusWidgetVisible(QWidget *widget)
if (alwaysResize) {
windowToMove->setUpdatesEnabled(false);
- if (!moveWithinVisibleArea)
+ if (!moveWithinVisibleArea) {
m_splitViewResizeBy = widget->height();
-
- windowTop = widget->geometry().top();
- widget->resize(widget->width(), splitViewRect.height() - windowTop);
+ windowTop = widget->geometry().top();
+ widget->resize(widget->width(), splitViewRect.height() - windowTop);
+ }
if (gv->scene()) {
const QRectF microFocusRect = gv->scene()->inputMethodQuery(Qt::ImMicroFocus).toRectF();