aboutsummaryrefslogtreecommitdiffstats
path: root/src/ui/main_window/MainWindowFileSlotFunction.cpp
diff options
context:
space:
mode:
authorsaturneric <[email protected]>2023-12-24 10:16:45 +0000
committersaturneric <[email protected]>2023-12-24 10:16:45 +0000
commite52215cd31237bcfe343754bdfcfdde65e804432 (patch)
tree91c4bbbe5d86ffaddd6f111bfa6e27aff1b644a0 /src/ui/main_window/MainWindowFileSlotFunction.cpp
parentfix: test the encrypt async api on gui app (diff)
downloadGpgFrontend-e52215cd31237bcfe343754bdfcfdde65e804432.tar.gz
GpgFrontend-e52215cd31237bcfe343754bdfcfdde65e804432.zip
fix: use the new async encrypt symmetric api at gui app
Diffstat (limited to 'src/ui/main_window/MainWindowFileSlotFunction.cpp')
-rw-r--r--src/ui/main_window/MainWindowFileSlotFunction.cpp22
1 files changed, 12 insertions, 10 deletions
diff --git a/src/ui/main_window/MainWindowFileSlotFunction.cpp b/src/ui/main_window/MainWindowFileSlotFunction.cpp
index fc9401c8..f26a9587 100644
--- a/src/ui/main_window/MainWindowFileSlotFunction.cpp
+++ b/src/ui/main_window/MainWindowFileSlotFunction.cpp
@@ -227,16 +227,18 @@ void MainWindow::SlotFileEncrypt() {
if (ret == QMessageBox::Cancel) return;
- process_operation(
- this, _("Symmetrically Encrypting"), [&](DataObjectPtr) -> int {
- try {
- error = GpgFrontend::GpgFileOpera::EncryptFileSymmetric(
- path.toStdString(), out_path.toStdString(), result, _channel);
- } catch (const std::runtime_error& e) {
- if_error = true;
- }
- return 0;
- });
+ process_operation(this, _("Symmetrically Encrypting"),
+ [&](DataObjectPtr) -> int {
+ try {
+ // error =
+ // GpgFrontend::GpgFileOpera::EncryptFileSymmetric(
+ // path.toStdString(), out_path.toStdString(),
+ // result, _channel);
+ } catch (const std::runtime_error& e) {
+ if_error = true;
+ }
+ return 0;
+ });
} else {
auto p_keys = GpgKeyGetter::GetInstance().GetKeys(key_ids);