summaryrefslogtreecommitdiff
path: root/src/ui/sidebarwidget.c
diff options
context:
space:
mode:
authorJaakko Keränen <jaakko.keranen@iki.fi>2020-10-30 15:03:09 +0200
committerJaakko Keränen <jaakko.keranen@iki.fi>2020-10-30 15:03:09 +0200
commit114e52a60c789c5d1d885a994e8e1bd002b7cc93 (patch)
tree85c9e5281cb2f8066f18394a1db4dfe662dc5316 /src/ui/sidebarwidget.c
parentf22ee7c9ac27fe05649219535a05c21281709607 (diff)
Updating LabelWidget command key
If the key bindings have a key for a command, LabelWidget will use it.
Diffstat (limited to 'src/ui/sidebarwidget.c')
-rw-r--r--src/ui/sidebarwidget.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/ui/sidebarwidget.c b/src/ui/sidebarwidget.c
index f089f48d..d6292f5b 100644
--- a/src/ui/sidebarwidget.c
+++ b/src/ui/sidebarwidget.c
@@ -252,18 +252,16 @@ static void updateItems_SidebarWidget_(iSidebarWidget *d) {
252 iWidget *div = makeVDiv_Widget(); 252 iWidget *div = makeVDiv_Widget();
253 setPadding_Widget(div, 3 * gap_UI, 0, 3 * gap_UI, 2 * gap_UI); 253 setPadding_Widget(div, 3 * gap_UI, 0, 3 * gap_UI, 2 * gap_UI);
254 addChildFlags_Widget(div, iClob(new_Widget()), expand_WidgetFlag); /* pad */ 254 addChildFlags_Widget(div, iClob(new_Widget()), expand_WidgetFlag); /* pad */
255 iLabelWidget *msg = new_LabelWidget("No Identities", 0, 0, NULL); 255 iLabelWidget *msg = new_LabelWidget("No Identities", NULL);
256 setFont_LabelWidget(msg, uiLabelLarge_FontId); 256 setFont_LabelWidget(msg, uiLabelLarge_FontId);
257 addChildFlags_Widget(div, iClob(msg), frameless_WidgetFlag); 257 addChildFlags_Widget(div, iClob(msg), frameless_WidgetFlag);
258 addChild_Widget(div, iClob(makePadding_Widget(3 * gap_UI))); 258 addChild_Widget(div, iClob(makePadding_Widget(3 * gap_UI)));
259 addChild_Widget(div, iClob(new_LabelWidget("New Identity...", 0, 0, "ident.new"))); 259 addChild_Widget(div, iClob(new_LabelWidget("New Identity...", "ident.new")));
260 addChildFlags_Widget(div, iClob(new_Widget()), expand_WidgetFlag); /* pad */ 260 addChildFlags_Widget(div, iClob(new_Widget()), expand_WidgetFlag); /* pad */
261 addChildFlags_Widget( 261 addChildFlags_Widget(
262 div, 262 div,
263 iClob(new_LabelWidget("See " uiTextStrong_ColorEscape "Help" uiText_ColorEscape 263 iClob(new_LabelWidget("See " uiTextStrong_ColorEscape "Help" uiText_ColorEscape
264 " for more information about TLS client certificates.", 264 " for more information about TLS client certificates.",
265 0,
266 0,
267 "!open newtab:1 gotoheading:Identities url:about:help")), 265 "!open newtab:1 gotoheading:Identities url:about:help")),
268 frameless_WidgetFlag | fixedHeight_WidgetFlag | wrapText_WidgetFlag); 266 frameless_WidgetFlag | fixedHeight_WidgetFlag | wrapText_WidgetFlag);
269 addChild_Widget(d->blank, iClob(div)); 267 addChild_Widget(d->blank, iClob(div));
@@ -336,7 +334,7 @@ void init_SidebarWidget(iSidebarWidget *d) {
336 d->modeButtons[i] = addChildFlags_Widget( 334 d->modeButtons[i] = addChildFlags_Widget(
337 buttons, 335 buttons,
338 iClob( 336 iClob(
339 new_LabelWidget(tightModeLabels_[i], 0, 0, format_CStr("sidebar.mode arg:%d", i))), 337 new_LabelWidget(tightModeLabels_[i], format_CStr("sidebar.mode arg:%d", i))),
340 frameless_WidgetFlag); 338 frameless_WidgetFlag);
341 d->maxButtonLabelWidth = 339 d->maxButtonLabelWidth =
342 iMaxi(d->maxButtonLabelWidth, 340 iMaxi(d->maxButtonLabelWidth,