mirror of
https://github.com/libretro/RetroArch.git
synced 2024-11-23 16:09:47 +00:00
Create RARCH_MENU_CTL_CONTEXT_RESET
This commit is contained in:
parent
825b259650
commit
3f4b0012d3
2
driver.c
2
driver.c
@ -361,7 +361,7 @@ static void init_drivers(int flags)
|
||||
if (flags & DRIVER_MENU)
|
||||
{
|
||||
init_menu();
|
||||
menu_driver_context_reset();
|
||||
menu_driver_ctl(RARCH_MENU_CTL_CONTEXT_RESET, NULL);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
@ -231,15 +231,6 @@ void *menu_driver_list_get_entry(menu_list_type_t type, unsigned i)
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void menu_driver_context_reset(void)
|
||||
{
|
||||
const menu_ctx_driver_t *driver = menu_driver_ctx;
|
||||
|
||||
if (driver->context_reset)
|
||||
driver->context_reset(menu_userdata ? menu_userdata : NULL);
|
||||
}
|
||||
|
||||
|
||||
int menu_driver_bind_init(menu_file_list_cbs_t *cbs,
|
||||
const char *path, const char *label, unsigned type, size_t idx,
|
||||
const char *elem0, const char *elem1,
|
||||
@ -864,6 +855,10 @@ bool menu_driver_ctl(enum rarch_menu_ctl_state state, void *data)
|
||||
#endif
|
||||
}
|
||||
break;
|
||||
case RARCH_MENU_CTL_CONTEXT_RESET:
|
||||
if (driver->context_reset)
|
||||
driver->context_reset(menu_userdata ? menu_userdata : NULL);
|
||||
break;
|
||||
default:
|
||||
case RARCH_MENU_CTL_NONE:
|
||||
break;
|
||||
|
@ -129,6 +129,7 @@ enum rarch_menu_ctl_state
|
||||
RARCH_MENU_CTL_PLAYLIST_GET,
|
||||
RARCH_MENU_CTL_LIST_CLEAR,
|
||||
RARCH_MENU_CTL_TOGGLE,
|
||||
RARCH_MENU_CTL_CONTEXT_RESET,
|
||||
RARCH_MENU_CTL_POPULATE_ENTRIES
|
||||
};
|
||||
|
||||
@ -348,8 +349,6 @@ void init_menu(void);
|
||||
|
||||
menu_handle_t *menu_driver_get_ptr(void);
|
||||
|
||||
void menu_driver_context_reset(void);
|
||||
|
||||
void menu_driver_free(menu_handle_t *menu);
|
||||
|
||||
bool menu_driver_load_image(void *data, menu_image_type_t type);
|
||||
|
Loading…
Reference in New Issue
Block a user