Merge pull request #28 from Calinou/filter-shortcut-select-all

Select the text in the filter LineEdit when pressing the shortcut
This commit is contained in:
Rodz Labs 2019-10-19 06:40:54 +02:00 committed by GitHub
commit 49f5d54acf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -19,6 +19,7 @@ func _ready():
func _unhandled_input(event : InputEvent) -> void:
if event is InputEventKey and event.pressed and event.command and event.scancode == KEY_F:
filter_line_edit.grab_focus()
filter_line_edit.select_all()
func get_selected_item_name():
var tree_item : TreeItem = tree.get_selected()