diff options
-rw-r--r-- | apps/root_menu.c | 4 | ||||
-rw-r--r-- | apps/tree.c | 2 |
2 files changed, 4 insertions, 2 deletions
diff --git a/apps/root_menu.c b/apps/root_menu.c index 49c31cb512..050f5be3c6 100644 --- a/apps/root_menu.c +++ b/apps/root_menu.c | |||
@@ -84,7 +84,7 @@ static int browser(void* param) | |||
84 | static char last_folder[MAX_PATH] = "/"; | 84 | static char last_folder[MAX_PATH] = "/"; |
85 | /* and stuff for the database browser */ | 85 | /* and stuff for the database browser */ |
86 | #ifdef HAVE_TAGCACHE | 86 | #ifdef HAVE_TAGCACHE |
87 | static int last_db_dirlevel = 0; | 87 | static int last_db_dirlevel = 0, last_db_selection = 0; |
88 | #endif | 88 | #endif |
89 | 89 | ||
90 | switch ((intptr_t)param) | 90 | switch ((intptr_t)param) |
@@ -166,6 +166,7 @@ static int browser(void* param) | |||
166 | return GO_TO_PREVIOUS; | 166 | return GO_TO_PREVIOUS; |
167 | filter = SHOW_ID3DB; | 167 | filter = SHOW_ID3DB; |
168 | tc->dirlevel = last_db_dirlevel; | 168 | tc->dirlevel = last_db_dirlevel; |
169 | tc->selected_item = last_db_selection; | ||
169 | break; | 170 | break; |
170 | #endif | 171 | #endif |
171 | case GO_TO_BROWSEPLUGINS: | 172 | case GO_TO_BROWSEPLUGINS: |
@@ -182,6 +183,7 @@ static int browser(void* param) | |||
182 | #ifdef HAVE_TAGCACHE | 183 | #ifdef HAVE_TAGCACHE |
183 | case GO_TO_DBBROWSER: | 184 | case GO_TO_DBBROWSER: |
184 | last_db_dirlevel = tc->dirlevel; | 185 | last_db_dirlevel = tc->dirlevel; |
186 | last_db_selection = tc->selected_item; | ||
185 | break; | 187 | break; |
186 | #endif | 188 | #endif |
187 | } | 189 | } |
diff --git a/apps/tree.c b/apps/tree.c index e4237dc598..d58c05deb7 100644 --- a/apps/tree.c +++ b/apps/tree.c | |||
@@ -632,6 +632,7 @@ int dirbrowse() | |||
632 | if (returned_button == ACTION_STD_CANCEL) | 632 | if (returned_button == ACTION_STD_CANCEL) |
633 | button = ACTION_STD_CANCEL; | 633 | button = ACTION_STD_CANCEL; |
634 | 634 | ||
635 | tc.selected_item = gui_synclist_get_sel_pos(&tree_lists); | ||
635 | switch ( button ) { | 636 | switch ( button ) { |
636 | case ACTION_STD_OK: | 637 | case ACTION_STD_OK: |
637 | /* nothing to do if no files to display */ | 638 | /* nothing to do if no files to display */ |
@@ -933,7 +934,6 @@ int dirbrowse() | |||
933 | } | 934 | } |
934 | 935 | ||
935 | if(need_update) { | 936 | if(need_update) { |
936 | tc.selected_item = gui_synclist_get_sel_pos(&tree_lists); | ||
937 | need_update=false; | 937 | need_update=false; |
938 | if ( numentries > 0 ) { | 938 | if ( numentries > 0 ) { |
939 | /* Voice the file if changed */ | 939 | /* Voice the file if changed */ |