aboutsummaryrefslogtreecommitdiffstats
path: root/src/ui/keypair_details/KeyUIDSignDialog.cpp
diff options
context:
space:
mode:
authorSaturneric <[email protected]>2021-05-28 19:21:46 +0000
committerSaturneric <[email protected]>2021-05-28 19:21:46 +0000
commita5c3aa5ceff300cad9203f3620f16920e726a762 (patch)
treebb375530f126f29746f4f4aa10985831beefec79 /src/ui/keypair_details/KeyUIDSignDialog.cpp
parentAdjust part of the text of the UI interface of the UID operation tab. (diff)
downloadGpgFrontend-a5c3aa5ceff300cad9203f3620f16920e726a762.tar.gz
GpgFrontend-a5c3aa5ceff300cad9203f3620f16920e726a762.zip
Make eligible keys enter the signature candidate list.
Added delete UID interface and function. Added setting as the main UID function. Added the delete key signature menu and function (there is a problem). Improve the presentation of key list items Improve the page function of KeyList. Added pop-up menu for UID list operation on UIDTab interface. Signed-off-by: Saturneric <[email protected]>
Diffstat (limited to '')
-rw-r--r--src/ui/keypair_details/KeyUIDSignDialog.cpp10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/ui/keypair_details/KeyUIDSignDialog.cpp b/src/ui/keypair_details/KeyUIDSignDialog.cpp
index 64a15865..cb4056b3 100644
--- a/src/ui/keypair_details/KeyUIDSignDialog.cpp
+++ b/src/ui/keypair_details/KeyUIDSignDialog.cpp
@@ -12,6 +12,10 @@ KeyUIDSignDialog::KeyUIDSignDialog(GpgME::GpgContext *ctx, const GpgKey &key, co
KeyListColumn::NAME | KeyListColumn::EmailAddress,
this);
+ mKeyList->setFilter([](const GpgKey &key) -> bool {
+ if(key.disabled || !key.can_sign) return false;
+ else return true;
+ });
mKeyList->setExcludeKeys({key.id});
mKeyList->slotRefresh();
@@ -73,9 +77,9 @@ void KeyUIDSignDialog::slotSignKey(bool clicked) {
// Sign For mKey
if (!mCtx->signKey(mKey, uid.uid, &expires)) {
QMessageBox::critical(nullptr,
- tr("Operation Unsuccessful"),
- QString("%1 <%2>"+tr(" signature operation failed for UID ") + "%3")
- .arg(mKey.name, mKey.email, uid.uid));
+ tr("Unsuccessful Operation"),
+ QString(tr("Signature operation failed for UID ") + "%1")
+ .arg(uid.uid));
}
}