diff options
Diffstat (limited to 'apps/plugins/lib/printcell_helper.c')
-rw-r--r-- | apps/plugins/lib/printcell_helper.c | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/apps/plugins/lib/printcell_helper.c b/apps/plugins/lib/printcell_helper.c index 27a4b0fc95..ce79943c31 100644 --- a/apps/plugins/lib/printcell_helper.c +++ b/apps/plugins/lib/printcell_helper.c | |||
@@ -41,6 +41,7 @@ struct printcell_info_t { | |||
41 | int iconw[NB_SCREENS]; | 41 | int iconw[NB_SCREENS]; |
42 | int selcol_offw[NB_SCREENS]; | 42 | int selcol_offw[NB_SCREENS]; |
43 | int totalcolw[NB_SCREENS]; | 43 | int totalcolw[NB_SCREENS]; |
44 | int firstcolxw[NB_SCREENS]; | ||
44 | uint16_t colw[NB_SCREENS][PRINTCELL_MAX_COLUMNS]; | 45 | uint16_t colw[NB_SCREENS][PRINTCELL_MAX_COLUMNS]; |
45 | int ncols; | 46 | int ncols; |
46 | int selcol; | 47 | int selcol; |
@@ -119,6 +120,15 @@ static void draw_selector(struct screen *display, struct line_desc *linedes, | |||
119 | return; | 120 | return; |
120 | } | 121 | } |
121 | } | 122 | } |
123 | else if (printcell.selcol < 0) | ||
124 | { | ||
125 | if (selected_flag == SELECTED_FLAG) | ||
126 | { | ||
127 | display->hline(x + 1, w + x, y); | ||
128 | display->hline(x + 1, w + x, y + h - 1); | ||
129 | return; | ||
130 | } | ||
131 | } | ||
122 | /* draw whole rect outline */ | 132 | /* draw whole rect outline */ |
123 | display->drawrect(x + 1, y, w - 1, h); | 133 | display->drawrect(x + 1, y, w - 1, h); |
124 | } | 134 | } |
@@ -255,6 +265,8 @@ static void printcell_listdraw_fn(struct list_putlineinfo_t *list_info) | |||
255 | nw += sbwidth; | 265 | nw += sbwidth; |
256 | 266 | ||
257 | colxw = nx + nw; | 267 | colxw = nx + nw; |
268 | printcell.firstcolxw[screen] = colxw; /* save position of first column for subsequent items */ | ||
269 | |||
258 | if (colxw > 0) | 270 | if (colxw > 0) |
259 | { | 271 | { |
260 | set_cell_width(vp, vp_w, colxw); | 272 | set_cell_width(vp, vp_w, colxw); |
@@ -289,8 +301,9 @@ static void printcell_listdraw_fn(struct list_putlineinfo_t *list_info) | |||
289 | display->put_line(x, y, linedes, "$t", ""); | 301 | display->put_line(x, y, linedes, "$t", ""); |
290 | } | 302 | } |
291 | 303 | ||
292 | nw = screencolwidth[0] + printcell.iconw[screen] + text_offset; | 304 | //nw = screencolwidth[0] + printcell.iconw[screen] + text_offset; |
293 | colxw = nx + nw; | 305 | colxw = printcell.firstcolxw[screen] - vp->x; /* match title spacing */ |
306 | nw = colxw - nx; | ||
294 | if (colxw > 0) | 307 | if (colxw > 0) |
295 | { | 308 | { |
296 | set_cell_width(vp, vp_w, colxw); | 309 | set_cell_width(vp, vp_w, colxw); |