summaryrefslogtreecommitdiffstats
path: root/src/gui/inputmethod
diff options
context:
space:
mode:
authorOlivier Goffart <olivier.goffart@nokia.com>2011-04-27 09:27:52 (GMT)
committerOlivier Goffart <olivier.goffart@nokia.com>2011-04-27 09:27:52 (GMT)
commit896db169ea224deb96c59ce8af800d019de63f12 (patch)
tree8350c36941ccfd74df35fb8a6a761edcbf042452 /src/gui/inputmethod
parent7a73de74fc517ff5722289cce4e4e754ff2417be (diff)
parentf8fea6f3b8fd3a1baa256130b23efc9e67a40e21 (diff)
downloadQt-896db169ea224deb96c59ce8af800d019de63f12.zip
Qt-896db169ea224deb96c59ce8af800d019de63f12.tar.gz
Qt-896db169ea224deb96c59ce8af800d019de63f12.tar.bz2
Merge remote-tracking branch 'origin/4.7' into qt-4.8-from-4.7
Conflicts: src/opengl/qwindowsurface_gl.cpp src/s60installs/eabi/QtGuiu.def
Diffstat (limited to 'src/gui/inputmethod')
-rw-r--r--src/gui/inputmethod/qcoefepinputcontext_s60.cpp13
1 files changed, 9 insertions, 4 deletions
diff --git a/src/gui/inputmethod/qcoefepinputcontext_s60.cpp b/src/gui/inputmethod/qcoefepinputcontext_s60.cpp
index 92f8384..06dc25c 100644
--- a/src/gui/inputmethod/qcoefepinputcontext_s60.cpp
+++ b/src/gui/inputmethod/qcoefepinputcontext_s60.cpp
@@ -255,9 +255,13 @@ bool QCoeFepInputContext::filterEvent(const QEvent *event)
// fall through intended
case QEvent::KeyRelease:
const QKeyEvent *keyEvent = static_cast<const QKeyEvent *>(event);
+ //If proxy exists, always use hints from proxy.
+ QWidget *proxy = focusWidget()->focusProxy();
+ Qt::InputMethodHints currentHints = proxy ? proxy->inputMethodHints() : focusWidget()->inputMethodHints();
+
switch (keyEvent->key()) {
case Qt::Key_F20:
- Q_ASSERT(m_lastImHints == focusWidget()->inputMethodHints());
+ Q_ASSERT(m_lastImHints == currentHints);
if (m_lastImHints & Qt::ImhHiddenText) {
// Special case in Symbian. On editors with secret text, F20 is for some reason
// considered to be a backspace.
@@ -287,7 +291,7 @@ bool QCoeFepInputContext::filterEvent(const QEvent *event)
}
if (keyEvent->type() == QEvent::KeyPress
- && focusWidget()->inputMethodHints() & Qt::ImhHiddenText
+ && currentHints & Qt::ImhHiddenText
&& !keyEvent->text().isEmpty()) {
// Send some temporary preedit text in order to make text visible for a moment.
m_preeditString = keyEvent->text();
@@ -588,9 +592,10 @@ void QCoeFepInputContext::updateHints(bool mustUpdateInputCapabilities)
{
QWidget *w = focusWidget();
if (w) {
- Qt::InputMethodHints hints = w->inputMethodHints();
+ QWidget *proxy = w->focusProxy();
+ Qt::InputMethodHints hints = proxy ? proxy->inputMethodHints() : w->inputMethodHints();
- // Since splitview support works like an input method hint, yet it is private flag,
+ // Since splitview support works like an input method hint, yet it is private flag,
// we need to update its state separately.
if (QSysInfo::s60Version() > QSysInfo::SV_S60_5_0) {
TInt currentFlags = m_fepState->Flags();