diff options
author | Jeremy Andrews <athenian200@outlook.com> | 2022-08-16 02:14:53 -0500 |
---|---|---|
committer | Jeremy Andrews <athenian200@outlook.com> | 2022-08-16 02:14:53 -0500 |
commit | 2a57b39dbc1cc8b2bb32dedd87707680a1025430 (patch) | |
tree | 73588f620f0b15df6f139908c7f14304f5d12949 /layout/generic/ReflowInput.cpp | |
parent | 50bd3acb5b664fab9a78e5cf160ad92cdb577a6e (diff) | |
download | uxp-2a57b39dbc1cc8b2bb32dedd87707680a1025430.tar.gz |
Issue #1986 - Use logical coordinates in flex containers.
This mostly reworks the way nsFlexContainerFrame handles things so that it can
deal with more than just height.
Diffstat (limited to 'layout/generic/ReflowInput.cpp')
-rw-r--r-- | layout/generic/ReflowInput.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/layout/generic/ReflowInput.cpp b/layout/generic/ReflowInput.cpp index 1af7e798ef..994e2cfbb6 100644 --- a/layout/generic/ReflowInput.cpp +++ b/layout/generic/ReflowInput.cpp @@ -225,7 +225,7 @@ ReflowInput::ReflowInput( CheckNextInFlowParenthood(aFrame, aParentReflowInput.mFrame); mFlags.mAssumingHScrollbar = mFlags.mAssumingVScrollbar = false; mFlags.mIsColumnBalancing = false; - mFlags.mIsFlexContainerMeasuringHeight = false; + mFlags.mIsFlexContainerMeasuringBSize = false; mFlags.mDummyParentReflowInput = false; mFlags.mShrinkWrap = !!(aFlags & COMPUTE_SIZE_SHRINK_WRAP); mFlags.mUseAutoBSize = !!(aFlags & COMPUTE_SIZE_USE_AUTO_BSIZE); @@ -2403,15 +2403,15 @@ ReflowInput::InitConstraints(nsPresContext* aPresContext, ComputeSizeFlags(computeSizeFlags | ComputeSizeFlags::eShrinkWrap); // If we're inside of a flex container that needs to measure our - // auto height, pass that information along to ComputeSize(). - if (mFlags.mIsFlexContainerMeasuringHeight) { + // auto BSize, pass that information along to ComputeSize(). + if (mFlags.mIsFlexContainerMeasuringBSize) { computeSizeFlags = ComputeSizeFlags(computeSizeFlags | ComputeSizeFlags::eUseAutoBSize); } } else { - MOZ_ASSERT(!mFlags.mIsFlexContainerMeasuringHeight, + MOZ_ASSERT(!mFlags.mIsFlexContainerMeasuringBSize, "We're not in a flex container, so the flag " - "'mIsFlexContainerMeasuringHeight' shouldn't be set"); + "'mIsFlexContainerMeasuringBSize' shouldn't be set"); } } @@ -2993,7 +2993,7 @@ ReflowInput::ComputeMinMaxValues(const LogicalSize&aCBSize) minBSize.HasPercent()) || (mFrameType == NS_CSS_FRAME_TYPE_INTERNAL_TABLE && minBSize.IsCalcUnit() && minBSize.CalcHasPercent()) || - mFlags.mIsFlexContainerMeasuringHeight) { + mFlags.mIsFlexContainerMeasuringBSize) { ComputedMinBSize() = 0; } else { ComputedMinBSize() = ComputeBSizeValue(aCBSize.BSize(wm), @@ -3015,7 +3015,7 @@ ReflowInput::ComputeMinMaxValues(const LogicalSize&aCBSize) maxBSize.HasPercent()) || (mFrameType == NS_CSS_FRAME_TYPE_INTERNAL_TABLE && maxBSize.IsCalcUnit() && maxBSize.CalcHasPercent()) || - mFlags.mIsFlexContainerMeasuringHeight) { + mFlags.mIsFlexContainerMeasuringBSize) { ComputedMaxBSize() = NS_UNCONSTRAINEDSIZE; } else { ComputedMaxBSize() = ComputeBSizeValue(aCBSize.BSize(wm), |