From 629c7c2785bc7b371ed8ce1abf016c6c35a4a78f Mon Sep 17 00:00:00 2001 From: Aleksandar Sasha Babic Date: Tue, 2 Jun 2009 16:33:56 +0200 Subject: Fixed incorrect focus detection. Previously we assumed that focused widget will give us both the parent and the child. Rev By:Axis --- src/gui/kernel/qapplication_s60.cpp | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/gui/kernel/qapplication_s60.cpp b/src/gui/kernel/qapplication_s60.cpp index 308bdbb..3d865d3 100644 --- a/src/gui/kernel/qapplication_s60.cpp +++ b/src/gui/kernel/qapplication_s60.cpp @@ -524,7 +524,14 @@ TKeyResponse QSymbianControl::sendKeyEvent(QWidget *widget, QKeyEvent *keyEvent) #ifndef QT_NO_IM TCoeInputCapabilities QSymbianControl::InputCapabilities() const { - QWidget *w = qwidget->focusWidget(); + QWidget *w = 0; + + if(qwidget->hasFocus()) { + w = qwidget; + } else { + w = qwidget->focusWidget(); + } + QCoeFepInputContext *ic; if (w && w->isEnabled() && w->testAttribute(Qt::WA_InputMethodEnabled) && (ic = qobject_cast(w->inputContext()))) { -- cgit v0.12