summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel/qapplication.cpp
diff options
context:
space:
mode:
authorSami Merila <sami.merila@nokia.com>2009-12-21 11:28:47 (GMT)
committerSami Merila <sami.merila@nokia.com>2009-12-21 11:28:47 (GMT)
commit71ee64f5a44dc310272b14fe6cd913b2e75672ed (patch)
treef38b4617a0d886d802e8bb33aa2e3db02053519c /src/gui/kernel/qapplication.cpp
parent3e45dbcc89a9f2284d8ab89e0c75bd7b275e6b61 (diff)
downloadQt-71ee64f5a44dc310272b14fe6cd913b2e75672ed.zip
Qt-71ee64f5a44dc310272b14fe6cd913b2e75672ed.tar.gz
Qt-71ee64f5a44dc310272b14fe6cd913b2e75672ed.tar.bz2
Edit focus should not be lost unless by explicit action
Currently non-touch devices lose edit focus if window switch happens. I.e. in cases when screensaver activates, an incoming call occurs, a global notification is shown... With this fix, edit focus remain active, until user removes the focus explicitly. Task-number: 4792 Reviewed-by: axis
Diffstat (limited to 'src/gui/kernel/qapplication.cpp')
-rw-r--r--src/gui/kernel/qapplication.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/gui/kernel/qapplication.cpp b/src/gui/kernel/qapplication.cpp
index bd13423..4165c95 100644
--- a/src/gui/kernel/qapplication.cpp
+++ b/src/gui/kernel/qapplication.cpp
@@ -2096,7 +2096,11 @@ void QApplicationPrivate::setFocusWidget(QWidget *focus, Qt::FocusReason reason)
if (prev) {
#ifdef QT_KEYPAD_NAVIGATION
if (QApplication::keypadNavigationEnabled()) {
- if (prev->hasEditFocus() && reason != Qt::PopupFocusReason)
+ if (prev->hasEditFocus() && reason != Qt::PopupFocusReason
+#ifdef Q_OS_SYMBIAN
+ && reason != Qt::ActiveWindowFocusReason
+#endif
+ )
prev->setEditFocus(false);
}
#endif