From 364b5b4600b4ca89c4c739751a5c55d2abd22a88 Mon Sep 17 00:00:00 2001 From: Boleslaw Ciesielski Date: Wed, 4 Sep 2019 12:59:41 -0700 Subject: [PATCH] Fixes Rhoban/Plater#6. Delay deleting a Wizard object and creating a new one until the current one unwinds from the stack (wait until we return to the message loop). --- gui/mainwindow.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gui/mainwindow.cpp b/gui/mainwindow.cpp index e047186..e2821af 100644 --- a/gui/mainwindow.cpp +++ b/gui/mainwindow.cpp @@ -273,7 +273,7 @@ void MainWindow::on_wizard_accept() ui->parts->setText(parts); } - wizardNext(); + QMetaObject::invokeMethod(this, &MainWindow::wizardNext, Qt::QueuedConnection); } void MainWindow::on_saveButton_clicked()