You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-07 12:30:27 +00:00
Signals: Port connect calls to use callable_mp
Remove now unnecessary bindings of signal callbacks in the public API. There might be some false positives that need rebinding if they were meant to be public. No regular expressions were harmed in the making of this commit. (Nah, just kidding.)
This commit is contained in:
@@ -44,7 +44,7 @@ void EditorPluginSettings::_notification(int p_what) {
|
||||
update_plugins();
|
||||
} else if (p_what == Node::NOTIFICATION_READY) {
|
||||
plugin_config_dialog->connect_compat("plugin_ready", EditorNode::get_singleton(), "_on_plugin_ready");
|
||||
plugin_list->connect_compat("button_pressed", this, "_cell_button_pressed");
|
||||
plugin_list->connect("button_pressed", callable_mp(this, &EditorPluginSettings::_cell_button_pressed));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -202,11 +202,6 @@ void EditorPluginSettings::_cell_button_pressed(Object *p_item, int p_column, in
|
||||
}
|
||||
|
||||
void EditorPluginSettings::_bind_methods() {
|
||||
|
||||
ClassDB::bind_method("update_plugins", &EditorPluginSettings::update_plugins);
|
||||
ClassDB::bind_method("_create_clicked", &EditorPluginSettings::_create_clicked);
|
||||
ClassDB::bind_method("_plugin_activity_changed", &EditorPluginSettings::_plugin_activity_changed);
|
||||
ClassDB::bind_method("_cell_button_pressed", &EditorPluginSettings::_cell_button_pressed);
|
||||
}
|
||||
|
||||
EditorPluginSettings::EditorPluginSettings() {
|
||||
@@ -219,10 +214,10 @@ EditorPluginSettings::EditorPluginSettings() {
|
||||
title_hb->add_child(memnew(Label(TTR("Installed Plugins:"))));
|
||||
title_hb->add_spacer();
|
||||
create_plugin = memnew(Button(TTR("Create")));
|
||||
create_plugin->connect_compat("pressed", this, "_create_clicked");
|
||||
create_plugin->connect("pressed", callable_mp(this, &EditorPluginSettings::_create_clicked));
|
||||
title_hb->add_child(create_plugin);
|
||||
update_list = memnew(Button(TTR("Update")));
|
||||
update_list->connect_compat("pressed", this, "update_plugins");
|
||||
update_list->connect("pressed", callable_mp(this, &EditorPluginSettings::update_plugins));
|
||||
title_hb->add_child(update_list);
|
||||
add_child(title_hb);
|
||||
|
||||
@@ -245,7 +240,7 @@ EditorPluginSettings::EditorPluginSettings() {
|
||||
plugin_list->set_column_min_width(3, 80 * EDSCALE);
|
||||
plugin_list->set_column_min_width(4, 40 * EDSCALE);
|
||||
plugin_list->set_hide_root(true);
|
||||
plugin_list->connect_compat("item_edited", this, "_plugin_activity_changed");
|
||||
plugin_list->connect("item_edited", callable_mp(this, &EditorPluginSettings::_plugin_activity_changed));
|
||||
|
||||
VBoxContainer *mc = memnew(VBoxContainer);
|
||||
mc->add_child(plugin_list);
|
||||
|
||||
Reference in New Issue
Block a user