projects
/
The Cutests To-Do List.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
222d4d4
)
check if animation playing (fix weird bug on touch screen)
author
Eduardo
<
[email protected]
>
Mon, 2 Oct 2023 21:42:41 +0000
(23:42 +0200)
committer
Eduardo
<
[email protected]
>
Mon, 2 Oct 2023 21:42:41 +0000
(23:42 +0200)
themes/default/buttons/menu_button/MenuButton.gd
patch
|
blob
|
history
diff --git
a/themes/default/buttons/menu_button/MenuButton.gd
b/themes/default/buttons/menu_button/MenuButton.gd
index caceddd9bf04a5eab6db9559e534f4dda9cf0659..c957b4a233a6caa0430ac76f44edaaf28a6bebd3 100644
(file)
--- a/
themes/default/buttons/menu_button/MenuButton.gd
+++ b/
themes/default/buttons/menu_button/MenuButton.gd
@@
-28,9
+28,11
@@
func toggle_menu():
menu_opened = !menu_opened
if menu_opened:
- animation_player.play("transform to close")
+ if !animation_player.is_playing():
+ animation_player.play("transform to close")
else:
- animation_player.play_backwards("transform to close")
+ if !animation_player.is_playing():
+ animation_player.play_backwards("transform to close")
for b in buttons:
b.visible = menu_opened