diff options
author | Dave Chapman <dave@dchapman.com> | 2006-02-02 20:42:56 +0000 |
---|---|---|
committer | Dave Chapman <dave@dchapman.com> | 2006-02-02 20:42:56 +0000 |
commit | d9e5b67b71cf246c11da8a9083af21752ac7bd15 (patch) | |
tree | 99ac1903b7b0a7197483fa64add73e6062d169af /apps/plugin.c | |
parent | 9b4b4d0bf2366ebbbb3cbb14eeb457da9f2658eb (diff) | |
download | rockbox-d9e5b67b71cf246c11da8a9083af21752ac7bd15.tar.gz rockbox-d9e5b67b71cf246c11da8a9083af21752ac7bd15.zip |
Patch #1421422 - Backdrop image patch started by Linus, finished by me. Adds ability to set backdrop images for file browser and menus (store full-screen bitmaps in /.rockbox/backdrops/) and also the ability to set a full-screen background image in a WPS using the %X|filename.bmp| WPS tag. Currently only implemented for targets with colour LCDs.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8536 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/plugin.c')
-rw-r--r-- | apps/plugin.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/apps/plugin.c b/apps/plugin.c index 32412bc2ee..774ae547a3 100644 --- a/apps/plugin.c +++ b/apps/plugin.c | |||
@@ -396,6 +396,9 @@ int plugin_load(const char* plugin, void* parameter) | |||
396 | #ifdef HAVE_LCD_BITMAP | 396 | #ifdef HAVE_LCD_BITMAP |
397 | int xm, ym; | 397 | int xm, ym; |
398 | #endif | 398 | #endif |
399 | #ifdef HAVE_LCD_COLOR | ||
400 | fb_data* old_backdrop; | ||
401 | #endif | ||
399 | 402 | ||
400 | if (pfn_tsr_exit != NULL) /* if we have a resident old plugin: */ | 403 | if (pfn_tsr_exit != NULL) /* if we have a resident old plugin: */ |
401 | { | 404 | { |
@@ -404,6 +407,10 @@ int plugin_load(const char* plugin, void* parameter) | |||
404 | plugin_loaded = false; | 407 | plugin_loaded = false; |
405 | } | 408 | } |
406 | 409 | ||
410 | #ifdef HAVE_LCD_COLOR | ||
411 | old_backdrop = lcd_get_backdrop(); | ||
412 | lcd_set_backdrop(NULL); | ||
413 | #endif | ||
407 | lcd_clear_display(); | 414 | lcd_clear_display(); |
408 | #ifdef HAVE_LCD_BITMAP | 415 | #ifdef HAVE_LCD_BITMAP |
409 | xm = lcd_getxmargin(); | 416 | xm = lcd_getxmargin(); |
@@ -481,6 +488,9 @@ int plugin_load(const char* plugin, void* parameter) | |||
481 | /* restore margins */ | 488 | /* restore margins */ |
482 | lcd_setmargins(xm,ym); | 489 | lcd_setmargins(xm,ym); |
483 | #endif /* HAVE_LCD_BITMAP */ | 490 | #endif /* HAVE_LCD_BITMAP */ |
491 | #ifdef HAVE_LCD_COLOR | ||
492 | lcd_set_backdrop(old_backdrop); | ||
493 | #endif | ||
484 | 494 | ||
485 | if (pfn_tsr_exit == NULL) | 495 | if (pfn_tsr_exit == NULL) |
486 | plugin_loaded = false; | 496 | plugin_loaded = false; |