diff options
author | Eskil Abrahamsen Blomfeldt <eblomfel@trolltech.com> | 2010-02-15 10:22:25 (GMT) |
---|---|---|
committer | Eskil Abrahamsen Blomfeldt <eblomfel@trolltech.com> | 2010-02-15 10:22:25 (GMT) |
commit | 8197e5fae939c264220666162fe9ecb624e47bef (patch) | |
tree | 08ad63b681ff701d568d771784c97be1c6274dbd /src/gui/widgets/qmainwindow.cpp | |
parent | 9f387357a7e171636c97a7ef13afca60c01a9e3b (diff) | |
parent | 4a47bf6a06a4f7ebbf2336cd643c50332ac76d6d (diff) | |
download | Qt-8197e5fae939c264220666162fe9ecb624e47bef.zip Qt-8197e5fae939c264220666162fe9ecb624e47bef.tar.gz Qt-8197e5fae939c264220666162fe9ecb624e47bef.tar.bz2 |
Merge branch 'master' of scm.dev.troll.no:qt/oslo-staging-2 into qstatictext-4.7
Conflicts:
src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp
tests/auto/qlineedit/tst_qlineedit.cpp
Merge branch 'master' of scm.dev.troll.no:qt/oslo-staging-2 into qstatictext-4.7
Conflicts:
src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp
tests/auto/qlineedit/tst_qlineedit.cpp
Merge branch 'master' of scm.dev.troll.no:qt/oslo-staging-2 into qstatictext-4.7
Conflicts:
src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp
tests/auto/qlineedit/tst_qlineedit.cpp
Diffstat (limited to 'src/gui/widgets/qmainwindow.cpp')
-rw-r--r-- | src/gui/widgets/qmainwindow.cpp | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/src/gui/widgets/qmainwindow.cpp b/src/gui/widgets/qmainwindow.cpp index 269cd12..a63f3bf 100644 --- a/src/gui/widgets/qmainwindow.cpp +++ b/src/gui/widgets/qmainwindow.cpp @@ -1393,6 +1393,7 @@ bool QMainWindow::event(QEvent *event) #endif // QT_NO_STATUSTIP case QEvent::StyleChange: + d->layout->layoutState.dockAreaLayout.styleChangedEvent(); if (!d->explicitIconSize) setIconSize(QSize()); break; @@ -1554,11 +1555,15 @@ void QMainWindow::contextMenuEvent(QContextMenuEvent *event) #ifndef QT_NO_MENU QMenu *popup = createPopupMenu(); - if (popup && !popup->isEmpty()) { - popup->exec(event->globalPos()); - event->accept(); + if (popup) { + if (!popup->isEmpty()) { + popup->setAttribute(Qt::WA_DeleteOnClose); + popup->popup(event->globalPos()); + event->accept(); + } else { + delete popup; + } } - delete popup; #endif } #endif // QT_NO_CONTEXTMENU |