Sansa clip zip: do not enable display if it's already enabled

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30903 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Bertrik Sikken 2011-11-05 12:30:19 +00:00
parent 3a66005739
commit 9310fc0b4c

View file

@ -263,7 +263,9 @@ static void lcd_init_type1(void)
/* enables/disables the lcd */
void lcd_enable(bool on)
{
lcd_enabled = on;
if (on == lcd_enabled) {
return;
}
if (lcd_type == 0) {
if (on) {
@ -301,6 +303,8 @@ void lcd_enable(bool on)
lcd_write_dat(0x01);
}
}
lcd_enabled = on;
}
/* returns true if the lcd is enabled */