From 80f7a0ca1368613bb2663155315a4cc4f1a75f25 Mon Sep 17 00:00:00 2001 From: OverloadedOrama <35376950+OverloadedOrama@users.noreply.github.com> Date: Thu, 19 Dec 2019 17:07:26 +0200 Subject: [PATCH] Added Shift+Ctrl+Z as a secondary shortcut for Redo --- Scripts/Main.gd | 5 +++++ project.godot | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/Scripts/Main.gd b/Scripts/Main.gd index 34b1f0e4d..8e2ff83b2 100644 --- a/Scripts/Main.gd +++ b/Scripts/Main.gd @@ -187,6 +187,11 @@ func _input(event : InputEvent) -> void: if event.is_action_pressed("toggle_fullscreen"): OS.window_fullscreen = !OS.window_fullscreen + if event.is_action_pressed("redo_secondary"): #Shift + Ctrl + Z + redone = true + Global.undo_redo.redo() + redone = false + if Global.has_focus: for t in tools: #Handle tool shortcuts if event.is_action_pressed(t[2]): #Shortcut for right button (with Alt) diff --git a/project.godot b/project.godot index 6b16638ca..674d6a0ed 100644 --- a/project.godot +++ b/project.godot @@ -190,6 +190,11 @@ ctrl={ "events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777238,"unicode":0,"echo":false,"script":null) ] } +redo_secondary={ +"deadzone": 0.5, +"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":true,"control":true,"meta":false,"command":true,"pressed":false,"scancode":90,"unicode":0,"echo":false,"script":null) + ] +} [locale]