#5629 Enable activation cancellation dialog

This commit is contained in:
Andrew Nelless 2016-09-29 16:17:38 +01:00
parent 0d5d7e11c0
commit 60a4e62779
3 changed files with 13 additions and 1 deletions

View File

@ -1,5 +1,6 @@
#include "ActivationDialog.h" #include "ActivationDialog.h"
#include "ui_ActivationDialog.h" #include "ui_ActivationDialog.h"
#include "CancelActivationDialog.h"
ActivationDialog::ActivationDialog(QWidget *parent) : ActivationDialog::ActivationDialog(QWidget *parent) :
QDialog(parent), QDialog(parent),
@ -12,3 +13,11 @@ ActivationDialog::~ActivationDialog()
{ {
delete ui; delete ui;
} }
void ActivationDialog::reject()
{
CancelActivationDialog cancelActivationDialog(this);
if (QDialog::Accepted == cancelActivationDialog.exec()) {
QDialog::reject();
}
}

View File

@ -15,6 +15,9 @@ public:
explicit ActivationDialog(QWidget *parent = 0); explicit ActivationDialog(QWidget *parent = 0);
~ActivationDialog(); ~ActivationDialog();
public slots:
void reject();
private: private:
Ui::ActivationDialog *ui; Ui::ActivationDialog *ui;
}; };

View File

@ -1154,7 +1154,7 @@ void MainWindow::on_m_pActionWizard_triggered()
void MainWindow::on_m_pActivate_triggered() void MainWindow::on_m_pActivate_triggered()
{ {
ActivationDialog activationDialog; ActivationDialog activationDialog (this);
activationDialog.exec(); activationDialog.exec();
} }