diff options
author | Saturn&Eric <[email protected]> | 2023-04-08 08:58:02 +0000 |
---|---|---|
committer | GitHub <[email protected]> | 2023-04-08 08:58:02 +0000 |
commit | 344096f325d686cf9810df6764fdb10ec8709d4a (patch) | |
tree | c629f58099a7e01084cb0fc09a165e1cf858ed9e /src/core/GpgContext.cpp | |
parent | Merge pull request #95 from saturneric/dev/2.1.0/main (diff) | |
parent | feat: update the online translation way (diff) | |
download | GpgFrontend-344096f325d686cf9810df6764fdb10ec8709d4a.tar.gz GpgFrontend-344096f325d686cf9810df6764fdb10ec8709d4a.zip |
Merge pull request #96 from saturneric/dev/2.1.0/main
Develop 2.1.1.2
Diffstat (limited to 'src/core/GpgContext.cpp')
-rw-r--r-- | src/core/GpgContext.cpp | 19 |
1 files changed, 3 insertions, 16 deletions
diff --git a/src/core/GpgContext.cpp b/src/core/GpgContext.cpp index 47ff77c4..1cb137e6 100644 --- a/src/core/GpgContext.cpp +++ b/src/core/GpgContext.cpp @@ -30,6 +30,7 @@ #include <gpg-error.h> #include <gpgme.h> +#include <spdlog/spdlog.h> #include <unistd.h> #include <mutex> @@ -37,14 +38,11 @@ #include <string> #include "core/GpgConstants.h" -#include "core/GpgModel.h" #include "core/common/CoreCommonUtil.h" #include "core/function/CoreSignalStation.h" -#include "core/function/GlobalSettingStation.h" #include "core/function/gpg/GpgCommandExecutor.h" +#include "core/thread/Task.h" #include "core/thread/TaskRunnerGetter.h" -#include "spdlog/spdlog.h" -#include "thread/Task.h" #ifdef _WIN32 #include <windows.h> @@ -232,19 +230,8 @@ void GpgContext::post_init_ctx() { // preload info auto &info = GetInfo(); - auto &settings = GlobalSettingStation::GetInstance().GetUISettings(); - - bool use_pinentry_as_password_input_dialog = false; - try { - use_pinentry_as_password_input_dialog = - settings.lookup("general.use_pinentry_as_password_input_dialog"); - } catch (...) { - SPDLOG_ERROR( - "setting operation error: use_pinentry_as_password_input_dialog"); - } - // use custom qt dialog to replace pinentry - if (!use_pinentry_as_password_input_dialog) { + if (!args_.use_pinentry) { SetPassphraseCb(custom_passphrase_cb); } |