Revert D4850458: [yoga][PR] Let measure behave more like on the web
Summary: This reverts commit be5e35a670ddcbf3cd426fc3c2a0c9b60a874cdc Differential Revision: D4850458 fbshipit-source-id: 2ecb6c8627a84b52ade968fd18331a7473369ebe
This commit is contained in:
committed by
Facebook Github Bot
parent
1b3e971549
commit
eb4af86e3c
@@ -1654,6 +1654,13 @@ static void YGNodeWithMeasureFuncSetMeasuredDimensions(const YGNodeRef node,
|
||||
node, YGFlexDirectionRow, availableWidth - marginAxisRow, parentWidth, parentWidth);
|
||||
node->layout.measuredDimensions[YGDimensionHeight] = YGNodeBoundAxis(
|
||||
node, YGFlexDirectionColumn, availableHeight - marginAxisColumn, parentHeight, parentWidth);
|
||||
} else if (innerWidth <= 0.0f || innerHeight <= 0.0f) {
|
||||
// Don't bother sizing the text if there's no horizontal or vertical
|
||||
// space.
|
||||
node->layout.measuredDimensions[YGDimensionWidth] =
|
||||
YGNodeBoundAxis(node, YGFlexDirectionRow, 0.0f, availableWidth, availableWidth);
|
||||
node->layout.measuredDimensions[YGDimensionHeight] =
|
||||
YGNodeBoundAxis(node, YGFlexDirectionColumn, 0.0f, availableHeight, availableWidth);
|
||||
} else {
|
||||
// Measure the text under the current constraints.
|
||||
const YGSize measuredSize =
|
||||
|
Reference in New Issue
Block a user