forked from len0rd/rockbox
Correct some preprocessor checks.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20573 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
148b0e98fc
commit
ddc554f62b
1 changed files with 11 additions and 5 deletions
|
@ -427,7 +427,15 @@ void lcd_init_device(void)
|
||||||
|
|
||||||
LCD_REG_6 |= 1; /* Start DMA */
|
LCD_REG_6 |= 1; /* Start DMA */
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined(HAVE_LCD_ENABLE) || defined(HAVE_LCD_SLEEP)
|
#if defined(HAVE_LCD_ENABLE) || defined(HAVE_LCD_SLEEP)
|
||||||
|
bool lcd_active(void)
|
||||||
|
{
|
||||||
|
return display_on;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(HAVE_LCD_ENABLE)
|
||||||
void lcd_enable(bool on)
|
void lcd_enable(bool on)
|
||||||
{
|
{
|
||||||
if (on == display_on)
|
if (on == display_on)
|
||||||
|
@ -450,12 +458,9 @@ void lcd_enable(bool on)
|
||||||
DEV_EN &= ~DEV_LCD; /* Disable LCD controller */
|
DEV_EN &= ~DEV_LCD; /* Disable LCD controller */
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
bool lcd_active(void)
|
|
||||||
{
|
|
||||||
return display_on;
|
|
||||||
}
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if defined(HAVE_LCD_SLEEP)
|
||||||
void lcd_sleep(void)
|
void lcd_sleep(void)
|
||||||
{
|
{
|
||||||
LCD_REG_6 &= ~1;
|
LCD_REG_6 &= ~1;
|
||||||
|
@ -474,6 +479,7 @@ void lcd_sleep(void)
|
||||||
/* SAP2-0=000, BT2-0=000, AP2-0=000, DK=0, SLP=0, STB=1 */
|
/* SAP2-0=000, BT2-0=000, AP2-0=000, DK=0, SLP=0, STB=1 */
|
||||||
lcd_write_reg(R_POWER_CONTROL1, 0x0001);
|
lcd_write_reg(R_POWER_CONTROL1, 0x0001);
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
/* Copies a rectangle from one framebuffer to another. Can be used in
|
/* Copies a rectangle from one framebuffer to another. Can be used in
|
||||||
single transfer mode with width = num pixels, and height = 1 which
|
single transfer mode with width = num pixels, and height = 1 which
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue