summaryrefslogtreecommitdiffstats
path: root/src/widgets/kernel/qwidget.cpp
diff options
context:
space:
mode:
authorFrederik Gladhorn <frederik.gladhorn@theqtcompany.com>2014-11-24 13:37:06 +0100
committerFrederik Gladhorn <frederik.gladhorn@theqtcompany.com>2014-11-24 13:39:13 +0100
commit34aba4724f196e34ed02cf50073f41968f119bb6 (patch)
tree0ebdfcabda989ab76ee6de53c6461553c7a767a5 /src/widgets/kernel/qwidget.cpp
parentb86b2a742afae118bf974c82ba966ddb0cae4afb (diff)
parentb1cf07f495e10c93e53651ac03e46ebdaea0a97e (diff)
Merge remote-tracking branch 'origin/5.4' into dev
Conflicts: src/corelib/io/qiodevice.cpp src/plugins/bearer/linux_common/qofonoservice_linux.cpp src/plugins/bearer/linux_common/qofonoservice_linux_p.h src/plugins/platforms/android/qandroidplatformtheme.cpp src/tools/bootstrap/bootstrap.pro src/widgets/styles/qmacstyle_mac.mm Change-Id: Ia02aab6c4598ce74e9c30bb4666d5e2ef000f99b
Diffstat (limited to 'src/widgets/kernel/qwidget.cpp')
-rw-r--r--src/widgets/kernel/qwidget.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/widgets/kernel/qwidget.cpp b/src/widgets/kernel/qwidget.cpp
index 63497ce745..7f2e5a5e17 100644
--- a/src/widgets/kernel/qwidget.cpp
+++ b/src/widgets/kernel/qwidget.cpp
@@ -1403,6 +1403,8 @@ void QWidgetPrivate::create_sys(WId window, bool initializeWindow, bool destroyO
if (q->testAttribute(Qt::WA_ShowWithoutActivating))
win->setProperty("_q_showWithoutActivating", QVariant(true));
+ if (q->testAttribute(Qt::WA_MacAlwaysShowToolWindow))
+ win->setProperty("_q_macAlwaysShowToolWindow", QVariant::fromValue(QVariant(true)));
win->setFlags(data.window_flags);
fixPosIncludesFrame();
if (q->testAttribute(Qt::WA_Moved)
@@ -7151,10 +7153,7 @@ void QWidgetPrivate::setGeometry_sys(int x, int y, int w, int h, bool isMove)
}
}
- // generate a move event for QWidgets without window handles. QWidgets with native
- // window handles already receive a move event from
- // QGuiApplicationPrivate::processGeometryChangeEvent.
- if (isMove && (!q->windowHandle() || q->testAttribute(Qt::WA_DontShowOnScreen))) {
+ if (isMove) {
QMoveEvent e(q->pos(), oldPos);
QApplication::sendEvent(q, &e);
}
@@ -10510,8 +10509,9 @@ void QWidgetPrivate::setParent_sys(QWidget *newparent, Qt::WindowFlags f)
QWidget *parentWithWindow =
newparent ? (newparent->windowHandle() ? newparent : newparent->nativeParentWidget()) : 0;
if (parentWithWindow) {
- if (f & Qt::Window) {
- q->windowHandle()->setTransientParent(parentWithWindow->windowHandle());
+ QWidget *topLevel = parentWithWindow->window();
+ if ((f & Qt::Window) && topLevel && topLevel->windowHandle()) {
+ q->windowHandle()->setTransientParent(topLevel->windowHandle());
q->windowHandle()->setParent(0);
} else {
q->windowHandle()->setTransientParent(0);