From: Jaehyun Cho Date: Thu, 14 Oct 2021 11:14:48 +0000 (+0900) Subject: [NUI] Fix GridLayout to calculate child's size proportional to span X-Git-Tag: submit/tizen/20211019.152222~1^2~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=c74e767b1d58a89b39376fa62b64687203ed8113;p=platform%2Fcore%2Fcsapi%2Ftizenfx.git [NUI] Fix GridLayout to calculate child's size proportional to span Previously, child's size was not proportional to its span. e.g. width of span 1 was the same with width of span 2. Now, child's size is proportional to its span. --- diff --git a/src/Tizen.NUI/src/internal/Layouting/GridLocations.cs b/src/Tizen.NUI/src/internal/Layouting/GridLocations.cs index 8659b2c..5dfdfd4 100755 --- a/src/Tizen.NUI/src/internal/Layouting/GridLocations.cs +++ b/src/Tizen.NUI/src/internal/Layouting/GridLocations.cs @@ -126,7 +126,7 @@ namespace Tizen.NUI Node node = edgeList[i]; // update expanded size. if (node.Stretch.HasFlag(StretchFlags.Expand)) - node.ExpandedSize = curExpandedSize / totalExpand; + node.ExpandedSize = curExpandedSize * (node.End - node.Start) / totalExpand; } // re-init locations based on updated expanded size.