(Menu) Cleanups

This commit is contained in:
twinaphex 2015-06-08 14:07:03 +02:00
parent 2514df5bca
commit 80445e2fca
2 changed files with 37 additions and 37 deletions

View File

@ -72,8 +72,9 @@ static int action_ok_file_load_with_detect_core(const char *path,
fill_pathname_join(detect_content_path, menu_path, path, fill_pathname_join(detect_content_path, menu_path, path,
sizeof(detect_content_path)); sizeof(detect_content_path));
if (ret == -1) switch (ret)
{ {
case -1:
switch (hash_label) switch (hash_label)
{ {
case MENU_LABEL_COLLECTION: case MENU_LABEL_COLLECTION:
@ -90,10 +91,8 @@ static int action_ok_file_load_with_detect_core(const char *path,
menu_common_load_content(false); menu_common_load_content(false);
return -1; return -1;
} }
} break;
case 0:
if (ret == 0)
{
info.list = menu->menu_list->menu_stack; info.list = menu->menu_list->menu_stack;
info.type = 0; info.type = 0;
info.directory_ptr = idx; info.directory_ptr = idx;
@ -111,6 +110,7 @@ static int action_ok_file_load_with_detect_core(const char *path,
} }
ret = menu_displaylist_push_list(&info, DISPLAYLIST_GENERIC); ret = menu_displaylist_push_list(&info, DISPLAYLIST_GENERIC);
break;
} }
return ret; return ret;

View File

@ -128,10 +128,10 @@ void menu_input_st_string_callback(void *userdata, const char *str)
if (str && *str) if (str && *str)
{ {
rarch_setting_t *current_setting = NULL;
global_t *global = global_get_ptr(); global_t *global = global_get_ptr();
rarch_setting_t *current_setting = menu_setting_find(menu->keyboard.label_setting);
if ((current_setting = menu_setting_find(menu->keyboard.label_setting))) if (current_setting)
{ {
setting_set_with_string_representation(current_setting, str); setting_set_with_string_representation(current_setting, str);
menu_setting_generic(current_setting, false); menu_setting_generic(current_setting, false);