summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDavid Garcia <david@aimsun.com>2014-02-05 17:49:11 (GMT)
committerMorten Johan Sørvig <morten.sorvig@digia.com>2014-06-18 10:26:24 (GMT)
commite66dd978999358efdb4d3edcc89b0455194c4ae1 (patch)
tree5be39131ca50c1ad2ba348d41db8b99833f73112 /src
parent753321eb459d2c988d66cc6c8905d75a0ba769bb (diff)
downloadQt-e66dd978999358efdb4d3edcc89b0455194c4ae1.zip
Qt-e66dd978999358efdb4d3edcc89b0455194c4ae1.tar.gz
Qt-e66dd978999358efdb4d3edcc89b0455194c4ae1.tar.bz2
Mac: Fix mixing unified and non-unified toolbars
Test if the target toolbar is actually a unified toolbar before calling the special MapFromParent function. This change is not needed in Qt 5. Task-number: QTBUG-36100 Change-Id: I37fce89c79f5fce057e0b31d4c4f2e72269cdb06 Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
Diffstat (limited to 'src')
-rw-r--r--src/gui/kernel/qwidget.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gui/kernel/qwidget.cpp b/src/gui/kernel/qwidget.cpp
index a99373a..7a0b047 100644
--- a/src/gui/kernel/qwidget.cpp
+++ b/src/gui/kernel/qwidget.cpp
@@ -10019,7 +10019,7 @@ QWidget *QWidgetPrivate::childAtRecursiveHelper(const QPoint &p, bool ignoreChil
// 'includeFrame' is true if the child's parent is a top-level QMainWindow with an unified tool bar.
// An unified tool bar on the Mac lives outside QMainWindow's geometry(), so a normal
// QWidget::mapFromParent won't do the trick.
- if (includeFrame && qobject_cast<QToolBar *>(child))
+ if (includeFrame && qobject_cast<QToolBar *>(child) && qt_widget_private(child)->isInUnifiedToolbar)
childPoint = qt_mac_nativeMapFromParent(child, p);
else
#endif