X-Git-Url: https://git.artsoft.org/?p=rocksndiamonds.git;a=blobdiff_plain;f=src%2Fanim.c;h=71f9958857020ce938ee3edc49277b18333fa9a0;hp=2ebf520f79d793a365b5acdedfbdc77a5ea263e5;hb=c271d9388070fd4ae23f7b75abab9045bd81bb73;hpb=f50b39e5a25f45c554d42130174da25d90131e57 diff --git a/src/anim.c b/src/anim.c index 2ebf520f..71f99588 100644 --- a/src/anim.c +++ b/src/anim.c @@ -1795,7 +1795,7 @@ static void ResetGlobalAnim_Clicked(void) InitGlobalAnim_Clicked(-1, -1, ANIM_CLICKED_RESET); } -boolean HandleGlobalAnimClicks(int mx, int my, int button) +boolean HandleGlobalAnimClicks(int mx, int my, int button, boolean force_click) { static boolean click_consumed = FALSE; static int last_button = 0; @@ -1803,6 +1803,9 @@ boolean HandleGlobalAnimClicks(int mx, int my, int button) boolean release_event; boolean click_consumed_current = click_consumed; + if (button != 0 && force_click) + last_button = 0; + // check if button state has changed since last invocation press_event = (button != 0 && last_button == 0); release_event = (button == 0 && last_button != 0);