Bug 775624 Part 15 - Remove NS_INLINE_BREAK_TYPE_MASK. r?dholbert
MozReview-Commit-ID: BjDou96ojUd
--- a/layout/generic/nsIFrame.h
+++ b/layout/generic/nsIFrame.h
@@ -360,19 +360,16 @@ private:
#define NS_FRAME_COMPLETE 0 // Note: not a bit!
#define NS_FRAME_NOT_COMPLETE 0x1
#define NS_FRAME_OVERFLOW_INCOMPLETE 0x4
#define NS_INLINE_BREAK 0x0100
#define NS_INLINE_BREAK_AFTER 0x0200
-// The type of break requested can be found in these bits.
-#define NS_INLINE_BREAK_TYPE_MASK 0xF000
-
// Set when a break was induced by completion of a first-letter
#define NS_INLINE_BREAK_FIRST_LETTER_COMPLETE 0x10000
//----------------------------------------
// Macros that use those bits
#define NS_INLINE_IS_BREAK(_status) \
(0 != ((_status) & NS_INLINE_BREAK))
--- a/layout/generic/nsInlineFrame.cpp
+++ b/layout/generic/nsInlineFrame.cpp
@@ -804,19 +804,20 @@ nsInlineFrame::ReflowInlineFrame(nsPresC
bool pushedFrame;
lineLayout->ReflowFrame(aFrame, aStatus, nullptr, pushedFrame);
if (NS_INLINE_IS_BREAK_BEFORE(aStatus)) {
if (aFrame != mFrames.FirstChild()) {
// Change break-before status into break-after since we have
// already placed at least one child frame. This preserves the
// break-type so that it can be propagated upward.
- aStatus = NS_FRAME_NOT_COMPLETE |
- NS_INLINE_BREAK | NS_INLINE_BREAK_AFTER |
- (aStatus & NS_INLINE_BREAK_TYPE_MASK);
+ StyleClear oldBreakType = aStatus.BreakType();
+ aStatus.Reset();
+ aStatus.SetIncomplete();
+ aStatus.SetInlineLineBreakAfter(oldBreakType);
PushFrames(aPresContext, aFrame, irs.mPrevFrame, irs);
}
else {
// Preserve reflow status when breaking-before our first child
// and propagate it upward without modification.
}
return;
}