mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-03-01 05:48:26 +00:00
Bug 1584018 - Make flex and grid code indicate that its block resizes can affect basis for percentages. r=dholbert,mats
Differential Revision: https://phabricator.services.mozilla.com/D50511 --HG-- extra : moz-landing-system : lando
This commit is contained in:
parent
2d2b81ee1d
commit
449f8593f0
@ -1865,6 +1865,8 @@ nscoord nsFlexContainerFrame::MeasureFlexItemContentBSize(
|
||||
|
||||
if (aForceBResizeForMeasuringReflow) {
|
||||
childRIForMeasuringBSize.SetBResize(true);
|
||||
// Not 100% sure this is needed, but be conservative for now:
|
||||
childRIForMeasuringBSize.mFlags.mIsBResizeForPercentages = true;
|
||||
}
|
||||
|
||||
const CachedMeasuringReflowResult& reflowResult =
|
||||
@ -4232,6 +4234,8 @@ void nsFlexContainerFrame::SizeItemInCrossAxis(
|
||||
// (Note: we know that the cross axis is the item's *block* axis -- if it
|
||||
// weren't, then we would've taken the early-return above.)
|
||||
aChildReflowInput.SetBResize(true);
|
||||
// Not 100% sure this is needed, but be conservative for now:
|
||||
aChildReflowInput.mFlags.mIsBResizeForPercentages = true;
|
||||
}
|
||||
|
||||
// Potentially reflow the item, and get the sizing info.
|
||||
@ -5248,6 +5252,7 @@ void nsFlexContainerFrame::ReflowFlexItem(
|
||||
}
|
||||
if (didOverrideComputedBSize) {
|
||||
childReflowInput.SetBResize(true);
|
||||
childReflowInput.mFlags.mIsBResizeForPercentages = true;
|
||||
}
|
||||
}
|
||||
// NOTE: Be very careful about doing anything else with childReflowInput
|
||||
|
@ -4634,6 +4634,8 @@ static nscoord MeasuringReflow(nsIFrame* aChild,
|
||||
// child does some of the things that are affected by
|
||||
// ReflowInput::COMPUTE_SIZE_USE_AUTO_BSIZE.
|
||||
childRI.SetBResize(true);
|
||||
// Not 100% sure this is needed, but be conservative for now:
|
||||
childRI.mFlags.mIsBResizeForPercentages = true;
|
||||
|
||||
ReflowOutput childSize(childRI);
|
||||
nsReflowStatus childStatus;
|
||||
@ -6379,6 +6381,7 @@ void nsGridContainerFrame::ReflowInFlowChild(
|
||||
// does some of the things that are affected by
|
||||
// ReflowInput::COMPUTE_SIZE_USE_AUTO_BSIZE.
|
||||
childRI.SetBResize(true);
|
||||
childRI.mFlags.mIsBResizeForPercentages = true;
|
||||
|
||||
// A table-wrapper needs to propagate the CB size we give it to its
|
||||
// inner table frame later. @see nsTableWrapperFrame::InitChildReflowInput.
|
||||
|
@ -1,2 +0,0 @@
|
||||
[flex-child-percent-basis-resize-1.html]
|
||||
expected: FAIL
|
@ -1,2 +0,0 @@
|
||||
[grid-child-percent-basis-resize-1.html]
|
||||
expected: FAIL
|
Loading…
x
Reference in New Issue
Block a user