diff options
Diffstat (limited to 'src/gui/graphicsview')
-rw-r--r-- | src/gui/graphicsview/qgraphicsproxywidget.cpp | 5 | ||||
-rw-r--r-- | src/gui/graphicsview/qgraphicsproxywidget_p.h | 1 |
2 files changed, 5 insertions, 1 deletions
diff --git a/src/gui/graphicsview/qgraphicsproxywidget.cpp b/src/gui/graphicsview/qgraphicsproxywidget.cpp index a39ccfd..483eb62 100644 --- a/src/gui/graphicsview/qgraphicsproxywidget.cpp +++ b/src/gui/graphicsview/qgraphicsproxywidget.cpp @@ -1315,6 +1315,8 @@ void QGraphicsProxyWidget::focusInEvent(QFocusEvent *event) return; } + d->proxyIsGivingFocus = true; + switch (event->reason()) { case Qt::TabFocusReason: { if (QWidget *focusChild = d->findFocusChild(0, true)) @@ -1328,10 +1330,11 @@ void QGraphicsProxyWidget::focusInEvent(QFocusEvent *event) default: if (d->widget && d->widget->focusWidget()) { d->widget->focusWidget()->setFocus(event->reason()); - return; } break; } + + d->proxyIsGivingFocus = false; } /*! diff --git a/src/gui/graphicsview/qgraphicsproxywidget_p.h b/src/gui/graphicsview/qgraphicsproxywidget_p.h index 60eb058..8aed363 100644 --- a/src/gui/graphicsview/qgraphicsproxywidget_p.h +++ b/src/gui/graphicsview/qgraphicsproxywidget_p.h @@ -118,6 +118,7 @@ public: quint32 styleChangeMode : 2; quint32 paletteChangeMode : 2; quint32 focusFromWidgetToProxy : 1; + quint32 proxyIsGivingFocus : 1; }; QT_END_NAMESPACE |