diff options
author | RĂ©mi Verschelde <remi@verschelde.fr> | 2022-01-19 16:44:06 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-01-19 16:44:06 +0100 |
commit | 8396755cb6742ba9cb203feb43784d516390e0e2 (patch) | |
tree | 48307a34e1f41d707c4220623f4804a5766261b3 /scene/gui | |
parent | cba2fd2e8080dc999c0473ca09ba23d30fe8cf42 (diff) | |
parent | bcbbbeb050885be39f3d95c9c5b9895e581d326c (diff) |
Merge pull request #56954 from pycbouh/control-dont-resize-outside-tree
Diffstat (limited to 'scene/gui')
-rw-r--r-- | scene/gui/control.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/scene/gui/control.cpp b/scene/gui/control.cpp index 11d7946866..f167062f7d 100644 --- a/scene/gui/control.cpp +++ b/scene/gui/control.cpp @@ -733,8 +733,10 @@ void Control::_notification(int p_notification) { } break; case NOTIFICATION_TRANSLATION_CHANGED: case NOTIFICATION_LAYOUT_DIRECTION_CHANGED: { - data.is_rtl_dirty = true; - _size_changed(); + if (is_inside_tree()) { + data.is_rtl_dirty = true; + _size_changed(); + } } break; } } |