diff options
| author | Franklin Sobrinho <franklin_gs@hotmail.com> | 2015-11-28 13:05:39 -0300 |
|---|---|---|
| committer | Franklin Sobrinho <franklin_gs@hotmail.com> | 2015-11-28 13:05:39 -0300 |
| commit | 43e1b879d02c53e2b4ef87fa6a42678dddca29b3 (patch) | |
| tree | 0571e148221e75875ed30bfc4acd0e8c1385b7aa /scene/gui/container.cpp | |
| parent | 274b17b63611ad678fc91ab06f264343914add39 (diff) | |
| download | redot-engine-43e1b879d02c53e2b4ef87fa6a42678dddca29b3.tar.gz | |
Add container automatic update when moving a child node
Diffstat (limited to 'scene/gui/container.cpp')
| -rw-r--r-- | scene/gui/container.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/scene/gui/container.cpp b/scene/gui/container.cpp index 6c74bc3977..8cdf4dd039 100644 --- a/scene/gui/container.cpp +++ b/scene/gui/container.cpp @@ -52,6 +52,14 @@ void Container::add_child_notify(Node *p_child) { } +void Container::move_child_notify(Node *p_child) { + + if (!p_child->cast_to<Control>()) + return; + + queue_sort(); +} + void Container::remove_child_notify(Node *p_child) { |
