commit d6d5665c36c6b52c95080dfe28e6747374896841
parent aef558541413a183ef2e67c72263a0e349e51035
Author: Ting-Yu Lin <tlin@mozilla.com>
Date: Thu, 20 Nov 2025 03:44:21 +0000
Bug 2001247 - Move nsSplittableFrame::PreReflowBlockLevelLogicalSkipSides() to public. r=layout-reviewers,emilio
In Bug 1994083, `AbsoluteContainingBlock` needs to call this method on
delegating frame's continuations to adjust borders.
Differential Revision: https://phabricator.services.mozilla.com/D272399
Diffstat:
1 file changed, 14 insertions(+), 14 deletions(-)
diff --git a/layout/generic/nsSplittableFrame.h b/layout/generic/nsSplittableFrame.h
@@ -87,6 +87,20 @@ class nsSplittableFrame : public nsIFrame {
// frame's Destroy() method.
static void RemoveFromFlow(nsIFrame* aFrame);
+ /**
+ * A version of GetLogicalSkipSides() that is intended to be used inside
+ * Reflow before it's known if |this| frame will be COMPLETE or not.
+ * It returns a result that assumes this fragment is the last and thus
+ * should apply the block-end border/padding etc (except for "true" overflow
+ * containers which always skip block sides). You're then expected to
+ * recalculate the block-end side (as needed) when you know |this| frame's
+ * reflow status is INCOMPLETE.
+ * This method is intended for frames that break in the block axis.
+ */
+ LogicalSides PreReflowBlockLevelLogicalSkipSides() const {
+ return GetBlockLevelLogicalSkipSides(false);
+ };
+
protected:
nsSplittableFrame(ComputedStyle* aStyle, nsPresContext* aPresContext,
ClassID aID)
@@ -144,20 +158,6 @@ class nsSplittableFrame : public nsIFrame {
LogicalSides GetBlockLevelLogicalSkipSides(bool aAfterReflow) const;
- /**
- * A version of GetLogicalSkipSides() that is intended to be used inside
- * Reflow before it's known if |this| frame will be COMPLETE or not.
- * It returns a result that assumes this fragment is the last and thus
- * should apply the block-end border/padding etc (except for "true" overflow
- * containers which always skip block sides). You're then expected to
- * recalculate the block-end side (as needed) when you know |this| frame's
- * reflow status is INCOMPLETE.
- * This method is intended for frames that break in the block axis.
- */
- LogicalSides PreReflowBlockLevelLogicalSkipSides() const {
- return GetBlockLevelLogicalSkipSides(false);
- };
-
nsIFrame* mPrevContinuation = nullptr;
nsIFrame* mNextContinuation = nullptr;