Skip to content

Commit

Permalink
Removed unneeded size calculation which caused some issues with mixed…
Browse files Browse the repository at this point in the history
… height/width children.

Resolves: #380
  • Loading branch information
Simon Jackson committed Dec 24, 2022
1 parent dced045 commit 18ebf81
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions Runtime/Scripts/Layout/FlowLayoutGroup.cs
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,6 @@ public float SetLayout(int axis, bool layoutInput)
childSize = LayoutUtility.GetPreferredSize (child, 0);
childSize = Mathf.Min (childSize, workingSize);
childOtherSize = LayoutUtility.GetPreferredSize (child, 1);
childOtherSize = Mathf.Min (childOtherSize, workingSize);
} else if (startAxis == Axis.Vertical) {
if (invertOrder) {
index = IsRightAlign ? rectChildren.Count - 1 - i : i;
Expand All @@ -175,7 +174,6 @@ public float SetLayout(int axis, bool layoutInput)
childSize = LayoutUtility.GetPreferredSize (child, 1);
childSize = Mathf.Min (childSize, workingSize);
childOtherSize = LayoutUtility.GetPreferredSize (child, 0);
childOtherSize = Mathf.Min (childOtherSize, workingSize);
}

// If adding this element would exceed the bounds of the container,
Expand Down

0 comments on commit 18ebf81

Please sign in to comment.