summaryrefslogtreecommitdiff
path: root/uisimulator/sdl
diff options
context:
space:
mode:
authorMaurus Cuelenaere <mcuelenaere@gmail.com>2009-12-17 13:44:09 +0000
committerMaurus Cuelenaere <mcuelenaere@gmail.com>2009-12-17 13:44:09 +0000
commit5d96c3ba711f0a1b3fd71cad0764b56f0260df8d (patch)
tree5ac0950baac6ca901ebd582611a41772042e6151 /uisimulator/sdl
parent6c683d449ea2b9955f827e898e1fd527fd814d20 (diff)
downloadrockbox-5d96c3ba711f0a1b3fd71cad0764b56f0260df8d.tar.gz
rockbox-5d96c3ba711f0a1b3fd71cad0764b56f0260df8d.zip
Enable backlight brightness in simulator
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24042 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'uisimulator/sdl')
-rw-r--r--uisimulator/sdl/lcd-bitmap.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/uisimulator/sdl/lcd-bitmap.c b/uisimulator/sdl/lcd-bitmap.c
index 3c73b6fc5d..0bd90196e4 100644
--- a/uisimulator/sdl/lcd-bitmap.c
+++ b/uisimulator/sdl/lcd-bitmap.c
@@ -149,11 +149,7 @@ void sim_backlight(int value)
149#endif 149#endif
150 } 150 }
151#else /* LCD_DEPTH > 8 */ 151#else /* LCD_DEPTH > 8 */
152 if (value > 0) { 152 SDL_SetAlpha(lcd_surface, SDL_SRCALPHA, (value * 255) / 100);
153 SDL_SetAlpha(lcd_surface, 0, SDL_ALPHA_OPAQUE); /* full on */
154 } else {
155 SDL_SetAlpha(lcd_surface, SDL_SRCALPHA, BACKLIGHT_OFF_ALPHA);
156 }
157#endif /* LCD_DEPTH */ 153#endif /* LCD_DEPTH */
158 154
159 sdl_gui_update(lcd_surface, 0, 0, SIM_LCD_WIDTH, SIM_LCD_HEIGHT, 155 sdl_gui_update(lcd_surface, 0, 0, SIM_LCD_WIDTH, SIM_LCD_HEIGHT,