mirror of
https://github.com/libretro/RetroArch
synced 2025-04-01 13:20:43 +00:00
(Zarch) Remember last header selection
This commit is contained in:
parent
a3adec9417
commit
fa82818ad2
@ -1166,6 +1166,7 @@ static int zarch_iterate(enum menu_action action)
|
|||||||
int ret = 0;
|
int ret = 0;
|
||||||
menu_entry_t entry;
|
menu_entry_t entry;
|
||||||
zui_t *zui = NULL;
|
zui_t *zui = NULL;
|
||||||
|
static ssize_t header_selection_last = 0;
|
||||||
menu_handle_t *menu = menu_driver_get_ptr();
|
menu_handle_t *menu = menu_driver_get_ptr();
|
||||||
enum menu_action act = (enum menu_action)action;
|
enum menu_action act = (enum menu_action)action;
|
||||||
bool perform_action = true;
|
bool perform_action = true;
|
||||||
@ -1204,13 +1205,14 @@ static int zarch_iterate(enum menu_action action)
|
|||||||
case MENU_ACTION_UP:
|
case MENU_ACTION_UP:
|
||||||
if (zui->entries_selection == 0)
|
if (zui->entries_selection == 0)
|
||||||
{
|
{
|
||||||
zui->header_selection = 0;
|
zui->header_selection = header_selection_last;
|
||||||
perform_action = false;
|
perform_action = false;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case MENU_ACTION_DOWN:
|
case MENU_ACTION_DOWN:
|
||||||
if (zui->header_selection != -1)
|
if (zui->header_selection != -1)
|
||||||
{
|
{
|
||||||
|
header_selection_last = zui->header_selection;
|
||||||
zui->header_selection = -1;
|
zui->header_selection = -1;
|
||||||
zui->entries_selection = 0;
|
zui->entries_selection = 0;
|
||||||
perform_action = false;
|
perform_action = false;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user