TextureButton Update min size on any texture change

(cherry picked from commit 6c3c269f24)
This commit is contained in:
kleonc 2021-06-11 13:39:51 +02:00 committed by Rémi Verschelde
parent e583888573
commit e8759f218d
No known key found for this signature in database
GPG Key ID: C3336907360768E1
1 changed files with 3 additions and 0 deletions

View File

@ -281,11 +281,13 @@ void TextureButton::set_pressed_texture(const Ref<Texture> &p_pressed) {
pressed = p_pressed;
update();
minimum_size_changed();
}
void TextureButton::set_hover_texture(const Ref<Texture> &p_hover) {
hover = p_hover;
update();
minimum_size_changed();
}
void TextureButton::set_disabled_texture(const Ref<Texture> &p_disabled) {
@ -296,6 +298,7 @@ void TextureButton::set_click_mask(const Ref<BitMap> &p_click_mask) {
click_mask = p_click_mask;
update();
minimum_size_changed();
}
Ref<Texture> TextureButton::get_normal_texture() const {