diff options
author | Saturn&Eric <[email protected]> | 2022-05-09 15:58:36 +0000 |
---|---|---|
committer | GitHub <[email protected]> | 2022-05-09 15:58:36 +0000 |
commit | a1bef0cc06a5c128a0f868ab59d7c153f5ab8aec (patch) | |
tree | f55b3c76f4203590b4bf40b6ab2f97965f5a51ec /src/ui/key_generate/KeygenDialog.cpp | |
parent | Merge pull request #56 from saturneric/develop-2.0.6 (diff) | |
parent | fix: modified init order (diff) | |
download | GpgFrontend-a1bef0cc06a5c128a0f868ab59d7c153f5ab8aec.tar.gz GpgFrontend-a1bef0cc06a5c128a0f868ab59d7c153f5ab8aec.zip |
Merge pull request #57 from saturneric/develop-2.0.7v2.0.7
Develop 2.0.7
Diffstat (limited to '')
-rw-r--r-- | src/ui/key_generate/KeygenDialog.cpp | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/src/ui/key_generate/KeygenDialog.cpp b/src/ui/key_generate/KeygenDialog.cpp index 6df0bcf0..676539c7 100644 --- a/src/ui/key_generate/KeygenDialog.cpp +++ b/src/ui/key_generate/KeygenDialog.cpp @@ -28,10 +28,10 @@ #include "ui/key_generate/KeygenDialog.h" -#include "dialog/WaitingDialog.h" +#include "core/function/GlobalSettingStation.h" #include "core/function/gpg/GpgKeyOpera.h" +#include "dialog/WaitingDialog.h" #include "ui/SignalStation.h" -#include "core/function/GlobalSettingStation.h" namespace GpgFrontend::UI { @@ -144,15 +144,19 @@ void KeyGenDialog::slot_key_gen_accept() { dialog->close(); + LOG(INFO) << "generate done"; + if (gpgme_err_code(error) == GPG_ERR_NO_ERROR) { - auto* msg_box = new QMessageBox(nullptr); + auto* msg_box = new QMessageBox((QWidget*)this->parent()); msg_box->setAttribute(Qt::WA_DeleteOnClose); msg_box->setStandardButtons(QMessageBox::Ok); msg_box->setWindowTitle(_("Success")); msg_box->setText(_("The new key pair has been generated.")); - msg_box->setModal(false); + msg_box->setModal(true); msg_box->open(); + LOG(INFO) << "generate success"; + emit SignalKeyGenerated(); this->close(); } else { |