mirror of
https://github.com/Orama-Interactive/Pixelorama.git
synced 2025-01-30 23:19:49 +00:00
Made tool keyboard shortcuts fire on action release
This commit is contained in:
parent
3b8a790cfb
commit
c02cda6b10
|
@ -235,9 +235,9 @@ func _input(event : InputEvent) -> void:
|
||||||
if event.is_action_pressed("undo") or event.is_action_pressed("redo") or event.is_action_pressed("redo_secondary"):
|
if event.is_action_pressed("undo") or event.is_action_pressed("redo") or event.is_action_pressed("redo_secondary"):
|
||||||
return
|
return
|
||||||
for t in tools: # Handle tool shortcuts
|
for t in tools: # Handle tool shortcuts
|
||||||
if event.is_action_pressed(t[2]): # Shortcut for right button (with Alt)
|
if event.is_action_released(t[2]): # Shortcut for right button (with Alt)
|
||||||
_on_Tool_pressed(t[0], false, false)
|
_on_Tool_pressed(t[0], false, false)
|
||||||
elif event.is_action_pressed(t[1]): # Shortcut for left button
|
elif event.is_action_released(t[1]): # Shortcut for left button
|
||||||
_on_Tool_pressed(t[0], false, true)
|
_on_Tool_pressed(t[0], false, true)
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue