input_state_internal - small cleanup for RETRO_DEVICE_JOYPAD

This commit is contained in:
twinaphex 2019-07-09 07:02:24 +02:00
parent f94a924be9
commit 5aebbdfddb

View File

@ -3315,16 +3315,10 @@ static int16_t input_state_internal(
bool bind_valid = libretro_input_binds[port]
&& libretro_input_binds[port][id].valid;
if (bind_valid)
{
/* reset_state - used to reset input state of a button
* when the gamepad mapper is in action for that button*/
bool reset_state = false;
if (settings->bools.input_remap_binds_enable)
if (id != settings->uints.input_remap_ids[port][id])
reset_state = true;
if (!reset_state)
if (settings->bools.input_remap_binds_enable &&
id != settings->uints.input_remap_ids[port][id])
res = 0;
else if (bind_valid)
{
if (button_mask)
{
@ -3340,9 +3334,6 @@ static int16_t input_state_internal(
res |= res_overlay;
#endif
}
else
res = 0;
}
}
if (settings->bools.input_remap_binds_enable && input_driver_mapper)