summaryrefslogtreecommitdiff
path: root/apps
diff options
context:
space:
mode:
Diffstat (limited to 'apps')
-rw-r--r--apps/settings.c8
-rw-r--r--apps/settings_menu.c14
-rw-r--r--apps/wps-display.c2
3 files changed, 15 insertions, 9 deletions
diff --git a/apps/settings.c b/apps/settings.c
index 7ca3820016..ff9c57d136 100644
--- a/apps/settings.c
+++ b/apps/settings.c
@@ -182,12 +182,14 @@ static const struct bit_entry rtc_bits[] =
182 {2, S_O(repeat_mode), REPEAT_ALL, "repeat", "off,all,one" }, 182 {2, S_O(repeat_mode), REPEAT_ALL, "repeat", "off,all,one" },
183 /* LCD */ 183 /* LCD */
184 {6, S_O(contrast), 40, "contrast", NULL }, 184 {6, S_O(contrast), 40, "contrast", NULL },
185#ifdef HAVE_BACKLIGHT 185#ifdef CONFIG_BACKLIGHT
186#ifdef HAVE_CHARGING
186 {1, S_O(backlight_on_when_charging), false, 187 {1, S_O(backlight_on_when_charging), false,
187 "backlight when plugged", off_on }, 188 "backlight when plugged", off_on },
189#endif
188 {5, S_O(backlight_timeout), 5, "backlight timeout", 190 {5, S_O(backlight_timeout), 5, "backlight timeout",
189 "off,on,1,2,3,4,5,6,7,8,9,10,15,20,25,30,45,60,90" }, 191 "off,on,1,2,3,4,5,6,7,8,9,10,15,20,25,30,45,60,90" },
190#endif 192#endif /* CONFIG_BACKLIGHT */
191#ifdef HAVE_LCD_BITMAP 193#ifdef HAVE_LCD_BITMAP
192 {1, S_O(invert), false, "invert", off_on }, 194 {1, S_O(invert), false, "invert", off_on },
193 {1, S_O(flip_display), false, "flip display", off_on }, 195 {1, S_O(flip_display), false, "flip display", off_on },
@@ -247,7 +249,7 @@ static const struct bit_entry hd_bits[] =
247 249
248 /* # of bits, offset+size, default, .cfg name, .cfg values */ 250 /* # of bits, offset+size, default, .cfg name, .cfg values */
249 /* more display */ 251 /* more display */
250#ifdef HAVE_BACKLIGHT 252#ifdef CONFIG_BACKLIGHT
251 {1, S_O(caption_backlight), false, "caption backlight", off_on }, 253 {1, S_O(caption_backlight), false, "caption backlight", off_on },
252#endif 254#endif
253 {4, S_O(scroll_speed), 9, "scroll speed", NULL }, /* 0...15 */ 255 {4, S_O(scroll_speed), 9, "scroll speed", NULL }, /* 0...15 */
diff --git a/apps/settings_menu.c b/apps/settings_menu.c
index c61352b1cc..eae39f905f 100644
--- a/apps/settings_menu.c
+++ b/apps/settings_menu.c
@@ -77,7 +77,7 @@ static bool contrast(void)
77 MAX_CONTRAST_SETTING ); 77 MAX_CONTRAST_SETTING );
78} 78}
79 79
80#ifdef HAVE_BACKLIGHT 80#ifdef CONFIG_BACKLIGHT
81static bool caption_backlight(void) 81static bool caption_backlight(void)
82{ 82{
83 bool rc = set_bool( str(LANG_CAPTION_BACKLIGHT), 83 bool rc = set_bool( str(LANG_CAPTION_BACKLIGHT),
@@ -575,7 +575,8 @@ static bool useMRB(void)
575 names, 3, NULL ); 575 names, 3, NULL );
576} 576}
577 577
578#ifdef HAVE_BACKLIGHT 578#ifdef CONFIG_BACKLIGHT
579#ifdef HAVE_CHARGING
579static bool backlight_on_when_charging(void) 580static bool backlight_on_when_charging(void)
580{ 581{
581 bool result = set_bool(str(LANG_BACKLIGHT_ON_WHEN_CHARGING), 582 bool result = set_bool(str(LANG_BACKLIGHT_ON_WHEN_CHARGING),
@@ -583,6 +584,7 @@ static bool backlight_on_when_charging(void)
583 backlight_set_on_when_charging(global_settings.backlight_on_when_charging); 584 backlight_set_on_when_charging(global_settings.backlight_on_when_charging);
584 return result; 585 return result;
585} 586}
587#endif
586 588
587static bool backlight_timer(void) 589static bool backlight_timer(void)
588{ 590{
@@ -610,7 +612,7 @@ static bool backlight_timer(void)
610 return set_option(str(LANG_BACKLIGHT), &global_settings.backlight_timeout, 612 return set_option(str(LANG_BACKLIGHT), &global_settings.backlight_timeout,
611 INT, names, 19, backlight_set_timeout ); 613 INT, names, 19, backlight_set_timeout );
612} 614}
613#endif /* HAVE_BACKLIGHT */ 615#endif /* CONFIG_BACKLIGHT */
614 616
615static bool poweroff_idle_timer(void) 617static bool poweroff_idle_timer(void)
616{ 618{
@@ -1162,11 +1164,13 @@ static bool lcd_settings_menu(void)
1162 bool result; 1164 bool result;
1163 1165
1164 static const struct menu_item items[] = { 1166 static const struct menu_item items[] = {
1165#ifdef HAVE_BACKLIGHT 1167#ifdef CONFIG_BACKLIGHT
1166 { ID2P(LANG_BACKLIGHT), backlight_timer }, 1168 { ID2P(LANG_BACKLIGHT), backlight_timer },
1169#ifdef HAVE_CHARGING
1167 { ID2P(LANG_BACKLIGHT_ON_WHEN_CHARGING), backlight_on_when_charging }, 1170 { ID2P(LANG_BACKLIGHT_ON_WHEN_CHARGING), backlight_on_when_charging },
1168 { ID2P(LANG_CAPTION_BACKLIGHT), caption_backlight },
1169#endif 1171#endif
1172 { ID2P(LANG_CAPTION_BACKLIGHT), caption_backlight },
1173#endif /* CONFIG_BACKLIGHT */
1170 { ID2P(LANG_CONTRAST), contrast }, 1174 { ID2P(LANG_CONTRAST), contrast },
1171#ifdef HAVE_LCD_BITMAP 1175#ifdef HAVE_LCD_BITMAP
1172 { ID2P(LANG_INVERT), invert }, 1176 { ID2P(LANG_INVERT), invert },
diff --git a/apps/wps-display.c b/apps/wps-display.c
index 90fec56001..a261f21a5d 100644
--- a/apps/wps-display.c
+++ b/apps/wps-display.c
@@ -987,7 +987,7 @@ bool wps_refresh(struct mp3entry* id3,
987 peak_meter_enabled = enable_pm; 987 peak_meter_enabled = enable_pm;
988#endif 988#endif
989 989
990#if defined(HAVE_BACKLIGHT) && !defined(SIMULATOR) 990#if defined(CONFIG_BACKLIGHT) && !defined(SIMULATOR)
991 if (global_settings.caption_backlight && id3) { 991 if (global_settings.caption_backlight && id3) {
992 /* turn on backlight n seconds before track ends, and turn it off n 992 /* turn on backlight n seconds before track ends, and turn it off n
993 seconds into the new track. n == backlight_timeout, or 5s */ 993 seconds into the new track. n == backlight_timeout, or 5s */