diff options
author | Jens Arnold <amiconn@rockbox.org> | 2006-02-16 22:36:04 +0000 |
---|---|---|
committer | Jens Arnold <amiconn@rockbox.org> | 2006-02-16 22:36:04 +0000 |
commit | 7ea4d591277e35b05baadebb0be3a1d909e830d7 (patch) | |
tree | 1b1e70e2eda7bbbfd3286bed0fcc477ddc7084a1 /apps | |
parent | 791005a54128f6393cfa5189864f68d09cdfc03a (diff) | |
download | rockbox-7ea4d591277e35b05baadebb0be3a1d909e830d7.tar.gz rockbox-7ea4d591277e35b05baadebb0be3a1d909e830d7.zip |
Plugin loader adjustments: * Don't clear the LCD before loading, just show a splash instead. * After successful loading, remove backdrop, then clear display, to properly prepare the screen for the plugin. * Clear after returning from plugin and restoring the backdrop.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8710 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps')
-rw-r--r-- | apps/plugin.c | 21 |
1 files changed, 13 insertions, 8 deletions
diff --git a/apps/plugin.c b/apps/plugin.c index 6f44a9c8ce..6060b4ad31 100644 --- a/apps/plugin.c +++ b/apps/plugin.c | |||
@@ -424,13 +424,8 @@ int plugin_load(const char* plugin, void* parameter) | |||
424 | plugin_loaded = false; | 424 | plugin_loaded = false; |
425 | } | 425 | } |
426 | 426 | ||
427 | lcd_clear_display(); | 427 | gui_syncsplash(0, true, str(LANG_WAIT)); |
428 | #ifdef HAVE_LCD_BITMAP | 428 | |
429 | xm = lcd_getxmargin(); | ||
430 | ym = lcd_getymargin(); | ||
431 | lcd_setmargins(0,0); | ||
432 | lcd_update(); | ||
433 | #endif | ||
434 | #ifdef SIMULATOR | 429 | #ifdef SIMULATOR |
435 | hdr = sim_plugin_load((char *)plugin, &fd); | 430 | hdr = sim_plugin_load((char *)plugin, &fd); |
436 | if (!fd) { | 431 | if (!fd) { |
@@ -486,10 +481,18 @@ int plugin_load(const char* plugin, void* parameter) | |||
486 | 481 | ||
487 | plugin_loaded = true; | 482 | plugin_loaded = true; |
488 | 483 | ||
484 | #ifdef HAVE_LCD_BITMAP | ||
485 | xm = lcd_getxmargin(); | ||
486 | ym = lcd_getymargin(); | ||
487 | lcd_setmargins(0,0); | ||
489 | #ifdef HAVE_LCD_COLOR | 488 | #ifdef HAVE_LCD_COLOR |
490 | old_backdrop = lcd_get_backdrop(); | 489 | old_backdrop = lcd_get_backdrop(); |
491 | lcd_set_backdrop(NULL); | 490 | lcd_set_backdrop(NULL); |
491 | #endif | ||
492 | lcd_clear_display(); | ||
492 | lcd_update(); | 493 | lcd_update(); |
494 | #else /* !HAVE_LCD_BITMAP */ | ||
495 | lcd_clear_display(); | ||
493 | #endif | 496 | #endif |
494 | 497 | ||
495 | invalidate_icache(); | 498 | invalidate_icache(); |
@@ -506,10 +509,12 @@ int plugin_load(const char* plugin, void* parameter) | |||
506 | #endif /* LCD_DEPTH */ | 509 | #endif /* LCD_DEPTH */ |
507 | /* restore margins */ | 510 | /* restore margins */ |
508 | lcd_setmargins(xm,ym); | 511 | lcd_setmargins(xm,ym); |
509 | #endif /* HAVE_LCD_BITMAP */ | ||
510 | #ifdef HAVE_LCD_COLOR | 512 | #ifdef HAVE_LCD_COLOR |
511 | lcd_set_backdrop(old_backdrop); | 513 | lcd_set_backdrop(old_backdrop); |
512 | #endif | 514 | #endif |
515 | lcd_clear_display(); | ||
516 | lcd_update(); | ||
517 | #endif /* HAVE_LCD_BITMAP */ | ||
513 | 518 | ||
514 | if (pfn_tsr_exit == NULL) | 519 | if (pfn_tsr_exit == NULL) |
515 | plugin_loaded = false; | 520 | plugin_loaded = false; |