diff options
author | saturneric <[email protected]> | 2024-01-15 17:02:40 +0000 |
---|---|---|
committer | saturneric <[email protected]> | 2024-01-15 17:02:40 +0000 |
commit | d54f52ce70cba15f5199e93d3c6fb122143b0526 (patch) | |
tree | f75224f8d020c4c7498bd1ffb97c834e12ec8a2c /src/ui/dialog/keypair_details/KeyPairOperaTab.cpp | |
parent | fix: clean up useless code and make life easier (diff) | |
download | GpgFrontend-d54f52ce70cba15f5199e93d3c6fb122143b0526.tar.gz GpgFrontend-d54f52ce70cba15f5199e93d3c6fb122143b0526.zip |
refactor: remove libconfig++ form project
Diffstat (limited to 'src/ui/dialog/keypair_details/KeyPairOperaTab.cpp')
-rw-r--r-- | src/ui/dialog/keypair_details/KeyPairOperaTab.cpp | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/src/ui/dialog/keypair_details/KeyPairOperaTab.cpp b/src/ui/dialog/keypair_details/KeyPairOperaTab.cpp index df5fc77b..e024b8f0 100644 --- a/src/ui/dialog/keypair_details/KeyPairOperaTab.cpp +++ b/src/ui/dialog/keypair_details/KeyPairOperaTab.cpp @@ -81,16 +81,12 @@ KeyPairOperaTab::KeyPairOperaTab(const QString& key_id, QWidget* parent) auto* advance_h_box_layout = new QHBoxLayout(); - // get settings - auto& settings = GlobalSettingStation::GetInstance().GetMainSettings(); + auto settings = + GpgFrontend::GlobalSettingStation::GetInstance().GetSettings(); + // read settings - bool forbid_all_gnupg_connection = false; - try { - forbid_all_gnupg_connection = - settings.lookup("network.forbid_all_gnupg_connection"); - } catch (...) { - GF_UI_LOG_ERROR("setting operation error: forbid_all_gnupg_connection"); - } + bool forbid_all_gnupg_connection = + settings.value("network/forbid_all_gnupg_connection").toBool(); auto* key_server_opera_button = new QPushButton(_("Key Server Operation (Pubkey)")); |