Textedit save shortcut

This commit is contained in:
bleeptrack 2020-10-06 11:34:12 +02:00
parent 812bf48b55
commit c400653f9d
2 changed files with 9 additions and 0 deletions

View file

@ -106,6 +106,11 @@ tab_complete={
"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":16777218,"unicode":0,"echo":false,"script":null)
]
}
save={
"deadzone": 0.5,
"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":true,"meta":false,"command":true,"pressed":false,"scancode":83,"unicode":0,"echo":false,"script":null)
]
}
[network]

View file

@ -20,6 +20,10 @@ func _process(_delta):
filename = filename.replace("%srepos/" % game.tmp_prefix_inside, "")
open(filename)
func _input(event):
if event.is_action_pressed("save"):
save()
func open(filename):
path = filename