Skip to content

Commit

Permalink
Fix input bind hold when every axis does not rest on 0 (libretro#16256)
Browse files Browse the repository at this point in the history
  • Loading branch information
sonninnos authored and Sunderland93 committed Dec 26, 2024
1 parent 0653a7a commit 225927e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion menu/menu_driver.c
Original file line number Diff line number Diff line change
Expand Up @@ -1556,7 +1556,8 @@ static bool menu_input_key_bind_poll_find_hold_pad(
/* Axes are a bit tricky ... */
for (a = 0; a < MENU_MAX_AXES; a++)
{
if (abs(n->axes[a]) >= 20000)
if ( abs(n->axes[a]) >= 20000
&& n->axes[a] != new_state->axis_state[p].rested_axes[a])
{
/* Take care of case where axis rests on +/- 0x7fff
* (e.g. 360 controller on Linux) */
Expand Down

0 comments on commit 225927e

Please sign in to comment.