Fix SortChildren in SetContainer

This commit is contained in:
Eric NGUYEN 2022-10-19 14:08:15 +02:00
parent a6c5be608d
commit 60ff7f412a

View file

@ -289,17 +289,17 @@ function SetContainer(
symbols symbols
); );
// sort the children list by their position
const parent = FindContainerById(containers, container.properties.parentId);
if (parent !== null && parent !== undefined) {
SortChildren(containers, parent);
}
// Apply special behaviors: rigid, flex, symbol, anchor // Apply special behaviors: rigid, flex, symbol, anchor
ApplyBehaviors(containers, container, symbols); ApplyBehaviors(containers, container, symbols);
// Apply special behaviors on siblings // Apply special behaviors on siblings
ApplyBehaviorsOnSiblingsChildren(containers, container, symbols); ApplyBehaviorsOnSiblingsChildren(containers, container, symbols);
// sort the children list by their position
const parent = FindContainerById(containers, container.properties.parentId);
if (parent !== null && parent !== undefined) {
SortChildren(containers, parent);
}
} }
/** /**