Reworked signal connection system, added support for Callable and Signal objects and made them default.
This commit is contained in:
committed by
Juan Linietsky
parent
1a4be2cd8f
commit
69c95f4b4c
@ -160,13 +160,13 @@ void TextureRect::set_texture(const Ref<Texture2D> &p_tex) {
|
||||
}
|
||||
|
||||
if (texture.is_valid()) {
|
||||
texture->disconnect(CoreStringNames::get_singleton()->changed, this, "_texture_changed");
|
||||
texture->disconnect_compat(CoreStringNames::get_singleton()->changed, this, "_texture_changed");
|
||||
}
|
||||
|
||||
texture = p_tex;
|
||||
|
||||
if (texture.is_valid()) {
|
||||
texture->connect(CoreStringNames::get_singleton()->changed, this, "_texture_changed");
|
||||
texture->connect_compat(CoreStringNames::get_singleton()->changed, this, "_texture_changed");
|
||||
}
|
||||
|
||||
update();
|
||||
|
||||
Reference in New Issue
Block a user