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

Iterate over all combos in one loop

GnuPG-bug-id: 5283
parent c3f83b3c
......@@ -819,7 +819,7 @@ public:
const Protocol protocol = currentProtocol();
for (const auto combo: qAsConst(mEncCombos)) {
for (const auto combo: qAsConst(mAllCombos)) {
const auto &key = combo->currentKey();
if (!combo->isVisible()) {
continue;
......@@ -832,21 +832,6 @@ public:
break;
}
}
if (de_vs) {
for (const auto combo: qAsConst(mSigningCombos)) {
const auto key = combo->currentKey();
if (!combo->isVisible()) {
continue;
}
if (protocol != UnknownProtocol && key.protocol() != protocol) {
continue;
}
if (!Formatting::isKeyDeVs(key) || keyValidity(key) < GpgME::UserID::Validity::Full) {
de_vs = false;
break;
}
}
}
mOkButton->setIcon(QIcon::fromTheme(de_vs
? QStringLiteral("security-high")
......
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