[NUI] Fix to calculate RelativeLayout's children MeasuredWidth/Height correctly
authorJaehyun Cho <jae_hyun.cho@samsung.com>
Wed, 7 Jul 2021 12:42:03 +0000 (21:42 +0900)
committerdongsug-song <35130733+dongsug-song@users.noreply.github.com>
Fri, 9 Jul 2021 10:39:50 +0000 (19:39 +0900)
commit51456bb9a5fea63fef0123a6083b7cf41a60e1cd
tree1a3c44924772d512221a285fc0430b17d99ca8ee
parent089c7d0a56fd019644ee583ef547bdae0aa60bdd
[NUI] Fix to calculate RelativeLayout's children MeasuredWidth/Height correctly

RelativeLayout sets its children's size in OnLayout().
Therefore, the children's MeasuredWidth/Height are not the same with the
children's size.
This causes that the grand children's MeasuredWidth/Height are calculated
incorrectly.
To resolve the above, RelativeLayout updates its children's MeasuredWidth/Height
based on the children's actual size on RelativeLayout after the RelativeLayout's
MeasuredWidth/Height are calculated.

e.g.
Let parent have RelativeLayout and parent's size be 1920x1080.
Let child have WrapContent with SetFillHorizontal/Vertical true.
Let grand child have MatchParent.
Then, child's size is 1920x1080 but child's MeasuredWidth/Height is 0x0.
Then, grand child's MeasuredWidth/Height is 0x0 and size is 0x0.
src/Tizen.NUI/src/public/Layouting/RelativeLayout.cs