summaryrefslogtreecommitdiff
path: root/src/ui/sidebarwidget.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/ui/sidebarwidget.c')
-rw-r--r--src/ui/sidebarwidget.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/ui/sidebarwidget.c b/src/ui/sidebarwidget.c
index db00209f..38c854a2 100644
--- a/src/ui/sidebarwidget.c
+++ b/src/ui/sidebarwidget.c
@@ -359,6 +359,7 @@ static void updateItems_SidebarWidget_(iSidebarWidget *d) {
359 { "Show Usage", 0, 0, "ident.showuse" }, 359 { "Show Usage", 0, 0, "ident.showuse" },
360 { "---", 0, 0, NULL }, 360 { "---", 0, 0, NULL },
361 { "Edit Notes...", 0, 0, "ident.edit" }, 361 { "Edit Notes...", 0, 0, "ident.edit" },
362 { "Copy Fingerprint", 0, 0, "ident.fingerprint" },
362// { "Pick Icon...", 0, 0, "ident.pickicon" }, 363// { "Pick Icon...", 0, 0, "ident.pickicon" },
363 { "---", 0, 0, NULL }, 364 { "---", 0, 0, NULL },
364 //{ "Reveal Files", 0, 0, "ident.reveal" }, 365 //{ "Reveal Files", 0, 0, "ident.reveal" },
@@ -923,6 +924,15 @@ static iBool processEvent_SidebarWidget_(iSidebarWidget *d, const SDL_Event *ev)
923 } 924 }
924 return iTrue; 925 return iTrue;
925 } 926 }
927 else if (isCommand_Widget(w, ev, "ident.fingerprint")) {
928 const iGmIdentity *ident = menuIdentity_SidebarWidget_(d);
929 if (ident) {
930 const iString *fps = collect_String(
931 hexEncode_Block(collect_Block(fingerprint_TlsCertificate(ident->cert))));
932 SDL_SetClipboardText(cstr_String(fps));
933 }
934 return iTrue;
935 }
926 else if (isCommand_Widget(w, ev, "ident.setnotes")) { 936 else if (isCommand_Widget(w, ev, "ident.setnotes")) {
927 iGmIdentity *ident = pointerLabel_Command(cmd, "ident"); 937 iGmIdentity *ident = pointerLabel_Command(cmd, "ident");
928 if (ident) { 938 if (ident) {