From 6e3860d17537bbb9789811dd725260bc971f1b46 Mon Sep 17 00:00:00 2001 From: Sami Merila Date: Tue, 20 Apr 2010 16:28:46 +0300 Subject: QS60Style: Style draws a focus frame to context menus and popups Currently QS60Style draws a ficus frame around context menus and combobox popups. This should be removed, as these widgets have keypad navigable item highlight rect inside them AND the widgets cannot be navigated in/out from other widgets. Also, currently there is no room to draw the focus frame to left and right border, so the focus frame looks somewhat strange theme colored think line above and below popup/menu. Task-number: QTBUG-10064 Reviewed-by: Alessandro Portale --- src/gui/styles/qs60style.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/gui/styles/qs60style.cpp b/src/gui/styles/qs60style.cpp index 6974959..6f05908 100644 --- a/src/gui/styles/qs60style.cpp +++ b/src/gui/styles/qs60style.cpp @@ -3156,6 +3156,12 @@ bool QS60Style::event(QEvent *e) #ifdef QT_KEYPAD_NAVIGATION case QEvent::FocusIn: if (QWidget *focusWidget = QApplication::focusWidget()) { + + // Menus and combobox popups do not draw focus frame around them + if (qobject_cast(focusWidget) || + qobject_cast(focusWidget)) + break; + if (!d->m_focusFrame) d->m_focusFrame = new QFocusFrame(focusWidget); d->m_focusFrame->setWidget(focusWidget); -- cgit v0.12