diff options
author | Saturneric <[email protected]> | 2021-07-16 10:02:06 +0000 |
---|---|---|
committer | Saturneric <[email protected]> | 2021-07-16 10:02:06 +0000 |
commit | b951a010548cf052d4de5480abb30163460c5020 (patch) | |
tree | 8b2a3037f5c203798a0d9a44bef4b174ead3ce62 /src/ui/main_window/MainWindowSlotFunction.cpp | |
parent | Add send mail function and its settings. (diff) | |
download | GpgFrontend-b951a010548cf052d4de5480abb30163460c5020.tar.gz GpgFrontend-b951a010548cf052d4de5480abb30163460c5020.zip |
Improve the function of sending mail; update the version number;
Diffstat (limited to '')
-rw-r--r-- | src/ui/main_window/MainWindowSlotFunction.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/ui/main_window/MainWindowSlotFunction.cpp b/src/ui/main_window/MainWindowSlotFunction.cpp index 4bb3a02b..cc8adb6f 100644 --- a/src/ui/main_window/MainWindowSlotFunction.cpp +++ b/src/ui/main_window/MainWindowSlotFunction.cpp @@ -87,7 +87,13 @@ void MainWindow::slotEncrypt() { if (resultAnalyse->getStatus() >= 0) { infoBoard->resetOptionActionsMenu(); infoBoard->addOptionalAction("Send Mail", [this]() { - new SendMailDialog(this); + if(settings.value("sendMail/enable", false).toBool()) + new SendMailDialog(edit->curTextPage()->toPlainText(), this); + else { + QMessageBox::warning(nullptr, + tr("Function Disabled"), + tr("Please go to the settings interface to enable and configure this function.")); + } }); } |