1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-18 14:21:41 +00:00

Reworked signal connection system, added support for Callable and Signal objects and made them default.

This commit is contained in:
Juan Linietsky
2020-02-19 16:27:19 -03:00
committed by Juan Linietsky
parent 1a4be2cd8f
commit 69c95f4b4c
275 changed files with 3831 additions and 2948 deletions

View File

@@ -305,10 +305,10 @@ void VisualShader::add_node(Type p_type, const Ref<VisualShaderNode> &p_node, co
if (input.is_valid()) {
input->shader_mode = shader_mode;
input->shader_type = p_type;
input->connect("input_type_changed", this, "_input_type_changed", varray(p_type, p_id));
input->connect_compat("input_type_changed", this, "_input_type_changed", varray(p_type, p_id));
}
n.node->connect("changed", this, "_queue_update");
n.node->connect_compat("changed", this, "_queue_update");
Ref<VisualShaderNodeCustom> custom = n.node;
if (custom.is_valid()) {
@@ -375,10 +375,10 @@ void VisualShader::remove_node(Type p_type, int p_id) {
Ref<VisualShaderNodeInput> input = g->nodes[p_id].node;
if (input.is_valid()) {
input->disconnect("input_type_changed", this, "_input_type_changed");
input->disconnect_compat("input_type_changed", this, "_input_type_changed");
}
g->nodes[p_id].node->disconnect("changed", this, "_queue_update");
g->nodes[p_id].node->disconnect_compat("changed", this, "_queue_update");
g->nodes.erase(p_id);