summaryrefslogtreecommitdiff
path: root/apps/status.c
diff options
context:
space:
mode:
Diffstat (limited to 'apps/status.c')
-rw-r--r--apps/status.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/apps/status.c b/apps/status.c
index 7e9233a63f..68d6ac74c1 100644
--- a/apps/status.c
+++ b/apps/status.c
@@ -40,7 +40,7 @@ static enum playmode current_mode = STATUS_STOP;
40static long switch_tick; 40static long switch_tick;
41static int battery_charge_step = 0; 41static int battery_charge_step = 0;
42static bool plug_state; 42static bool plug_state;
43static bool battery_state; 43static bool battery_state = true;
44 44
45struct status_info { 45struct status_info {
46 int battlevel; 46 int battlevel;
@@ -167,7 +167,8 @@ void status_draw(bool force_redraw)
167 battery_state = true; 167 battery_state = true;
168 else { 168 else {
169 /* blink battery if level is low */ 169 /* blink battery if level is low */
170 if(TIME_AFTER(current_tick, switch_tick)) { 170 if(TIME_AFTER(current_tick, switch_tick) &&
171 (info.battlevel > -1)) {
171 switch_tick = current_tick+HZ; 172 switch_tick = current_tick+HZ;
172 battery_state =! battery_state; 173 battery_state =! battery_state;
173 } 174 }
@@ -175,7 +176,7 @@ void status_draw(bool force_redraw)
175 } 176 }
176 177
177#ifdef HAVE_LCD_BITMAP 178#ifdef HAVE_LCD_BITMAP
178 if (battery_state && (info.battlevel > -1)) 179 if (battery_state)
179 statusbar_icon_battery(info.battlevel, plug_state); 180 statusbar_icon_battery(info.battlevel, plug_state);
180 181
181 statusbar_icon_volume(info.volume); 182 statusbar_icon_volume(info.volume);