Remove the calls to backlight_lcd_sleep_countdown from target specific code and move it into backlight.c

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20793 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Thomas Martitz 2009-04-26 01:23:39 +00:00
parent c40af94d12
commit 6abae1f124
11 changed files with 20 additions and 65 deletions

View file

@ -33,9 +33,6 @@ void _backlight_set_brightness(int brightness)
void _backlight_on(void)
{
#ifdef HAVE_LCD_SLEEP
backlight_lcd_sleep_countdown(false); /* stop counter */
#endif
#ifdef HAVE_LCD_ENABLE
lcd_enable(true); /* power on lcd + visible display */
#endif
@ -52,9 +49,6 @@ void _backlight_off(void)
#ifdef HAVE_LCD_ENABLE
lcd_enable(false); /* power off visible display */
#endif
#ifdef HAVE_LCD_SLEEP
backlight_lcd_sleep_countdown(true); /* start countdown */
#endif
}
void _buttonlight_on(void)

View file

@ -38,9 +38,6 @@ void _backlight_set_brightness(int brightness)
void _backlight_on(void)
{
#ifdef HAVE_LCD_SLEEP
backlight_lcd_sleep_countdown(false); /* stop counter */
#endif
#ifdef HAVE_LCD_ENABLE
lcd_enable(true); /* power on lcd + visible display */
#endif
@ -53,9 +50,6 @@ void _backlight_off(void)
#ifdef HAVE_LCD_ENABLE
lcd_enable(false); /* power off visible display */
#endif
#ifdef HAVE_LCD_SLEEP
backlight_lcd_sleep_countdown(true); /* start countdown */
#endif
}
void _buttonlight_on(void)

View file

@ -127,9 +127,6 @@ void _backlight_on(void)
mutex_lock(&backlight_mutex);
#ifdef HAVE_LCD_SLEEP
backlight_lcd_sleep_countdown(false); /* stop counter */
#endif
#ifdef HAVE_LCD_ENABLE
lcd_enable(true);
#endif
@ -180,11 +177,6 @@ void _backlight_off(void)
0 << MC13783_LEDMDDC_POS,
MC13783_LEDMDDC);
#ifdef HAVE_LCD_SLEEP
/* Disable lcd after fade completes (when lcd_sleep timeout expires) */
backlight_lcd_sleep_countdown(true); /* start countdown */
#endif
mutex_unlock(&backlight_mutex);
}

View file

@ -26,9 +26,6 @@
void _backlight_on(void)
{
#ifdef HAVE_LCD_SLEEP
backlight_lcd_sleep_countdown(false); /* stop counter */
#endif
#ifdef HAVE_LCD_ENABLE
lcd_enable(true); /* power on lcd + visible display */
#endif
@ -41,7 +38,4 @@ void _backlight_off(void)
#ifdef HAVE_LCD_ENABLE
lcd_enable(false); /* power off visible display */
#endif
#ifdef HAVE_LCD_SLEEP
backlight_lcd_sleep_countdown(true); /* start countdown */
#endif
}

View file

@ -33,9 +33,6 @@ void _backlight_set_brightness(int brightness)
void _backlight_on(void)
{
#ifdef HAVE_LCD_SLEEP
backlight_lcd_sleep_countdown(false); /* stop counter */
#endif
#ifdef HAVE_LCD_ENABLE
lcd_enable(true); /* power on lcd + visible display */
#endif
@ -52,9 +49,6 @@ void _backlight_off(void)
#ifdef HAVE_LCD_ENABLE
lcd_enable(false); /* power off visible display */
#endif
#ifdef HAVE_LCD_SLEEP
backlight_lcd_sleep_countdown(true); /* start countdown */
#endif
}
void _buttonlight_on(void)

View file

@ -337,9 +337,6 @@ static void __backlight_dim(bool dim_now)
void _backlight_on(void)
{
#ifdef HAVE_LCD_SLEEP
backlight_lcd_sleep_countdown(false); /* stop counter */
#endif
#ifdef HAVE_LCD_ENABLE
lcd_enable(true); /* power on lcd + visible display */
#endif
@ -349,10 +346,6 @@ void _backlight_on(void)
void _backlight_off(void)
{
__backlight_dim(true);
#ifdef HAVE_LCD_SLEEP
/* Disable lcd after fade completes (when lcd_sleep timeout expires) */
backlight_lcd_sleep_countdown(true); /* start countdown */
#endif
}
static inline void __buttonlight_on(void)

View file

@ -33,9 +33,6 @@ void _backlight_set_brightness(int brightness)
void _backlight_on(void)
{
#ifdef HAVE_LCD_SLEEP
backlight_lcd_sleep_countdown(false); /* stop counter */
#endif
#ifdef HAVE_LCD_ENABLE
lcd_enable(true); /* power on lcd + visible display */
#endif
@ -52,9 +49,6 @@ void _backlight_off(void)
#ifdef HAVE_LCD_ENABLE
lcd_enable(false); /* power off visible display */
#endif
#ifdef HAVE_LCD_SLEEP
backlight_lcd_sleep_countdown(true); /* start countdown */
#endif
}
void _buttonlight_on(void)

View file

@ -38,9 +38,6 @@ static void _backlight_write_brightness(int brightness)
void _backlight_on(void)
{
#if defined(HAVE_LCD_SLEEP) && !defined(BOOTLOADER)
backlight_lcd_sleep_countdown(false); /* stop counter */
#endif
#ifdef HAVE_LCD_ENABLE
lcd_enable(true); /* power on lcd + visible display */
#endif
@ -50,10 +47,6 @@ void _backlight_on(void)
void _backlight_off(void)
{
_backlight_write_brightness(0);
#if defined(HAVE_LCD_SLEEP) && !defined(BOOTLOADER)
/* Disable lcd after fade completes (when lcd_sleep timeout expires) */
backlight_lcd_sleep_countdown(true); /* start countdown */
#endif
}
/* Assumes that the backlight has been initialized */