diff options
author | Jonathan Gordon <rockbox@jdgordon.info> | 2008-06-29 02:39:09 +0000 |
---|---|---|
committer | Jonathan Gordon <rockbox@jdgordon.info> | 2008-06-29 02:39:09 +0000 |
commit | 47b67ba6f60b0f4b04f2583f35a553619bcf3ca1 (patch) | |
tree | 91b649c17164bb1cef24705498bfb2c8874b6736 /apps | |
parent | fa366af4b8caf9c5c12030af5b013c9e54ebbbc0 (diff) |
fix FS#9120 by actually quiting random folder advance config after choosing "ignore changes and quit"
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@17864 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps')
-rw-r--r-- | apps/plugins/random_folder_advance_config.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/apps/plugins/random_folder_advance_config.c b/apps/plugins/random_folder_advance_config.c index e1aa469473..c03a794e73 100644 --- a/apps/plugins/random_folder_advance_config.c +++ b/apps/plugins/random_folder_advance_config.c @@ -285,18 +285,18 @@ int save_list(void) return 1; } -void edit_list(void) +int edit_list(void) { struct gui_synclist lists; bool exit = false; int button,i; - int selection; + int selection, ret = 0; /* load the dat file if not already done */ if ((list == NULL || list->count == 0) && (i = load_list()) != 0) { rb->splash(HZ*2, "Could not load %s, rv = %d", RFA_FILE, i); - return; + return -1; } dirs_count = list->count; @@ -371,12 +371,14 @@ void edit_list(void) save_list(); case 1: exit = true; + ret = -2; } menu_exit(m); } break; } } + return ret; } int export_list_to_file_text(void) @@ -474,6 +476,7 @@ int import_list_from_file_text(void) int main_menu(void) { int m; + bool exit = false; static const struct menu_item items[] = { { "Generate Folder List", NULL }, { "Edit Folder List", NULL }, @@ -503,7 +506,8 @@ int main_menu(void) #ifdef HAVE_ADJUSTABLE_CPU_FREQ rb->cpu_boost(true); #endif - edit_list(); + if (edit_list() < 0) + exit = true; #ifdef HAVE_ADJUSTABLE_CPU_FREQ rb->cpu_boost(false); #endif @@ -543,7 +547,7 @@ int main_menu(void) return 1; } menu_exit(m); - return 0; + return exit?1:0; } enum plugin_status plugin_start(const struct plugin_api* api, const void* parameter) |