diff options
author | William Wilgus <wilgus.william@gmail.com> | 2021-11-11 00:05:29 -0500 |
---|---|---|
committer | William Wilgus <wilgus.william@gmail.com> | 2021-11-11 00:28:59 -0500 |
commit | 30a23fdd6de8fb46e7b1349126a9ae6921cf7555 (patch) | |
tree | 78c1103d3a6f0285cc9555a521fe45d20831379c /apps/menus | |
parent | cf009b4cbb1eec083ab17ce370df090979eaf68e (diff) | |
download | rockbox-30a23fdd6de8fb46e7b1349126a9ae6921cf7555.tar.gz rockbox-30a23fdd6de8fb46e7b1349126a9ae6921cf7555.zip |
folder_select.c move to plugin as db_folder_select
handles the folder selection for autoresume paths and database paths
folder_select uses the pluginbuf to build the directory tree
hopefully having it as a plugin will make it stop corrupting
TSR plugins like battery_bench and announce_status
I left the original include and source in the gui directory for now
there are currently no other users..
Change-Id: If40ccb5a2bec4286a0616c10dfa7e1479a592808
Diffstat (limited to 'apps/menus')
-rw-r--r-- | apps/menus/settings_menu.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/apps/menus/settings_menu.c b/apps/menus/settings_menu.c index a5e747651a..94b697aada 100644 --- a/apps/menus/settings_menu.c +++ b/apps/menus/settings_menu.c | |||
@@ -48,7 +48,6 @@ | |||
48 | #ifdef HAVE_DIRCACHE | 48 | #ifdef HAVE_DIRCACHE |
49 | #include "dircache.h" | 49 | #include "dircache.h" |
50 | #endif | 50 | #endif |
51 | #include "folder_select.h" | ||
52 | #ifndef HAS_BUTTON_HOLD | 51 | #ifndef HAS_BUTTON_HOLD |
53 | #include "mask_select.h" | 52 | #include "mask_select.h" |
54 | #endif | 53 | #endif |
@@ -56,6 +55,7 @@ | |||
56 | #include "governor-ibasso.h" | 55 | #include "governor-ibasso.h" |
57 | #include "usb-ibasso.h" | 56 | #include "usb-ibasso.h" |
58 | #endif | 57 | #endif |
58 | #include "plugin.h" | ||
59 | 59 | ||
60 | #ifndef HAS_BUTTON_HOLD | 60 | #ifndef HAS_BUTTON_HOLD |
61 | static int selectivesoftlock_callback(int action, | 61 | static int selectivesoftlock_callback(int action, |
@@ -133,8 +133,7 @@ static void tagcache_update_with_splash(void) | |||
133 | 133 | ||
134 | static int dirs_to_scan(void) | 134 | static int dirs_to_scan(void) |
135 | { | 135 | { |
136 | if (folder_select(global_settings.tagcache_scan_paths, | 136 | if(plugin_load(VIEWERS_DIR"/db_folder_select.rock", NULL) > PLUGIN_OK) |
137 | sizeof(global_settings.tagcache_scan_paths))) | ||
138 | { | 137 | { |
139 | static const char *lines[] = {ID2P(LANG_TAGCACHE_BUSY), | 138 | static const char *lines[] = {ID2P(LANG_TAGCACHE_BUSY), |
140 | ID2P(LANG_TAGCACHE_FORCE_UPDATE)}; | 139 | ID2P(LANG_TAGCACHE_FORCE_UPDATE)}; |
@@ -650,8 +649,8 @@ static int autoresume_nexttrack_callback(int action, | |||
650 | break; | 649 | break; |
651 | case ACTION_EXIT_MENUITEM: | 650 | case ACTION_EXIT_MENUITEM: |
652 | if (global_settings.autoresume_automatic == AUTORESUME_NEXTTRACK_CUSTOM | 651 | if (global_settings.autoresume_automatic == AUTORESUME_NEXTTRACK_CUSTOM |
653 | && !folder_select(global_settings.autoresume_paths, | 652 | && plugin_load(VIEWERS_DIR"/db_folder_select.rock", |
654 | MAX_PATHNAME+1)) | 653 | str(LANG_AUTORESUME)) == PLUGIN_OK) |
655 | { | 654 | { |
656 | global_settings.autoresume_automatic = oldval; | 655 | global_settings.autoresume_automatic = oldval; |
657 | } | 656 | } |