diff options
-rw-r--r-- | apps/gui/statusbar.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/apps/gui/statusbar.c b/apps/gui/statusbar.c index 66297826c0..a961d191b2 100644 --- a/apps/gui/statusbar.c +++ b/apps/gui/statusbar.c | |||
@@ -53,6 +53,7 @@ | |||
53 | #define STATUSBAR_PLUG_X_POS STATUSBAR_X_POS + \ | 53 | #define STATUSBAR_PLUG_X_POS STATUSBAR_X_POS + \ |
54 | STATUSBAR_BATTERY_WIDTH + \ | 54 | STATUSBAR_BATTERY_WIDTH + \ |
55 | ICONS_SPACING | 55 | ICONS_SPACING |
56 | #define STATUSBAR_BATTERY_HEIGHT SB_ICON_HEIGHT - 1 | ||
56 | #define STATUSBAR_PLUG_WIDTH 7 | 57 | #define STATUSBAR_PLUG_WIDTH 7 |
57 | #define STATUSBAR_VOLUME_X_POS STATUSBAR_X_POS + \ | 58 | #define STATUSBAR_VOLUME_X_POS STATUSBAR_X_POS + \ |
58 | STATUSBAR_BATTERY_WIDTH + \ | 59 | STATUSBAR_BATTERY_WIDTH + \ |
@@ -400,12 +401,13 @@ static void gui_statusbar_icon_battery(struct screen * display, int percent, | |||
400 | } | 401 | } |
401 | else { | 402 | else { |
402 | /* draw battery */ | 403 | /* draw battery */ |
403 | display->drawrect(STATUSBAR_BATTERY_X_POS, STATUSBAR_Y_POS, 17, 7); | 404 | display->drawrect(STATUSBAR_BATTERY_X_POS, STATUSBAR_Y_POS, |
404 | display->vline(STATUSBAR_BATTERY_X_POS + 17, STATUSBAR_Y_POS + 2, | 405 | STATUSBAR_BATTERY_WIDTH - 1, STATUSBAR_BATTERY_HEIGHT); |
405 | STATUSBAR_Y_POS + 4); | 406 | display->vline(STATUSBAR_BATTERY_X_POS + STATUSBAR_BATTERY_WIDTH - 1, |
407 | STATUSBAR_Y_POS + 2, STATUSBAR_Y_POS + 4); | ||
406 | 408 | ||
407 | display->fillrect(STATUSBAR_BATTERY_X_POS + 1, STATUSBAR_Y_POS + 1, | 409 | display->fillrect(STATUSBAR_BATTERY_X_POS + 1, STATUSBAR_Y_POS + 1, |
408 | fill, 5); | 410 | fill, STATUSBAR_BATTERY_HEIGHT - 2); |
409 | #if LCD_DEPTH > 1 | 411 | #if LCD_DEPTH > 1 |
410 | if (display->depth > 1) | 412 | if (display->depth > 1) |
411 | { | 413 | { |
@@ -413,8 +415,8 @@ static void gui_statusbar_icon_battery(struct screen * display, int percent, | |||
413 | display->set_foreground(LCD_DARKGRAY); | 415 | display->set_foreground(LCD_DARKGRAY); |
414 | } | 416 | } |
415 | #endif | 417 | #endif |
416 | display->fillrect(STATUSBAR_BATTERY_X_POS + 1 + fill, | 418 | display->fillrect(STATUSBAR_BATTERY_X_POS + 1 + fill, STATUSBAR_Y_POS + 1, |
417 | STATUSBAR_Y_POS + 1, endfill - fill, 5); | 419 | endfill - fill, STATUSBAR_BATTERY_HEIGHT - 2); |
418 | #if LCD_DEPTH > 1 | 420 | #if LCD_DEPTH > 1 |
419 | if (display->depth > 1) | 421 | if (display->depth > 1) |
420 | display->set_foreground(prevfg); | 422 | display->set_foreground(prevfg); |