mirror of
https://github.com/Relintai/broken_seals.git
synced 2024-11-20 21:07:17 +01:00
Now the wortld generator addon's datalist popup will focus the line edit for changing the resource's name. Also it will accept enter as ok.
This commit is contained in:
parent
7c861eda5d
commit
b101213d84
@ -13,7 +13,7 @@ var _undo_redo : UndoRedo = null
|
||||
|
||||
func _init():
|
||||
connect("item_activated", self, "on_item_activated")
|
||||
|
||||
|
||||
func set_plugin(plugin : EditorPlugin) -> void:
|
||||
_plugin = plugin
|
||||
_undo_redo = _plugin.get_undo_redo()
|
||||
@ -115,6 +115,10 @@ func name_edit_dialog_ok_pressed() -> void:
|
||||
name_edited_resource.emit_changed()
|
||||
name_edited_resource = null
|
||||
on_resource_changed()
|
||||
|
||||
func name_edit_dialog_line_edit_text_entered(var s : String) -> void:
|
||||
$NameEditDialog.hide()
|
||||
name_edit_dialog_ok_pressed()
|
||||
|
||||
func delete_button_pressed() -> void:
|
||||
var item : TreeItem = get_selected()
|
||||
|
@ -81,4 +81,6 @@ margin_right = 207.0
|
||||
margin_bottom = 42.0
|
||||
|
||||
[connection signal="confirmed" from="NameDialog" to="." method="name_dialog_ok_pressed"]
|
||||
[connection signal="about_to_show" from="NameEditDialog" to="NameEditDialog/VBoxContainer/LineEdit" method="grab_focus" flags=3]
|
||||
[connection signal="confirmed" from="NameEditDialog" to="." method="name_edit_dialog_ok_pressed"]
|
||||
[connection signal="text_entered" from="NameEditDialog/VBoxContainer/LineEdit" to="." method="name_edit_dialog_line_edit_text_entered"]
|
||||
|
@ -398,6 +398,7 @@ zone_bevel = 0.3
|
||||
zone_base = 0.0
|
||||
|
||||
[sub_resource type="Resource" id=21]
|
||||
resource_name = "C"
|
||||
script = ExtResource( 3 )
|
||||
rect = Rect2( 241, 247, 40, 25 )
|
||||
min_size = Vector2i( 1, 1 )
|
||||
|
Loading…
Reference in New Issue
Block a user