summaryrefslogtreecommitdiff
path: root/src/ui/mobile.c
diff options
context:
space:
mode:
authorJaakko Keränen <jaakko.keranen@iki.fi>2021-12-02 15:25:22 +0200
committerJaakko Keränen <jaakko.keranen@iki.fi>2021-12-02 15:25:22 +0200
commit50c5abbbeab07e3ccd67da5caafe7325467f1396 (patch)
tree051e06dcbecab50fcf9c37f5b6db483f5604bef5 /src/ui/mobile.c
parent8269c38f074cb991e79430bd2ae9fe892d412635 (diff)
Avoid capitalizing headings in .po files
All-caps should be applied at runtime when appropriate.
Diffstat (limited to 'src/ui/mobile.c')
-rw-r--r--src/ui/mobile.c15
1 files changed, 14 insertions, 1 deletions
diff --git a/src/ui/mobile.c b/src/ui/mobile.c
index c7b75d3f..9e4fef84 100644
--- a/src/ui/mobile.c
+++ b/src/ui/mobile.c
@@ -23,6 +23,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */
23#include "mobile.h" 23#include "mobile.h"
24 24
25#include "app.h" 25#include "app.h"
26#include "certlistwidget.h"
26#include "command.h" 27#include "command.h"
27#include "defs.h" 28#include "defs.h"
28#include "inputwidget.h" 29#include "inputwidget.h"
@@ -196,6 +197,8 @@ static iBool topPanelHandler_(iWidget *topPanel, const char *cmd) {
196 setText_LabelWidget(detailTitle, text_LabelWidget((iLabelWidget *) findTitleLabel_(panel))); 197 setText_LabelWidget(detailTitle, text_LabelWidget((iLabelWidget *) findTitleLabel_(panel)));
197 setFlags_Widget(button, selected_WidgetFlag, iTrue); 198 setFlags_Widget(button, selected_WidgetFlag, iTrue);
198 postCommand_Widget(topPanel, "panel.changed arg:%d", panelIndex); 199 postCommand_Widget(topPanel, "panel.changed arg:%d", panelIndex);
200 //printTree_Widget(findDetailStack_(topPanel));
201// updateVisible_ListWidget(findChild_Widget(findDetailStack_(topPanel), "certlist"));
199 return iTrue; 202 return iTrue;
200 } 203 }
201 if (equal_Command(cmd, "swipe.back")) { 204 if (equal_Command(cmd, "swipe.back")) {
@@ -482,7 +485,7 @@ void makePanelItem_Mobile(iWidget *panel, const iMenuItem *item) {
482 collapse_WidgetFlag); 485 collapse_WidgetFlag);
483 setFont_LabelWidget(title, uiLabelLargeBold_FontId); 486 setFont_LabelWidget(title, uiLabelLargeBold_FontId);
484 setTextColor_LabelWidget(title, uiHeading_ColorId); 487 setTextColor_LabelWidget(title, uiHeading_ColorId);
485 setAllCaps_LabelWidget(title, iTrue); 488// setAllCaps_LabelWidget(title, iTrue);
486 setId_Widget(as_Widget(title), id); 489 setId_Widget(as_Widget(title), id);
487 } 490 }
488 else if (equal_Command(spec, "heading")) { 491 else if (equal_Command(spec, "heading")) {
@@ -609,6 +612,16 @@ void makePanelItem_Mobile(iWidget *panel, const iMenuItem *item) {
609 setUserData_Object(widget, input); 612 setUserData_Object(widget, input);
610 } 613 }
611 } 614 }
615 else if (equal_Command(spec, "certlist")) {
616 iCertListWidget *certList = new_CertListWidget();
617 iListWidget *list = (iListWidget *) certList;
618 setBackgroundColor_Widget(as_Widget(list), uiBackgroundSidebar_ColorId);
619 widget = as_Widget(certList);
620 updateItems_CertListWidget(certList);
621 invalidate_ListWidget(list);
622 setFixedSize_Widget(widget,
623 init_I2(-1, numItems_ListWidget(list) * itemHeight_ListWidget(list)));
624 }
612 else if (equal_Command(spec, "button")) { 625 else if (equal_Command(spec, "button")) {
613 widget = as_Widget(heading = makePanelButton_(label, item->command)); 626 widget = as_Widget(heading = makePanelButton_(label, item->command));
614 setFlags_Widget(widget, selected_WidgetFlag, argLabel_Command(spec, "selected") != 0); 627 setFlags_Widget(widget, selected_WidgetFlag, argLabel_Command(spec, "selected") != 0);