mirror of
https://github.com/libretro/RetroArch
synced 2025-02-20 15:40:44 +00:00
devices_mask no longer needed
This commit is contained in:
parent
d9fe9b23d7
commit
37e450c94c
@ -102,8 +102,6 @@ typedef struct menu_input
|
||||
{
|
||||
struct menu_bind_state binds;
|
||||
|
||||
uint64_t devices_mask;
|
||||
|
||||
menu_input_mouse_t mouse;
|
||||
|
||||
struct
|
||||
@ -671,7 +669,6 @@ int menu_input_key_bind_set_mode(void *data,
|
||||
menu_input_t *menu_input = menu_input_get_ptr();
|
||||
rarch_setting_t *setting = (rarch_setting_t*)data;
|
||||
settings_t *settings = config_get_ptr();
|
||||
bool joypad_pressed = BIT64_GET(menu_input->devices_mask, settings->menu_ok_btn);
|
||||
|
||||
if (!setting)
|
||||
return -1;
|
||||
@ -1156,7 +1153,7 @@ static unsigned menu_input_frame_pointer(unsigned *data)
|
||||
return ret;
|
||||
}
|
||||
|
||||
unsigned menu_input_frame_retropad(retro_input_t input, retro_input_t trigger_input, retro_input_t *devices)
|
||||
unsigned menu_input_frame_retropad(retro_input_t input, retro_input_t trigger_input)
|
||||
{
|
||||
float delta_time;
|
||||
unsigned ret = MENU_ACTION_NOOP;
|
||||
@ -1220,7 +1217,6 @@ unsigned menu_input_frame_retropad(retro_input_t input, retro_input_t trigger_in
|
||||
menu_animation_ctl(MENU_ANIMATION_CTL_DELTA_TIME, &delta_time);
|
||||
|
||||
menu_input->delay.count += delta_time / IDEAL_DT;
|
||||
menu_input->devices_mask = *devices;
|
||||
|
||||
if (menu_input->keyboard.display)
|
||||
{
|
||||
@ -1258,17 +1254,5 @@ unsigned menu_input_frame_retropad(retro_input_t input, retro_input_t trigger_in
|
||||
else if (trigger_input & (UINT64_C(1) << RARCH_MENU_TOGGLE))
|
||||
ret = MENU_ACTION_TOGGLE;
|
||||
|
||||
#if 0
|
||||
unsigned j;
|
||||
for (j = 0; j < 64; j++)
|
||||
{
|
||||
bool joypad_pressed = BIT64_GET(*devices, j);
|
||||
if (joypad_pressed)
|
||||
RARCH_LOG("Button %d pressed on gamepad\n", j);
|
||||
else
|
||||
RARCH_LOG("Button %d pressed on keyboard\n", j);
|
||||
}
|
||||
#endif
|
||||
|
||||
return menu_input_frame_pointer(&ret);
|
||||
}
|
||||
|
@ -117,7 +117,7 @@ void menu_input_st_string_callback(void *userdata, const char *str);
|
||||
|
||||
void menu_input_st_cheat_callback(void *userdata, const char *str);
|
||||
|
||||
unsigned menu_input_frame_retropad(retro_input_t input, retro_input_t trigger_state, retro_input_t *devices_mask);
|
||||
unsigned menu_input_frame_retropad(retro_input_t input, retro_input_t trigger_state);
|
||||
|
||||
void menu_input_post_iterate(int *ret, unsigned action);
|
||||
|
||||
|
@ -987,7 +987,7 @@ int rarch_main_iterate(unsigned *sleep_ms)
|
||||
#ifdef HAVE_MENU
|
||||
if (menu_driver_alive())
|
||||
{
|
||||
if (menu_driver_iterate((enum menu_action)menu_input_frame_retropad(input, trigger_input, &devices)) == -1)
|
||||
if (menu_driver_iterate((enum menu_action)menu_input_frame_retropad(input, trigger_input)) == -1)
|
||||
rarch_ctl(RARCH_ACTION_STATE_MENU_RUNNING_FINISHED, NULL);
|
||||
|
||||
if (!input && settings->menu.pause_libretro)
|
||||
|
Loading…
x
Reference in New Issue
Block a user