-
-
Notifications
You must be signed in to change notification settings - Fork 20.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix action exact match (Also fixes ui_ focus keys) #54173
Conversation
9984b9b
to
e8e53d7
Compare
e8e53d7
to
f0ba99d
Compare
f0ba99d
to
e0bd576
Compare
1939a23
to
d880c6e
Compare
cffdf79
to
ab489b3
Compare
ab489b3
to
52fed27
Compare
52fed27
to
ef3d178
Compare
ef3d178
to
0f1dcde
Compare
Thanks for reviewing, sorry for missing those extra consts so many times now! Should be ready now. |
0f1dcde
to
dc1c4cf
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Haven't checked it in deep, but all changes seems reasonable, and it fixes keyboard navigation.
// Matches even if not in the same direction, but returns a "not pressed" event. | ||
bool match = axis == jm->axis; | ||
if (p_exact_match) { | ||
match &= (axis_value < 0) == (jm->axis_value < 0); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm a bit concerned about the potential impact of this change on joypad motion events.
I guess let's merge and assess while testing whether this is working as expected.
Thanks! |
Fixes #54602
Fixes #55622
Supersedes #54842
3.x version: #54174
Previously,
event.is_action_pressed("test", false, true)
always returned false, whileevent.is_action_released("test", false, true)
returned true both for pressed and released. This is because the pressed pointer was not passed intois_match
. This PR fixes it by usingaction_match
instead.MRP: Test10.zip