diff options
author | Solomon Peachy <pizza@shaftnet.org> | 2020-07-24 19:20:15 -0400 |
---|---|---|
committer | Solomon Peachy <pizza@shaftnet.org> | 2020-07-24 19:20:15 -0400 |
commit | 9be5bc4cf0d185f4515174b9ebbb105f73f7c2e3 (patch) | |
tree | 46b4a9f4650d288bcbe67e92a9138b45c06105fa /apps/plugins/chessclock.c | |
parent | 2127906384d618e032692becba10aeda1b3e1974 (diff) | |
download | rockbox-9be5bc4cf0d185f4515174b9ebbb105f73f7c2e3.tar.gz rockbox-9be5bc4cf0d185f4515174b9ebbb105f73f7c2e3.zip |
plugins: More HAVE_BACKLIGHT cleanup
Change-Id: I70cf700f5bc3d4375c025efa62ef40fd2bd70293
Diffstat (limited to 'apps/plugins/chessclock.c')
-rw-r--r-- | apps/plugins/chessclock.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/apps/plugins/chessclock.c b/apps/plugins/chessclock.c index fea966213d..649ab164d0 100644 --- a/apps/plugins/chessclock.c +++ b/apps/plugins/chessclock.c | |||
@@ -21,8 +21,6 @@ | |||
21 | #include "plugin.h" | 21 | #include "plugin.h" |
22 | #include "lib/playback_control.h" | 22 | #include "lib/playback_control.h" |
23 | 23 | ||
24 | |||
25 | |||
26 | /* variable button definitions */ | 24 | /* variable button definitions */ |
27 | #if (CONFIG_KEYPAD == IRIVER_H100_PAD) || \ | 25 | #if (CONFIG_KEYPAD == IRIVER_H100_PAD) || \ |
28 | (CONFIG_KEYPAD == IRIVER_H300_PAD) | 26 | (CONFIG_KEYPAD == IRIVER_H300_PAD) |
@@ -636,15 +634,19 @@ static int run_timer(int nr) | |||
636 | rb->lcd_puts(0, FIRST_LINE+1, (unsigned char *)"ROUND UP!"); | 634 | rb->lcd_puts(0, FIRST_LINE+1, (unsigned char *)"ROUND UP!"); |
637 | else | 635 | else |
638 | rb->lcd_puts(0, FIRST_LINE+1, (unsigned char *)"TIME OUT!"); | 636 | rb->lcd_puts(0, FIRST_LINE+1, (unsigned char *)"TIME OUT!"); |
637 | #ifdef HAVE_BACKLIGHT | ||
639 | rb->backlight_on(); | 638 | rb->backlight_on(); |
639 | #endif | ||
640 | ticks = max_ticks; | 640 | ticks = max_ticks; |
641 | } else { | 641 | } else { |
642 | now=*rb->current_tick; | 642 | now=*rb->current_tick; |
643 | if (!chesspause) { | 643 | if (!chesspause) { |
644 | ticks+=now-last_tick; | 644 | ticks+=now-last_tick; |
645 | if ((max_ticks-ticks)/HZ == 10) { | 645 | if ((max_ticks-ticks)/HZ == 10) { |
646 | /* Backlight on if 10 seconds remain */ | 646 | #ifdef HAVE_BACKLIGHT |
647 | /* Backlight on if 10 seconds remain */ | ||
647 | rb->backlight_on(); | 648 | rb->backlight_on(); |
649 | #endif | ||
648 | } | 650 | } |
649 | } | 651 | } |
650 | last_tick=now; | 652 | last_tick=now; |