summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel/qwidget_s60.cpp
diff options
context:
space:
mode:
authorMiikka Heikkinen <miikka.heikkinen@digia.com>2011-03-31 12:49:46 (GMT)
committerMiikka Heikkinen <miikka.heikkinen@digia.com>2011-03-31 13:28:14 (GMT)
commit54601b563fb1935c901fc99046ca35dd6d90d1c7 (patch)
treec12faa8376236ee369fe48d09a997f8f01bc064e /src/gui/kernel/qwidget_s60.cpp
parent7da530eba0e53cf0c15e790a395442fc9daa41b0 (diff)
downloadQt-54601b563fb1935c901fc99046ca35dd6d90d1c7.zip
Qt-54601b563fb1935c901fc99046ca35dd6d90d1c7.tar.gz
Qt-54601b563fb1935c901fc99046ca35dd6d90d1c7.tar.bz2
Do not set focus unnecessarily at window activation in Symbian
Calling QSymbianControl::setFocusSafely(true) on currently focused window causes the next window in stack to get the focus momentarily, leading to various softkey problems, such as leaving child window's softkeys around when child is closed and flickering softkeys when child is opened. Added a check to QWidget::activateWindow to avoid calling setFocusSafely for already focused windows. Task-number: QTBUG-18409 Reviewed-by: Sami Merila Reviewed-by: axis
Diffstat (limited to 'src/gui/kernel/qwidget_s60.cpp')
-rw-r--r--src/gui/kernel/qwidget_s60.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/gui/kernel/qwidget_s60.cpp b/src/gui/kernel/qwidget_s60.cpp
index e7d5e95..8b57701 100644
--- a/src/gui/kernel/qwidget_s60.cpp
+++ b/src/gui/kernel/qwidget_s60.cpp
@@ -1451,7 +1451,8 @@ void QWidget::activateWindow()
if (tlw->isVisible()) {
window()->createWinId();
QSymbianControl *id = static_cast<QSymbianControl *>(tlw->internalWinId());
- id->setFocusSafely(true);
+ if (!id->IsFocused())
+ id->setFocusSafely(true);
}
}