mirror of
https://github.com/libretro/RetroArch
synced 2025-03-28 19:20:35 +00:00
Cleanups
This commit is contained in:
parent
826a5009b0
commit
b4733fd6c2
@ -71,7 +71,6 @@ int generic_menu_iterate(void *data, void *userdata, enum menu_action action)
|
||||
enum msg_hash_enums enum_idx = MSG_UNKNOWN;
|
||||
const char *label = NULL;
|
||||
menu_handle_t *menu = (menu_handle_t*)data;
|
||||
size_t selection = menu_navigation_get_selection();
|
||||
|
||||
menu_entries_get_last_stack(NULL, &label, &file_type, &enum_idx, NULL);
|
||||
|
||||
@ -119,6 +118,7 @@ int generic_menu_iterate(void *data, void *userdata, enum menu_action action)
|
||||
|
||||
if (menu_input_key_bind_iterate(&bind))
|
||||
{
|
||||
size_t selection = menu_navigation_get_selection();
|
||||
menu_entries_pop_stack(&selection, 0, 0);
|
||||
menu_navigation_set_selection(selection);
|
||||
}
|
||||
@ -129,6 +129,7 @@ int generic_menu_iterate(void *data, void *userdata, enum menu_action action)
|
||||
case ITERATE_TYPE_INFO:
|
||||
{
|
||||
file_list_t *selection_buf = menu_entries_get_selection_buf_ptr(0);
|
||||
size_t selection = menu_navigation_get_selection();
|
||||
menu_file_list_cbs_t *cbs = selection_buf ?
|
||||
(menu_file_list_cbs_t*)
|
||||
file_list_get_actiondata_at_offset(selection_buf, selection)
|
||||
@ -143,6 +144,7 @@ int generic_menu_iterate(void *data, void *userdata, enum menu_action action)
|
||||
{
|
||||
unsigned type = 0;
|
||||
enum msg_hash_enums enum_idx = MSG_UNKNOWN;
|
||||
size_t selection = menu_navigation_get_selection();
|
||||
menu_entries_get_at_offset(selection_buf, selection,
|
||||
NULL, NULL, &type, NULL, NULL);
|
||||
|
||||
@ -218,6 +220,7 @@ int generic_menu_iterate(void *data, void *userdata, enum menu_action action)
|
||||
case ITERATE_TYPE_DEFAULT:
|
||||
{
|
||||
menu_entry_t entry;
|
||||
size_t selection = menu_navigation_get_selection();
|
||||
/* FIXME: Crappy hack, needed for mouse controls
|
||||
* to not be completely broken in case we press back.
|
||||
*
|
||||
@ -245,6 +248,7 @@ int generic_menu_iterate(void *data, void *userdata, enum menu_action action)
|
||||
|
||||
if (BIT64_GET(menu->state, MENU_STATE_POP_STACK))
|
||||
{
|
||||
size_t selection = menu_navigation_get_selection();
|
||||
size_t new_selection_ptr = selection;
|
||||
menu_entries_pop_stack(&new_selection_ptr, 0, 0);
|
||||
menu_navigation_set_selection(selection);
|
||||
|
Loading…
x
Reference in New Issue
Block a user