summaryrefslogtreecommitdiff
path: root/src/ui
diff options
context:
space:
mode:
authorJaakko Keränen <jaakko.keranen@iki.fi>2021-10-01 16:31:08 +0300
committerJaakko Keränen <jaakko.keranen@iki.fi>2021-10-01 16:31:08 +0300
commit5c7417c547b84c30eee42fce57cb09e0552ac34f (patch)
treed9ceff958b3fa5e82234cfc9eb407b2f8f4c4b46 /src/ui
parentb60715722cceea893167a619613f79945f346885 (diff)
Added feeds update progress indicator
Show some status info about the progress of feed refresh. The search query and feeds indicators now use the small UI font size.
Diffstat (limited to 'src/ui')
-rw-r--r--src/ui/root.c12
-rw-r--r--src/ui/widget.c2
2 files changed, 11 insertions, 3 deletions
diff --git a/src/ui/root.c b/src/ui/root.c
index adc18870..253d0cfb 100644
--- a/src/ui/root.c
+++ b/src/ui/root.c
@@ -1149,9 +1149,10 @@ void createUserInterface_Root(iRoot *d) {
1149 iLabelWidget *queryInd = new_LabelWidget("${status.query} " return_Icon, NULL); 1149 iLabelWidget *queryInd = new_LabelWidget("${status.query} " return_Icon, NULL);
1150 setId_Widget(as_Widget(queryInd), "input.indicator.search"); 1150 setId_Widget(as_Widget(queryInd), "input.indicator.search");
1151 setTextColor_LabelWidget(queryInd, uiTextAction_ColorId); 1151 setTextColor_LabelWidget(queryInd, uiTextAction_ColorId);
1152 setFont_LabelWidget(queryInd, defaultSmall_FontId);
1152 setBackgroundColor_Widget(as_Widget(queryInd), uiBackground_ColorId); 1153 setBackgroundColor_Widget(as_Widget(queryInd), uiBackground_ColorId);
1153 setFrameColor_Widget(as_Widget(queryInd), uiTextAction_ColorId); 1154 setFrameColor_Widget(as_Widget(queryInd), uiTextAction_ColorId);
1154 setAlignVisually_LabelWidget(queryInd, iTrue); 1155// setAlignVisually_LabelWidget(queryInd, iTrue);
1155 setNoAutoMinHeight_LabelWidget(queryInd, iTrue); 1156 setNoAutoMinHeight_LabelWidget(queryInd, iTrue);
1156 addChildFlags_Widget(rightEmbed, 1157 addChildFlags_Widget(rightEmbed,
1157 iClob(queryInd), 1158 iClob(queryInd),
@@ -1161,9 +1162,16 @@ void createUserInterface_Root(iRoot *d) {
1161 iLabelWidget *fprog = new_LabelWidget("", NULL); 1162 iLabelWidget *fprog = new_LabelWidget("", NULL);
1162 setId_Widget(as_Widget(fprog), "feeds.progress"); 1163 setId_Widget(as_Widget(fprog), "feeds.progress");
1163 setTextColor_LabelWidget(fprog, uiTextCaution_ColorId); 1164 setTextColor_LabelWidget(fprog, uiTextCaution_ColorId);
1165 setFont_LabelWidget(fprog, defaultSmall_FontId);
1164 setBackgroundColor_Widget(as_Widget(fprog), uiBackground_ColorId); 1166 setBackgroundColor_Widget(as_Widget(fprog), uiBackground_ColorId);
1165 setAlignVisually_LabelWidget(fprog, iTrue); 1167// setAlignVisually_LabelWidget(fprog, iTrue);
1166 setNoAutoMinHeight_LabelWidget(fprog, iTrue); 1168 setNoAutoMinHeight_LabelWidget(fprog, iTrue);
1169 iWidget *progBar = new_Widget();
1170 setBackgroundColor_Widget(progBar, uiTextCaution_ColorId);
1171 setFixedSize_Widget(progBar, init_I2(0, gap_UI / 4));
1172 setId_Widget(addChildFlags_Widget(as_Widget(fprog), iClob(progBar),
1173 moveToParentBottomEdge_WidgetFlag),
1174 "feeds.progressbar");
1167 addChildFlags_Widget(rightEmbed, 1175 addChildFlags_Widget(rightEmbed,
1168 iClob(fprog), 1176 iClob(fprog),
1169 collapse_WidgetFlag | hidden_WidgetFlag | frameless_WidgetFlag); 1177 collapse_WidgetFlag | hidden_WidgetFlag | frameless_WidgetFlag);
diff --git a/src/ui/widget.c b/src/ui/widget.c
index bdc5f090..ec92ac5a 100644
--- a/src/ui/widget.c
+++ b/src/ui/widget.c
@@ -289,7 +289,7 @@ void showCollapsed_Widget(iWidget *d, iBool show) {
289 setFlags_Widget(d, hidden_WidgetFlag, !show); 289 setFlags_Widget(d, hidden_WidgetFlag, !show);
290 /* The entire UI may be affected, if parents are resized due to the (un)collapsing. */ 290 /* The entire UI may be affected, if parents are resized due to the (un)collapsing. */
291 arrange_Widget(root_Widget(d)); 291 arrange_Widget(root_Widget(d));
292 postRefresh_App(); 292 refresh_Widget(d);
293 } 293 }
294} 294}
295 295