Commit a633f864 authored by Ingo Klöcker's avatar Ingo Klöcker
Browse files

Set value of OpenPGP keyserver field only if config entry is set

stringValue() returns the default value if no value is set for the
config entry. To make it more obvious that the config entry is not set
clear the value of the line edit, so that the placeholder showing
the default value of the config entry is shown.

GnuPG-bug-id: 5514
parent 1520a1da
Pipeline #67935 passed with stage
in 15 minutes and 35 seconds
......@@ -261,7 +261,7 @@ void DirectoryServicesConfigurationPage::load()
<< s_pgpservice_componentName << "/" << s_pgpservice_entryName;
}
mOpenPGPKeyserverEdit->setText(mOpenPGPServiceEntry ? mOpenPGPServiceEntry->stringValue() : QString());
mOpenPGPKeyserverEdit->setText(mOpenPGPServiceEntry && mOpenPGPServiceEntry->isSet() ? mOpenPGPServiceEntry->stringValue() : QString());
mOpenPGPKeyserverEdit->setEnabled(mOpenPGPServiceEntry && !mOpenPGPServiceEntry->isReadOnly());
#ifdef QGPGME_CRYPTOCONFIGENTRY_HAS_DEFAULT_VALUE
if (newEntry && !newEntry->defaultValue().isNull()) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment