mirror of
https://github.com/libretro/RetroArch.git
synced 2024-11-28 02:30:35 +00:00
Create wrapper function menu_list_push_stack_refresh
This commit is contained in:
parent
4c6aff67f2
commit
25efe98704
@ -503,7 +503,7 @@ static int menu_load_or_open_zip_iterate(unsigned action)
|
||||
char cat_path[PATH_MAX];
|
||||
|
||||
fill_pathname_join(cat_path, menu_path, path, sizeof(cat_path));
|
||||
menu_list_push_refresh(
|
||||
menu_list_push_stack_refresh(
|
||||
driver.menu->menu_stack,
|
||||
cat_path,
|
||||
menu_label,
|
||||
@ -523,7 +523,7 @@ static int menu_load_or_open_zip_iterate(unsigned action)
|
||||
return -1;
|
||||
}
|
||||
else if (ret == 0)
|
||||
menu_list_push_refresh(
|
||||
menu_list_push_stack_refresh(
|
||||
driver.menu->menu_stack,
|
||||
g_settings.libretro_directory,
|
||||
"deferred_core_list",
|
||||
|
@ -107,7 +107,7 @@ static int menu_entries_set_current_path_selection(
|
||||
switch (action)
|
||||
{
|
||||
case MENU_ACTION_OK:
|
||||
menu_list_push_refresh(
|
||||
menu_list_push_stack_refresh(
|
||||
driver.menu->menu_stack,
|
||||
start_path,
|
||||
label,
|
||||
|
@ -127,7 +127,7 @@ static int action_ok_push_content_list(const char *path,
|
||||
if (!driver.menu)
|
||||
return -1;
|
||||
|
||||
menu_list_push_refresh(
|
||||
menu_list_push_stack_refresh(
|
||||
driver.menu->menu_stack,
|
||||
g_settings.menu_content_directory,
|
||||
label,
|
||||
@ -154,7 +154,7 @@ static int action_ok_push_history_list(const char *path,
|
||||
if (!driver.menu)
|
||||
return -1;
|
||||
|
||||
menu_list_push_refresh(
|
||||
menu_list_push_stack_refresh(
|
||||
driver.menu->menu_stack,
|
||||
"",
|
||||
label,
|
||||
@ -169,7 +169,7 @@ static int action_ok_push_path_list(const char *path,
|
||||
if (!driver.menu)
|
||||
return -1;
|
||||
|
||||
menu_list_push_refresh(
|
||||
menu_list_push_stack_refresh(
|
||||
driver.menu->menu_stack,
|
||||
"",
|
||||
label,
|
||||
@ -343,7 +343,7 @@ static int action_ok_compressed_archive_push(const char *path,
|
||||
}
|
||||
|
||||
fill_pathname_join(cat_path, menu_path, path, sizeof(cat_path));
|
||||
menu_list_push_refresh(
|
||||
menu_list_push_stack_refresh(
|
||||
driver.menu->menu_stack,
|
||||
cat_path,
|
||||
menu_label,
|
||||
@ -366,7 +366,7 @@ static int action_ok_directory_push(const char *path,
|
||||
file_list_get_last(driver.menu->menu_stack, &menu_path, &menu_label, NULL);
|
||||
|
||||
fill_pathname_join(cat_path, menu_path, path, sizeof(cat_path));
|
||||
menu_list_push_refresh(
|
||||
menu_list_push_stack_refresh(
|
||||
driver.menu->menu_stack,
|
||||
cat_path,
|
||||
menu_label,
|
||||
@ -441,7 +441,7 @@ static int action_ok_file_load_with_detect_core(const char *path,
|
||||
return -1;
|
||||
}
|
||||
else if (ret == 0)
|
||||
menu_list_push_refresh(
|
||||
menu_list_push_stack_refresh(
|
||||
driver.menu->menu_stack,
|
||||
g_settings.libretro_directory,
|
||||
"deferred_core_list",
|
||||
@ -639,7 +639,7 @@ static int action_ok_core_list(const char *path,
|
||||
if (!driver.menu)
|
||||
return -1;
|
||||
|
||||
menu_list_push_refresh(driver.menu->menu_stack,
|
||||
menu_list_push_stack_refresh(driver.menu->menu_stack,
|
||||
dir, label, type,
|
||||
driver.menu->selection_ptr);
|
||||
|
||||
@ -654,7 +654,7 @@ static int action_ok_disk_image_append_list(const char *path,
|
||||
if (!driver.menu)
|
||||
return -1;
|
||||
|
||||
menu_list_push_refresh(driver.menu->menu_stack,
|
||||
menu_list_push_stack_refresh(driver.menu->menu_stack,
|
||||
dir, label, type,
|
||||
driver.menu->selection_ptr);
|
||||
return 0;
|
||||
@ -667,7 +667,7 @@ static int action_ok_configurations_list(const char *path,
|
||||
if (!driver.menu)
|
||||
return -1;
|
||||
|
||||
menu_list_push_refresh(driver.menu->menu_stack,
|
||||
menu_list_push_stack_refresh(driver.menu->menu_stack,
|
||||
dir ? dir : label, label, type,
|
||||
driver.menu->selection_ptr);
|
||||
return 0;
|
||||
@ -679,7 +679,7 @@ static int action_ok_push_default(const char *path,
|
||||
if (!driver.menu)
|
||||
return -1;
|
||||
|
||||
menu_list_push_refresh(driver.menu->menu_stack,
|
||||
menu_list_push_stack_refresh(driver.menu->menu_stack,
|
||||
label, label, type,
|
||||
driver.menu->selection_ptr);
|
||||
return 0;
|
||||
@ -799,7 +799,7 @@ static int action_ok_shader_pass(const char *path,
|
||||
if (!driver.menu)
|
||||
return -1;
|
||||
|
||||
menu_list_push_refresh(
|
||||
menu_list_push_stack_refresh(
|
||||
driver.menu->menu_stack,
|
||||
g_settings.video.shader_dir,
|
||||
"video_shader_pass",
|
||||
@ -833,7 +833,7 @@ static int action_ok_shader_preset(const char *path,
|
||||
if (!driver.menu)
|
||||
return -1;
|
||||
|
||||
menu_list_push_refresh(
|
||||
menu_list_push_stack_refresh(
|
||||
driver.menu->menu_stack,
|
||||
g_settings.video.shader_dir,
|
||||
"video_shader_preset",
|
||||
@ -997,7 +997,7 @@ static int action_ok_shader_parameters(const char *path,
|
||||
const char *label, unsigned type, size_t index)
|
||||
{
|
||||
#ifdef HAVE_SHADER_MANAGER
|
||||
menu_list_push_refresh(
|
||||
menu_list_push_stack_refresh(
|
||||
driver.menu->menu_stack, "",
|
||||
"video_shader_parameters",
|
||||
MENU_FILE_PUSH,
|
||||
|
@ -203,3 +203,14 @@ void menu_list_push_stack(file_list_t *list,
|
||||
{
|
||||
menu_list_push(list, path, label, type, directory_ptr);
|
||||
}
|
||||
|
||||
void menu_list_push_stack_refresh(file_list_t *list,
|
||||
const char *path, const char *label,
|
||||
unsigned type, size_t directory_ptr)
|
||||
{
|
||||
if (!list)
|
||||
return;
|
||||
menu_list_push_stack(list, path, label, type, directory_ptr);
|
||||
menu_navigation_clear(driver.menu, true);
|
||||
driver.menu->need_refresh = true;
|
||||
}
|
||||
|
@ -56,6 +56,10 @@ void menu_list_push_stack(file_list_t *list,
|
||||
const char *path, const char *label,
|
||||
unsigned type, size_t directory_ptr);
|
||||
|
||||
void menu_list_push_stack_refresh(file_list_t *list,
|
||||
const char *path, const char *label,
|
||||
unsigned type, size_t directory_ptr);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
@ -2384,7 +2384,7 @@ static void general_write_handler(void *data)
|
||||
if (*setting->value.boolean)
|
||||
{
|
||||
#ifdef HAVE_MENU
|
||||
menu_list_push_refresh(
|
||||
menu_list_push_stack_refresh(
|
||||
driver.menu->menu_stack,
|
||||
"",
|
||||
"help",
|
||||
|
Loading…
Reference in New Issue
Block a user