1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-08 12:40:44 +00:00

[Scene] Add SceneStringNames::pressed

This commit is contained in:
A Thousand Ships
2024-05-14 09:40:21 +02:00
parent 78cce1954d
commit ee79386f7b
147 changed files with 727 additions and 722 deletions

View File

@@ -177,7 +177,7 @@ void AnimationNodeBlendTreeEditor::update_graph() {
delete_button->set_flat(true);
delete_button->set_focus_mode(FOCUS_NONE);
delete_button->set_icon(get_editor_theme_icon(SNAME("Close")));
delete_button->connect("pressed", callable_mp(this, &AnimationNodeBlendTreeEditor::_delete_node_request).bind(E), CONNECT_DEFERRED);
delete_button->connect(SceneStringName(pressed), callable_mp(this, &AnimationNodeBlendTreeEditor::_delete_node_request).bind(E), CONNECT_DEFERRED);
node->get_titlebar_hbox()->add_child(delete_button);
}
}
@@ -216,7 +216,7 @@ void AnimationNodeBlendTreeEditor::update_graph() {
open_in_editor->set_text(TTR("Open Editor"));
open_in_editor->set_icon(get_editor_theme_icon(SNAME("Edit")));
node->add_child(open_in_editor);
open_in_editor->connect("pressed", callable_mp(this, &AnimationNodeBlendTreeEditor::_open_in_editor).bind(E), CONNECT_DEFERRED);
open_in_editor->connect(SceneStringName(pressed), callable_mp(this, &AnimationNodeBlendTreeEditor::_open_in_editor).bind(E), CONNECT_DEFERRED);
open_in_editor->set_h_size_flags(SIZE_SHRINK_CENTER);
}
@@ -230,7 +230,7 @@ void AnimationNodeBlendTreeEditor::update_graph() {
}
inspect_filters->set_icon(get_editor_theme_icon(SNAME("AnimationFilter")));
node->add_child(inspect_filters);
inspect_filters->connect("pressed", callable_mp(this, &AnimationNodeBlendTreeEditor::_inspect_filters).bind(E), CONNECT_DEFERRED);
inspect_filters->connect(SceneStringName(pressed), callable_mp(this, &AnimationNodeBlendTreeEditor::_inspect_filters).bind(E), CONNECT_DEFERRED);
inspect_filters->set_h_size_flags(SIZE_SHRINK_CENTER);
}
@@ -1232,22 +1232,22 @@ AnimationNodeBlendTreeEditor::AnimationNodeBlendTreeEditor() {
filter_enabled = memnew(CheckBox);
filter_enabled->set_text(TTR("Enable Filtering"));
filter_enabled->connect("pressed", callable_mp(this, &AnimationNodeBlendTreeEditor::_filter_toggled));
filter_enabled->connect(SceneStringName(pressed), callable_mp(this, &AnimationNodeBlendTreeEditor::_filter_toggled));
filter_hbox->add_child(filter_enabled);
filter_fill_selection = memnew(Button);
filter_fill_selection->set_text(TTR("Fill Selected Children"));
filter_fill_selection->connect("pressed", callable_mp(this, &AnimationNodeBlendTreeEditor::_filter_fill_selection));
filter_fill_selection->connect(SceneStringName(pressed), callable_mp(this, &AnimationNodeBlendTreeEditor::_filter_fill_selection));
filter_hbox->add_child(filter_fill_selection);
filter_invert_selection = memnew(Button);
filter_invert_selection->set_text(TTR("Invert"));
filter_invert_selection->connect("pressed", callable_mp(this, &AnimationNodeBlendTreeEditor::_filter_invert_selection));
filter_invert_selection->connect(SceneStringName(pressed), callable_mp(this, &AnimationNodeBlendTreeEditor::_filter_invert_selection));
filter_hbox->add_child(filter_invert_selection);
filter_clear_selection = memnew(Button);
filter_clear_selection->set_text(TTR("Clear"));
filter_clear_selection->connect("pressed", callable_mp(this, &AnimationNodeBlendTreeEditor::_filter_clear_selection));
filter_clear_selection->connect(SceneStringName(pressed), callable_mp(this, &AnimationNodeBlendTreeEditor::_filter_clear_selection));
filter_hbox->add_child(filter_clear_selection);
filters = memnew(Tree);