From c7d7886d0e2c83abc897ced71d77a6ee12375e5d Mon Sep 17 00:00:00 2001 From: Josef Rokos Date: Tue, 15 Aug 2017 13:26:56 +0200 Subject: [PATCH] Camp wizard is now accepted on close report preview. --- camp/campwizard.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/camp/campwizard.cpp b/camp/campwizard.cpp index 4593799..6cf951e 100644 --- a/camp/campwizard.cpp +++ b/camp/campwizard.cpp @@ -487,6 +487,11 @@ void CampWizard::on_btnPrint_clicked() filler.fill(report, m_data->id()); ReportViewer *viewer = new ReportViewer(this); + viewer->setAttribute(Qt::WA_DeleteOnClose); viewer->setReport(report); viewer->openPreview(); + + connect(viewer, &QDialog::finished, [this](int){ + this->accept(); + }); }