summaryrefslogtreecommitdiffstats
path: root/examples/mainwindows/mdi
diff options
context:
space:
mode:
authorDavid Boddie <dboddie@trolltech.com>2009-11-02 15:11:49 (GMT)
committerDavid Boddie <dboddie@trolltech.com>2009-11-02 15:11:49 (GMT)
commitc4ce16e1eaa4504787f4cc739f3af7d1fdea8351 (patch)
tree1468e5b60bedefe37eacfd3354f6502cf9ec4ee4 /examples/mainwindows/mdi
parent50a745d31e348c113d42444d527b4286b7064e3e (diff)
downloadQt-c4ce16e1eaa4504787f4cc739f3af7d1fdea8351.zip
Qt-c4ce16e1eaa4504787f4cc739f3af7d1fdea8351.tar.gz
Qt-c4ce16e1eaa4504787f4cc739f3af7d1fdea8351.tar.bz2
Fixed main window closing when subwindows cancel their close events.
Reviewed-by: Trust Me Reported-here: http://lists.trolltech.com/pipermail/qt4-preview-feedback /2009-October/001023.html
Diffstat (limited to 'examples/mainwindows/mdi')
-rw-r--r--examples/mainwindows/mdi/mainwindow.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/examples/mainwindows/mdi/mainwindow.cpp b/examples/mainwindows/mdi/mainwindow.cpp
index 712d91f..edb33b7 100644
--- a/examples/mainwindows/mdi/mainwindow.cpp
+++ b/examples/mainwindows/mdi/mainwindow.cpp
@@ -71,7 +71,7 @@ MainWindow::MainWindow()
void MainWindow::closeEvent(QCloseEvent *event)
{
mdiArea->closeAllSubWindows();
- if (activeMdiChild()) {
+ if (mdiArea->currentSubWindow()) {
event->ignore();
} else {
writeSettings();