diff options
author | saturneric <[email protected]> | 2025-04-18 17:56:51 +0000 |
---|---|---|
committer | saturneric <[email protected]> | 2025-04-18 17:56:51 +0000 |
commit | a7ea8e6de4bb205d2a3783d5cb9bde8bee0086b9 (patch) | |
tree | 54838273836a155033d33b246ec4a4200291825b /src/ui/main_window/KeyMgmt.cpp | |
parent | fix: issues found by testing (diff) | |
parent | fix: spelling mistake on project config by nightly build (diff) | |
download | GpgFrontend-a7ea8e6de4bb205d2a3783d5cb9bde8bee0086b9.tar.gz GpgFrontend-a7ea8e6de4bb205d2a3783d5cb9bde8bee0086b9.zip |
Merge branch 'develop'
Diffstat (limited to 'src/ui/main_window/KeyMgmt.cpp')
-rw-r--r-- | src/ui/main_window/KeyMgmt.cpp | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/src/ui/main_window/KeyMgmt.cpp b/src/ui/main_window/KeyMgmt.cpp index e3128231..f9364ecf 100644 --- a/src/ui/main_window/KeyMgmt.cpp +++ b/src/ui/main_window/KeyMgmt.cpp @@ -428,12 +428,20 @@ void KeyMgmt::SlotExportKeyToClipboard() { } void KeyMgmt::SlotGenerateKeyDialog() { - (new KeyGenerateDialog(key_list_->GetCurrentGpgContextChannel(), this)) - ->exec(); - this->raise(); + if (!CheckGpgVersion(key_list_->GetCurrentGpgContextChannel(), "2.2.0")) { + CommonUtils::RaiseMessageBoxNotSupported(this); + return; + } + + new KeyGenerateDialog(key_list_->GetCurrentGpgContextChannel(), this); } void KeyMgmt::SlotGenerateSubKey() { + if (!CheckGpgVersion(key_list_->GetCurrentGpgContextChannel(), "2.2.0")) { + CommonUtils::RaiseMessageBoxNotSupported(this); + return; + } + auto key = key_list_->GetSelectedGpgKey(); if (key == nullptr) return; @@ -444,10 +452,7 @@ void KeyMgmt::SlotGenerateSubKey() { return; } - (new SubkeyGenerateDialog(key_list_->GetCurrentGpgContextChannel(), key, - this)) - ->exec(); - this->raise(); + new SubkeyGenerateDialog(key_list_->GetCurrentGpgContextChannel(), key, this); } void KeyMgmt::SlotExportAsOpenSSHFormat() { |