mirror of
https://github.com/libretro/RetroArch
synced 2025-03-29 22:20:21 +00:00
Don't call menu_driver_render from menu_input.c
This commit is contained in:
parent
032abfffd4
commit
1c38e9ae05
@ -469,11 +469,10 @@ static int action_iterate_main(const char *label, unsigned action)
|
||||
break;
|
||||
case ITERATE_TYPE_BIND:
|
||||
if (menu_input_bind_iterate(msg, sizeof(msg)))
|
||||
{
|
||||
if (msg[0] != '\0')
|
||||
do_messagebox = true;
|
||||
menu_list_pop_stack(menu_list);
|
||||
}
|
||||
else
|
||||
do_messagebox = true;
|
||||
do_render = true;
|
||||
break;
|
||||
case ITERATE_TYPE_VIEWPORT:
|
||||
ret = action_iterate_menu_viewport(msg, sizeof(msg), label, action, hash);
|
||||
|
@ -531,34 +531,29 @@ static int menu_input_bind_iterate_keyboard(int64_t current, int timeout)
|
||||
|
||||
int menu_input_bind_iterate(char *s, size_t len)
|
||||
{
|
||||
int64_t current;
|
||||
struct menu_bind_state binds;
|
||||
int timeout = 0;
|
||||
menu_input_t *menu_input = menu_input_get_ptr();
|
||||
driver_t *driver = driver_get_ptr();
|
||||
global_t *global = global_get_ptr();
|
||||
bool bind_mode_kb = global ? global->menu.bind_mode_keyboard : false;
|
||||
|
||||
menu_driver_render();
|
||||
|
||||
current = rarch_get_time_usec();
|
||||
timeout = (menu_input->binds.timeout_end - current) / 1000000;
|
||||
|
||||
if (bind_mode_kb)
|
||||
snprintf(s, len,
|
||||
"[%s]\npress keyboard\n(timeout %d %s)",
|
||||
input_config_bind_map[
|
||||
menu_input->binds.begin - MENU_SETTINGS_BIND_BEGIN].desc,
|
||||
timeout,
|
||||
menu_hash_to_str(MENU_VALUE_SECONDS));
|
||||
else
|
||||
snprintf(s, len,
|
||||
"[%s]\npress joypad\n(RETURN to skip)",
|
||||
input_config_bind_map[
|
||||
menu_input->binds.begin - MENU_SETTINGS_BIND_BEGIN].desc);
|
||||
int64_t current = rarch_get_time_usec();
|
||||
int timeout = (menu_input->binds.timeout_end - current) / 1000000;
|
||||
|
||||
if (bind_mode_kb)
|
||||
{
|
||||
snprintf(s, len,
|
||||
"[%s]\npress keyboard\n(timeout %d %s)",
|
||||
input_config_bind_map[
|
||||
menu_input->binds.begin - MENU_SETTINGS_BIND_BEGIN].desc,
|
||||
timeout,
|
||||
menu_hash_to_str(MENU_VALUE_SECONDS));
|
||||
return menu_input_bind_iterate_keyboard(current, timeout);
|
||||
}
|
||||
else
|
||||
snprintf(s, len,
|
||||
"[%s]\npress joypad\n(RETURN to skip)",
|
||||
input_config_bind_map[
|
||||
menu_input->binds.begin - MENU_SETTINGS_BIND_BEGIN].desc);
|
||||
|
||||
binds = menu_input->binds;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user