summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorQt Continuous Integration System <qt-info@nokia.com>2011-09-23 08:05:56 (GMT)
committerQt Continuous Integration System <qt-info@nokia.com>2011-09-23 08:05:56 (GMT)
commit84e905a50767e81abaa2827a6b98401677527374 (patch)
tree5baa9ae03edcbebe4d31243d4d25a9b921795adf
parent24a5178d9d995afdee118ca3452bff0255ece97e (diff)
parent4d07fc585b7cb8784deaf98afa432082f36fc981 (diff)
downloadQt-84e905a50767e81abaa2827a6b98401677527374.zip
Qt-84e905a50767e81abaa2827a6b98401677527374.tar.gz
Qt-84e905a50767e81abaa2827a6b98401677527374.tar.bz2
Merge branch 'master' of git://scm.dev.nokia.troll.no/qt/qt-symbian-team
* 'master' of git://scm.dev.nokia.troll.no/qt/qt-symbian-team: The cursor can get offscreen in splitscreen landscape mode
-rw-r--r--src/gui/inputmethod/qcoefepinputcontext_s60.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/gui/inputmethod/qcoefepinputcontext_s60.cpp b/src/gui/inputmethod/qcoefepinputcontext_s60.cpp
index 9025221..b830d50 100644
--- a/src/gui/inputmethod/qcoefepinputcontext_s60.cpp
+++ b/src/gui/inputmethod/qcoefepinputcontext_s60.cpp
@@ -1277,7 +1277,11 @@ void QCoeFepInputContext::translateInputWidget()
// Translation should happen row-by-row, but initially it needs to ensure that cursor is visible.
const qreal translation = m_transformation.height() ?
cursor.height() : (cursorRect.bottom() - vkbRect.top());
- const qreal dy = -(qMin(maxY, translation));
+ qreal dy = -(qMin(maxY, translation));
+
+ // Correct the translation direction, if the cursor rect would be moved outside of application area.
+ if ((cursorRect.bottom() + dy) < 0)
+ dy *= -1;
// Do not allow transform above screen top, nor beyond scenerect
if (m_transformation.height() + dy > 0 || gv->sceneRect().bottom() + m_transformation.height() < 0) {