diff options
Diffstat (limited to 'apps/root_menu.c')
-rw-r--r-- | apps/root_menu.c | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/apps/root_menu.c b/apps/root_menu.c index 56b9918c40..e606d5cd68 100644 --- a/apps/root_menu.c +++ b/apps/root_menu.c | |||
@@ -1009,11 +1009,17 @@ void root_menu(void) | |||
1009 | { | 1009 | { |
1010 | /* shortcuts may take several trips through the GO_TO_PLUGIN | 1010 | /* shortcuts may take several trips through the GO_TO_PLUGIN |
1011 | case make sure we preserve and restore the origin */ | 1011 | case make sure we preserve and restore the origin */ |
1012 | if (shortcut_origin != GO_TO_ROOT) | 1012 | if(tree_get_context()->out_of_tree > 0) /* a shortcut has been selected */ |
1013 | { | 1013 | { |
1014 | if(tree_get_context()->out_of_tree > 0) /* a shortcut has been selected */ | 1014 | next_screen = GO_TO_FILEBROWSER; |
1015 | next_screen = GO_TO_FILEBROWSER; | 1015 | shortcut_origin = GO_TO_ROOT; |
1016 | else if (shortcut_origin != GO_TO_WPS) | 1016 | /* note in some cases there is a screen to return to |
1017 | but the history is rewritten as if you browsed here | ||
1018 | from the root so return there when finished */ | ||
1019 | } | ||
1020 | else if (shortcut_origin != GO_TO_ROOT) | ||
1021 | { | ||
1022 | if (shortcut_origin != GO_TO_WPS) | ||
1017 | next_screen = shortcut_origin; | 1023 | next_screen = shortcut_origin; |
1018 | shortcut_origin = GO_TO_ROOT; | 1024 | shortcut_origin = GO_TO_ROOT; |
1019 | } | 1025 | } |