changed only handling pointer-style animations clicks in request dialogs
authorHolger Schemel <info@artsoft.org>
Sat, 9 Dec 2023 16:44:11 +0000 (17:44 +0100)
committerHolger Schemel <info@artsoft.org>
Sat, 9 Dec 2023 16:50:09 +0000 (17:50 +0100)
As request dialogs are displayed above all other screen elements,
including global animations (except pointer-style global animations),
global animations should not be clickable while request dialogs are
active, with the exception of clickable pointer-style animations,
which is generally used to display a different pointer while the
mouse button is pressed.

src/anim.c

index 3c58fa917d04072d2e9e1263efe3bccd3fb52a70..7ef6d6904b6a6243923e98dcfb5909aedbf6b32e 100644 (file)
@@ -2139,6 +2139,11 @@ static boolean InitGlobalAnim_Clicked(int mx, int my, int clicked_event)
       {
        struct GlobalAnimPartControlInfo *part = &anim->part[part_nr];
 
+       // if request dialog is active, only handle pointer-style animations
+       if (game.request_active &&
+           part->control_info.class != get_hash_from_key("pointer"))
+         continue;
+
        if (clicked_event == ANIM_CLICKED_RESET)
        {
          part->clicked = FALSE;