diff options
author | William Wilgus <wilgus.william@gmail.com> | 2024-05-04 08:41:16 -0400 |
---|---|---|
committer | William Wilgus <wilgus.william@gmail.com> | 2024-05-05 14:01:43 -0400 |
commit | d7c541742f5e6ec07dbcc8e1346efde9d807437e (patch) | |
tree | 2c3325b652999bd9b2443eb96d8d32035d3c4c18 /apps/tree.c | |
parent | efcea6628024c5f6796c3850c3779801db4b6874 (diff) | |
download | rockbox-d7c541742f5e6ec07dbcc8e1346efde9d807437e.tar.gz rockbox-d7c541742f5e6ec07dbcc8e1346efde9d807437e.zip |
Allow first level folders in plugin menu
add sorting directories as files
move picross files to a hidden folder
use directory for lua_scripts, sgt_puzzles
make plugin browser able to handle 1st level directories
Change-Id: I30852d71dc992c378d5790756e94f06f5a2e9bef
Diffstat (limited to 'apps/tree.c')
-rw-r--r-- | apps/tree.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/apps/tree.c b/apps/tree.c index 2e82b165af..58457c2d71 100644 --- a/apps/tree.c +++ b/apps/tree.c | |||
@@ -466,6 +466,13 @@ static int update_dir(void) | |||
466 | icon = tc.browse->icon; | 466 | icon = tc.browse->icon; |
467 | if (icon == NOICON) | 467 | if (icon == NOICON) |
468 | icon = filetype_get_icon(ATTR_DIRECTORY); | 468 | icon = filetype_get_icon(ATTR_DIRECTORY); |
469 | /* display sub directories in the title of plugin browser */ | ||
470 | if (tc.dirlevel > 0 && *tc.dirfilter == SHOW_PLUGINS) | ||
471 | { | ||
472 | char *subdir = strrchr(tc.currdir, '/'); | ||
473 | if (subdir) | ||
474 | title = subdir + 1; /* step past the separator */ | ||
475 | } | ||
469 | } | 476 | } |
470 | else | 477 | else |
471 | { | 478 | { |
@@ -1056,7 +1063,7 @@ int rockbox_browse(struct browse_context *browse) | |||
1056 | int last_context; | 1063 | int last_context; |
1057 | /* don't reset if its the same browse already loaded */ | 1064 | /* don't reset if its the same browse already loaded */ |
1058 | if (tc.browse != browse || | 1065 | if (tc.browse != browse || |
1059 | !(tc.currdir[1] && strcmp(tc.currdir, browse->root) == 0)) | 1066 | !(tc.currdir[1] && strstr(tc.currdir, browse->root) != NULL)) |
1060 | { | 1067 | { |
1061 | tc.browse = browse; | 1068 | tc.browse = browse; |
1062 | tc.selected_item = 0; | 1069 | tc.selected_item = 0; |