summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel/qwindow.cpp
diff options
context:
space:
mode:
authorStephen Kelly <stephen.kelly@kdab.com>2012-02-11 01:10:07 +0100
committerQt by Nokia <qt-info@nokia.com>2012-02-15 20:47:32 +0100
commit394315d902d9068a53439737906c00d48023d182 (patch)
tree7d5d09f1b4386fefdbe702a33ab8e30e08739758 /src/gui/kernel/qwindow.cpp
parentc455674555b263c98fe613612babab3efcf10345 (diff)
Move the removal of the Quit event to QWindow.
Change-Id: If524127ba9dab9ef065aaf4079294295eef8e49b Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
Diffstat (limited to 'src/gui/kernel/qwindow.cpp')
-rw-r--r--src/gui/kernel/qwindow.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/gui/kernel/qwindow.cpp b/src/gui/kernel/qwindow.cpp
index 43b7e39103..61ae2a2438 100644
--- a/src/gui/kernel/qwindow.cpp
+++ b/src/gui/kernel/qwindow.cpp
@@ -178,6 +178,9 @@ void QWindow::setVisible(bool visible)
create();
if (visible) {
+ // remove posted quit events when showing a new window
+ QCoreApplication::removePostedEvents(qApp, QEvent::Quit);
+
QShowEvent showEvent;
QGuiApplication::sendEvent(this, &showEvent);
}