Make key generation dialog in Identity page modal

Prevents closing the identity dialog while key generation is in
progress, which lead to crash.
wilder-work
Daniel Vrátil 9 years ago
parent a9bf0addb0
commit 792264dd66
  1. 3
      src/identity/identitydialog.cpp

@ -265,7 +265,8 @@ void KeySelectionCombo::onCustomItemSelected(const QVariant &type)
return;
} else if (type == QLatin1String("generate-new-key")) {
auto job = new KeyGenerationJob(mName, mEmail, this);
new Kleo::ProgressDialog(job, i18n("Generating new key pair..."), parentWidget());
auto dlg = new Kleo::ProgressDialog(job, i18n("Generating new key pair..."), parentWidget());
dlg->setModal(true);
setEnabled(false);
connect(job, &KeyGenerationJob::done,
this, [this]() {

Loading…
Cancel
Save