diff options
author | Roman Artiukhin <bahusdrive@gmail.com> | 2024-10-02 18:52:57 +0300 |
---|---|---|
committer | Solomon Peachy <pizza@shaftnet.org> | 2024-10-22 06:52:28 -0400 |
commit | c354e0bd1f0842b56e9a913d302ee17ec1474db6 (patch) | |
tree | af07750a978cdb7b502cb384f730a79b844aaf1f | |
parent | 5a3d62dabbc4c456b63db9c3416a922728c97053 (diff) | |
download | rockbox-c354e0bd1f0842b56e9a913d302ee17ec1474db6.tar.gz rockbox-c354e0bd1f0842b56e9a913d302ee17ec1474db6.zip |
buttons: Don't set wait_for_release for release action
Fixes ignored button press in yes/no screen.
It depends on keymapping - this issue happens if action before wait_for_release is mapped on release action. Something like:
{ ACTION_STD_OK, BUTTON_SELECT|BUTTON_REL, BUTTON_SELECT }
Change-Id: Idc6a57ef7a7daf75c21c9887e07fbefc814b6ae3
-rw-r--r-- | apps/action.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/apps/action.c b/apps/action.c index 2286e9fe29..9d66dd131b 100644 --- a/apps/action.c +++ b/apps/action.c | |||
@@ -1217,7 +1217,8 @@ bool action_userabort(int timeout) | |||
1217 | 1217 | ||
1218 | void action_wait_for_release(void) | 1218 | void action_wait_for_release(void) |
1219 | { | 1219 | { |
1220 | action_last.wait_for_release = true; | 1220 | if (!(action_last.button & BUTTON_REL)) |
1221 | action_last.wait_for_release = true; | ||
1221 | } | 1222 | } |
1222 | 1223 | ||
1223 | int get_action(int context, int timeout) | 1224 | int get_action(int context, int timeout) |