From 29e70a7d269d3337253eb8245764aef65dbe541f Mon Sep 17 00:00:00 2001 From: Michael Carpenter Date: Tue, 7 Jan 2014 20:16:42 -0500 Subject: [PATCH] Delete all WizardViews on close of MainWindow, so they don't stay open after closing EMStudio --- core/src/mainwindow.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/core/src/mainwindow.cpp b/core/src/mainwindow.cpp index 9465e64..e7dafe8 100644 --- a/core/src/mainwindow.cpp +++ b/core/src/mainwindow.cpp @@ -342,6 +342,8 @@ MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent) windowsettings.endGroup(); + this->setAttribute(Qt::WA_DeleteOnClose,true); + } void MainWindow::menu_windows_interrogateProgressViewClicked() @@ -1964,6 +1966,14 @@ MainWindow::~MainWindow() windowsettings.endGroup(); windowsettings.sync(); + //Remove all WizardView windows + for (int i=0;iclose(); + delete m_wizardList[i]; + } + m_wizardList.clear(); + emsComms->stop(); emsComms->wait(1000); delete emsComms;