diff options
author | saturneric <[email protected]> | 2023-10-25 14:28:25 +0000 |
---|---|---|
committer | saturneric <[email protected]> | 2023-10-25 14:28:25 +0000 |
commit | b7ceed0b87752077fe19fefe9b0df8ec27ce0531 (patch) | |
tree | 51cb5f2a9210dabaa585b65d085f336cc5f0f844 /src/ui/UserInterfaceUtils.cpp | |
parent | fix: solve some code tidy issues (diff) | |
download | GpgFrontend-b7ceed0b87752077fe19fefe9b0df8ec27ce0531.tar.gz GpgFrontend-b7ceed0b87752077fe19fefe9b0df8ec27ce0531.zip |
feat: moving gnupg info gathering logic to a new module
Diffstat (limited to 'src/ui/UserInterfaceUtils.cpp')
-rw-r--r-- | src/ui/UserInterfaceUtils.cpp | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/ui/UserInterfaceUtils.cpp b/src/ui/UserInterfaceUtils.cpp index 63a78873..5b92ffc0 100644 --- a/src/ui/UserInterfaceUtils.cpp +++ b/src/ui/UserInterfaceUtils.cpp @@ -40,12 +40,13 @@ #include "core/function/FileOperator.h" #include "core/function/GlobalSettingStation.h" #include "core/function/gpg/GpgKeyGetter.h" +#include "core/module/ModuleManager.h" #include "core/thread/Task.h" #include "core/thread/TaskRunner.h" #include "core/thread/TaskRunnerGetter.h" -#include "dialog/gnupg/GnuPGControllerDialog.h" #include "ui/SignalStation.h" #include "ui/dialog/WaitingDialog.h" +#include "ui/dialog/gnupg/GnuPGControllerDialog.h" #include "ui/struct/SettingsObject.h" #include "ui/widgets/TextEdit.h" @@ -325,8 +326,11 @@ void CommonUtils::SlotExecuteGpgCommand( _("Finished executing command.")); }); - gpg_process->setProgram( - GpgContext::GetInstance().GetInfo(false).AppPath.c_str()); + const auto app_path = Module::RetrieveRTValueTypedOrDefault<>( + "core", "gpgme.ctx.app_path", std::string{}); + SPDLOG_DEBUG("got gnupg app path from rt: {}", app_path); + + gpg_process->setProgram(app_path.c_str()); gpg_process->setArguments(arguments); gpg_process->start(); looper.exec(); |