diff options
Diffstat (limited to 'apps/root_menu.c')
-rw-r--r-- | apps/root_menu.c | 40 |
1 files changed, 13 insertions, 27 deletions
diff --git a/apps/root_menu.c b/apps/root_menu.c index 3b301e6d3a..49c31cb512 100644 --- a/apps/root_menu.c +++ b/apps/root_menu.c | |||
@@ -102,7 +102,6 @@ static int browser(void* param) | |||
102 | break; | 102 | break; |
103 | #ifdef HAVE_TAGCACHE | 103 | #ifdef HAVE_TAGCACHE |
104 | case GO_TO_DBBROWSER: | 104 | case GO_TO_DBBROWSER: |
105 | #if 0 /* Revert this for now */ | ||
106 | if (!tagcache_is_usable()) | 105 | if (!tagcache_is_usable()) |
107 | { | 106 | { |
108 | bool reinit_attempted = false; | 107 | bool reinit_attempted = false; |
@@ -165,13 +164,6 @@ static int browser(void* param) | |||
165 | } | 164 | } |
166 | if (!tagcache_is_usable()) | 165 | if (!tagcache_is_usable()) |
167 | return GO_TO_PREVIOUS; | 166 | return GO_TO_PREVIOUS; |
168 | #else /* The old code */ | ||
169 | if ((last_screen != GO_TO_ROOT) && !tagcache_is_usable()) | ||
170 | { | ||
171 | gui_syncsplash(0, true, str(LANG_TAGCACHE_BUSY)); | ||
172 | return GO_TO_PREVIOUS; | ||
173 | } | ||
174 | #endif /* Sorry for the interruption */ | ||
175 | filter = SHOW_ID3DB; | 167 | filter = SHOW_ID3DB; |
176 | tc->dirlevel = last_db_dirlevel; | 168 | tc->dirlevel = last_db_dirlevel; |
177 | break; | 169 | break; |
@@ -457,35 +449,29 @@ void root_menu(void) | |||
457 | break; | 449 | break; |
458 | 450 | ||
459 | case GO_TO_PREVIOUS_BROWSER: | 451 | case GO_TO_PREVIOUS_BROWSER: |
460 | #ifdef HAVE_TAGCACHE | 452 | ret_val = previous_browser; |
461 | if ((previous_browser == GO_TO_DBBROWSER) && | ||
462 | !tagcache_is_usable()) | ||
463 | ret_val = GO_TO_FILEBROWSER; | ||
464 | else | ||
465 | #endif | ||
466 | ret_val = previous_browser; | ||
467 | /* fall through */ | ||
468 | case GO_TO_FILEBROWSER: | ||
469 | #ifdef HAVE_TAGCACHE | ||
470 | case GO_TO_DBBROWSER: | ||
471 | #endif | ||
472 | previous_browser = ret_val; | ||
473 | break; | 453 | break; |
474 | 454 | ||
475 | case GO_TO_PREVIOUS_MUSIC: | 455 | case GO_TO_PREVIOUS_MUSIC: |
476 | ret_val = previous_music; | 456 | ret_val = previous_music; |
477 | /* fall through */ | ||
478 | case GO_TO_WPS: | ||
479 | #if CONFIG_TUNER | ||
480 | case GO_TO_FM: | ||
481 | #endif | ||
482 | previous_music = ret_val; | ||
483 | break; | 457 | break; |
484 | } | 458 | } |
485 | this_screen = ret_val; | 459 | this_screen = ret_val; |
486 | /* set the global_status.last_screen before entering, | 460 | /* set the global_status.last_screen before entering, |
487 | if we dont we will always return to the wrong screen on boot */ | 461 | if we dont we will always return to the wrong screen on boot */ |
488 | global_status.last_screen = (char)this_screen; | 462 | global_status.last_screen = (char)this_screen; |
463 | if (this_screen == GO_TO_FILEBROWSER | ||
464 | #ifdef HAVE_TAGCACHE | ||
465 | || this_screen == GO_TO_DBBROWSER | ||
466 | #endif | ||
467 | ) | ||
468 | previous_browser = this_screen; | ||
469 | if (this_screen == GO_TO_WPS | ||
470 | #ifdef CONFIG_TUNER | ||
471 | || this_screen == GO_TO_FM | ||
472 | #endif | ||
473 | ) | ||
474 | previous_music = this_screen; | ||
489 | status_save(); | 475 | status_save(); |
490 | action_signalscreenchange(); | 476 | action_signalscreenchange(); |
491 | ret_val = items[this_screen].function(items[this_screen].param); | 477 | ret_val = items[this_screen].function(items[this_screen].param); |