Bug 1425078 - Remove nsDisplayList::AppendNewToTop and nsDisplayList::AppendNewToBottom r=mattwoodrow
MozReview-Commit-ID: E3neKT2sV4Q
This commit is contained in:
@@ -5203,7 +5203,7 @@ PresShell::AddPrintPreviewBackgroundItem(nsDisplayListBuilder& aBuilder,
|
|||||||
nsIFrame* aFrame,
|
nsIFrame* aFrame,
|
||||||
const nsRect& aBounds)
|
const nsRect& aBounds)
|
||||||
{
|
{
|
||||||
aList.AppendNewToBottom(new (&aBuilder)
|
aList.AppendToBottom(new (&aBuilder)
|
||||||
nsDisplaySolidColor(&aBuilder, aFrame, aBounds, NS_RGB(115, 115, 115)));
|
nsDisplaySolidColor(&aBuilder, aFrame, aBounds, NS_RGB(115, 115, 115)));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -5287,7 +5287,7 @@ PresShell::AddCanvasBackgroundColorItem(nsDisplayListBuilder& aBuilder,
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (!addedScrollingBackgroundColor || forceUnscrolledItem) {
|
if (!addedScrollingBackgroundColor || forceUnscrolledItem) {
|
||||||
aList.AppendNewToBottom(
|
aList.AppendToBottom(
|
||||||
new (&aBuilder) nsDisplaySolidColor(&aBuilder, aFrame, aBounds, bgcolor));
|
new (&aBuilder) nsDisplaySolidColor(&aBuilder, aFrame, aBounds, bgcolor));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -489,7 +489,7 @@ nsButtonFrameRenderer::DisplayButton(nsDisplayListBuilder* aBuilder,
|
|||||||
nsDisplayList* aForeground)
|
nsDisplayList* aForeground)
|
||||||
{
|
{
|
||||||
if (mFrame->StyleEffects()->mBoxShadow) {
|
if (mFrame->StyleEffects()->mBoxShadow) {
|
||||||
aBackground->AppendNewToTop(new (aBuilder)
|
aBackground->AppendToTop(new (aBuilder)
|
||||||
nsDisplayButtonBoxShadowOuter(aBuilder, this));
|
nsDisplayButtonBoxShadowOuter(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -498,13 +498,13 @@ nsButtonFrameRenderer::DisplayButton(nsDisplayListBuilder* aBuilder,
|
|||||||
nsDisplayBackgroundImage::AppendBackgroundItemsToTop(
|
nsDisplayBackgroundImage::AppendBackgroundItemsToTop(
|
||||||
aBuilder, mFrame, buttonRect, aBackground);
|
aBuilder, mFrame, buttonRect, aBackground);
|
||||||
|
|
||||||
aBackground->AppendNewToTop(new (aBuilder)
|
aBackground->AppendToTop(new (aBuilder)
|
||||||
nsDisplayButtonBorder(aBuilder, this));
|
nsDisplayButtonBorder(aBuilder, this));
|
||||||
|
|
||||||
// Only display focus rings if we actually have them. Since at most one
|
// Only display focus rings if we actually have them. Since at most one
|
||||||
// button would normally display a focus ring, most buttons won't have them.
|
// button would normally display a focus ring, most buttons won't have them.
|
||||||
if (mInnerFocusStyle && mInnerFocusStyle->StyleBorder()->HasBorder()) {
|
if (mInnerFocusStyle && mInnerFocusStyle->StyleBorder()->HasBorder()) {
|
||||||
aForeground->AppendNewToTop(new (aBuilder)
|
aForeground->AppendToTop(new (aBuilder)
|
||||||
nsDisplayButtonForeground(aBuilder, this));
|
nsDisplayButtonForeground(aBuilder, this));
|
||||||
}
|
}
|
||||||
return NS_OK;
|
return NS_OK;
|
||||||
|
|||||||
@@ -1574,7 +1574,7 @@ nsComboboxControlFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
if ((!IsThemed(disp) ||
|
if ((!IsThemed(disp) ||
|
||||||
!presContext->GetTheme()->ThemeDrawsFocusForWidget(disp->mAppearance)) &&
|
!presContext->GetTheme()->ThemeDrawsFocusForWidget(disp->mAppearance)) &&
|
||||||
mDisplayFrame && IsVisibleForPainting(aBuilder)) {
|
mDisplayFrame && IsVisibleForPainting(aBuilder)) {
|
||||||
aLists.Content()->AppendNewToTop(
|
aLists.Content()->AppendToTop(
|
||||||
new (aBuilder) nsDisplayComboboxFocus(aBuilder, this));
|
new (aBuilder) nsDisplayComboboxFocus(aBuilder, this));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -196,7 +196,7 @@ nsFieldSetFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
if (!(GetStateBits() & NS_FRAME_IS_OVERFLOW_CONTAINER) &&
|
if (!(GetStateBits() & NS_FRAME_IS_OVERFLOW_CONTAINER) &&
|
||||||
IsVisibleForPainting(aBuilder)) {
|
IsVisibleForPainting(aBuilder)) {
|
||||||
if (StyleEffects()->mBoxShadow) {
|
if (StyleEffects()->mBoxShadow) {
|
||||||
aLists.BorderBackground()->AppendNewToTop(new (aBuilder)
|
aLists.BorderBackground()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayBoxShadowOuter(aBuilder, this));
|
nsDisplayBoxShadowOuter(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -205,7 +205,7 @@ nsFieldSetFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
aLists.BorderBackground(),
|
aLists.BorderBackground(),
|
||||||
/* aAllowWillPaintBorderOptimization = */ false);
|
/* aAllowWillPaintBorderOptimization = */ false);
|
||||||
|
|
||||||
aLists.BorderBackground()->AppendNewToTop(new (aBuilder)
|
aLists.BorderBackground()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayFieldSetBorder(aBuilder, this));
|
nsDisplayFieldSetBorder(aBuilder, this));
|
||||||
|
|
||||||
DisplayOutlineUnconditional(aBuilder, aLists);
|
DisplayOutlineUnconditional(aBuilder, aLists);
|
||||||
|
|||||||
@@ -178,7 +178,7 @@ nsListControlFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
// XXX Because we have an opaque widget and we get called to paint with
|
// XXX Because we have an opaque widget and we get called to paint with
|
||||||
// this frame as the root of a stacking context we need make sure to draw
|
// this frame as the root of a stacking context we need make sure to draw
|
||||||
// some opaque color over the whole widget. (Bug 511323)
|
// some opaque color over the whole widget. (Bug 511323)
|
||||||
aLists.BorderBackground()->AppendNewToBottom(
|
aLists.BorderBackground()->AppendToBottom(
|
||||||
new (aBuilder) nsDisplaySolidColor(aBuilder,
|
new (aBuilder) nsDisplaySolidColor(aBuilder,
|
||||||
this, nsRect(aBuilder->ToReferenceFrame(this), GetSize()),
|
this, nsRect(aBuilder->ToReferenceFrame(this), GetSize()),
|
||||||
mLastDropdownBackstopColor));
|
mLastDropdownBackstopColor));
|
||||||
|
|||||||
@@ -304,7 +304,7 @@ nsRangeFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
return; // the native theme displays its own visual indication of focus
|
return; // the native theme displays its own visual indication of focus
|
||||||
}
|
}
|
||||||
|
|
||||||
aLists.Content()->AppendNewToTop(
|
aLists.Content()->AppendToTop(
|
||||||
new (aBuilder) nsDisplayRangeFocusRing(aBuilder, this));
|
new (aBuilder) nsDisplayRangeFocusRing(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -154,7 +154,7 @@ nsSelectsAreaFrame::BuildDisplayListInternal(nsDisplayListBuilder* aBuilder,
|
|||||||
// we can't just associate the display item with the list frame,
|
// we can't just associate the display item with the list frame,
|
||||||
// because then the list's scrollframe won't clip it (the scrollframe
|
// because then the list's scrollframe won't clip it (the scrollframe
|
||||||
// only clips contained descendants).
|
// only clips contained descendants).
|
||||||
aLists.Outlines()->AppendNewToTop(new (aBuilder)
|
aLists.Outlines()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayListFocus(aBuilder, this));
|
nsDisplayListFocus(aBuilder, this));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -858,7 +858,7 @@ TextOverflow::CreateMarkers(const nsLineBox* aLine,
|
|||||||
nsDisplayItem* marker = new (mBuilder)
|
nsDisplayItem* marker = new (mBuilder)
|
||||||
nsDisplayTextOverflowMarker(mBuilder, mBlock, markerRect,
|
nsDisplayTextOverflowMarker(mBuilder, mBlock, markerRect,
|
||||||
aLine->GetLogicalAscent(), mIStart.mStyle, aLineNumber, 0);
|
aLine->GetLogicalAscent(), mIStart.mStyle, aLineNumber, 0);
|
||||||
mMarkerList.AppendNewToTop(marker);
|
mMarkerList.AppendToTop(marker);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (aCreateIEnd) {
|
if (aCreateIEnd) {
|
||||||
@@ -875,7 +875,7 @@ TextOverflow::CreateMarkers(const nsLineBox* aLine,
|
|||||||
nsDisplayItem* marker = new (mBuilder)
|
nsDisplayItem* marker = new (mBuilder)
|
||||||
nsDisplayTextOverflowMarker(mBuilder, mBlock, markerRect,
|
nsDisplayTextOverflowMarker(mBuilder, mBlock, markerRect,
|
||||||
aLine->GetLogicalAscent(), mIEnd.mStyle, aLineNumber, 1);
|
aLine->GetLogicalAscent(), mIEnd.mStyle, aLineNumber, 1);
|
||||||
mMarkerList.AppendNewToTop(marker);
|
mMarkerList.AppendToTop(marker);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -75,7 +75,7 @@ ViewportFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
new (aBuilder) nsDisplayWrapList(aBuilder, this, &topLayerList);
|
new (aBuilder) nsDisplayWrapList(aBuilder, this, &topLayerList);
|
||||||
wrapList->SetOverrideZIndex(
|
wrapList->SetOverrideZIndex(
|
||||||
std::numeric_limits<decltype(wrapList->ZIndex())>::max());
|
std::numeric_limits<decltype(wrapList->ZIndex())>::max());
|
||||||
aLists.PositionedDescendants()->AppendNewToTop(wrapList);
|
aLists.PositionedDescendants()->AppendToTop(wrapList);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -786,7 +786,7 @@ nsBulletFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
|
|
||||||
DO_GLOBAL_REFLOW_COUNT_DSP("nsBulletFrame");
|
DO_GLOBAL_REFLOW_COUNT_DSP("nsBulletFrame");
|
||||||
|
|
||||||
aLists.Content()->AppendNewToTop(
|
aLists.Content()->AppendToTop(
|
||||||
new (aBuilder) nsDisplayBullet(aBuilder, this));
|
new (aBuilder) nsDisplayBullet(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -508,11 +508,11 @@ nsCanvasFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
dependentFrame = nullptr;
|
dependentFrame = nullptr;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
aLists.BorderBackground()->AppendNewToTop(
|
aLists.BorderBackground()->AppendToTop(
|
||||||
new (aBuilder) nsDisplayCanvasBackgroundColor(aBuilder, this));
|
new (aBuilder) nsDisplayCanvasBackgroundColor(aBuilder, this));
|
||||||
|
|
||||||
if (isThemed) {
|
if (isThemed) {
|
||||||
aLists.BorderBackground()->AppendNewToTop(
|
aLists.BorderBackground()->AppendToTop(
|
||||||
new (aBuilder) nsDisplayCanvasThemedBackground(aBuilder, this));
|
new (aBuilder) nsDisplayCanvasThemedBackground(aBuilder, this));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -571,18 +571,18 @@ nsCanvasFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
bgItem = new (aBuilder) nsDisplayCanvasBackgroundImage(bgData);
|
bgItem = new (aBuilder) nsDisplayCanvasBackgroundImage(bgData);
|
||||||
bgItem->SetDependentFrame(aBuilder, dependentFrame);
|
bgItem->SetDependentFrame(aBuilder, dependentFrame);
|
||||||
}
|
}
|
||||||
thisItemList.AppendNewToTop(
|
thisItemList.AppendToTop(
|
||||||
nsDisplayFixedPosition::CreateForFixedBackground(aBuilder, this, bgItem, i));
|
nsDisplayFixedPosition::CreateForFixedBackground(aBuilder, this, bgItem, i));
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
nsDisplayCanvasBackgroundImage* bgItem = new (aBuilder) nsDisplayCanvasBackgroundImage(bgData);
|
nsDisplayCanvasBackgroundImage* bgItem = new (aBuilder) nsDisplayCanvasBackgroundImage(bgData);
|
||||||
bgItem->SetDependentFrame(aBuilder, dependentFrame);
|
bgItem->SetDependentFrame(aBuilder, dependentFrame);
|
||||||
thisItemList.AppendNewToTop(bgItem);
|
thisItemList.AppendToTop(bgItem);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (layers.mLayers[i].mBlendMode != NS_STYLE_BLEND_NORMAL) {
|
if (layers.mLayers[i].mBlendMode != NS_STYLE_BLEND_NORMAL) {
|
||||||
DisplayListClipState::AutoSaveRestore blendClip(aBuilder);
|
DisplayListClipState::AutoSaveRestore blendClip(aBuilder);
|
||||||
thisItemList.AppendNewToTop(
|
thisItemList.AppendToTop(
|
||||||
new (aBuilder) nsDisplayBlendMode(aBuilder, this, &thisItemList,
|
new (aBuilder) nsDisplayBlendMode(aBuilder, this, &thisItemList,
|
||||||
layers.mLayers[i].mBlendMode,
|
layers.mLayers[i].mBlendMode,
|
||||||
thisItemASR, i + 1));
|
thisItemASR, i + 1));
|
||||||
@@ -593,7 +593,7 @@ nsCanvasFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
if (needBlendContainer) {
|
if (needBlendContainer) {
|
||||||
const ActiveScrolledRoot* containerASR = contASRTracker.GetContainerASR();
|
const ActiveScrolledRoot* containerASR = contASRTracker.GetContainerASR();
|
||||||
DisplayListClipState::AutoSaveRestore blendContainerClip(aBuilder);
|
DisplayListClipState::AutoSaveRestore blendContainerClip(aBuilder);
|
||||||
aLists.BorderBackground()->AppendNewToTop(
|
aLists.BorderBackground()->AppendToTop(
|
||||||
nsDisplayBlendContainer::CreateForBackgroundBlendMode(aBuilder, this,
|
nsDisplayBlendContainer::CreateForBackgroundBlendMode(aBuilder, this,
|
||||||
aLists.BorderBackground(),
|
aLists.BorderBackground(),
|
||||||
containerASR));
|
containerASR));
|
||||||
@@ -631,7 +631,7 @@ nsCanvasFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
if (!StyleVisibility()->IsVisible())
|
if (!StyleVisibility()->IsVisible())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
aLists.Outlines()->AppendNewToTop(new (aBuilder)
|
aLists.Outlines()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayCanvasFocus(aBuilder, this));
|
nsDisplayCanvasFocus(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1285,7 +1285,7 @@ nsColumnSetFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
|
|
||||||
if (IsVisibleForPainting(aBuilder)) {
|
if (IsVisibleForPainting(aBuilder)) {
|
||||||
aLists.BorderBackground()->
|
aLists.BorderBackground()->
|
||||||
AppendNewToTop(new (aBuilder) nsDisplayColumnRule(aBuilder, this));
|
AppendToTop(new (aBuilder) nsDisplayColumnRule(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
// Our children won't have backgrounds so it doesn't matter where we put them.
|
// Our children won't have backgrounds so it doesn't matter where we put them.
|
||||||
|
|||||||
@@ -2274,7 +2274,7 @@ nsFrame::DisplaySelectionOverlay(nsDisplayListBuilder* aBuilder,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
aList->AppendNewToTop(new (aBuilder)
|
aList->AppendToTop(new (aBuilder)
|
||||||
nsDisplaySelectionOverlay(aBuilder, this, selectionValue));
|
nsDisplaySelectionOverlay(aBuilder, this, selectionValue));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2286,7 +2286,7 @@ nsFrame::DisplayOutlineUnconditional(nsDisplayListBuilder* aBuilder,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
aLists.Outlines()->AppendNewToTop(
|
aLists.Outlines()->AppendToTop(
|
||||||
new (aBuilder) nsDisplayOutline(aBuilder, this));
|
new (aBuilder) nsDisplayOutline(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2307,7 +2307,7 @@ nsIFrame::DisplayCaret(nsDisplayListBuilder* aBuilder,
|
|||||||
if (!IsVisibleForPainting(aBuilder))
|
if (!IsVisibleForPainting(aBuilder))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
aList->AppendNewToTop(new (aBuilder) nsDisplayCaret(aBuilder, this));
|
aList->AppendToTop(new (aBuilder) nsDisplayCaret(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
nscolor
|
nscolor
|
||||||
@@ -2346,7 +2346,7 @@ nsFrame::DisplayBorderBackgroundOutline(nsDisplayListBuilder* aBuilder,
|
|||||||
|
|
||||||
nsCSSShadowArray* shadows = StyleEffects()->mBoxShadow;
|
nsCSSShadowArray* shadows = StyleEffects()->mBoxShadow;
|
||||||
if (shadows && shadows->HasShadowWithInset(false)) {
|
if (shadows && shadows->HasShadowWithInset(false)) {
|
||||||
aLists.BorderBackground()->AppendNewToTop(new (aBuilder)
|
aLists.BorderBackground()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayBoxShadowOuter(aBuilder, this));
|
nsDisplayBoxShadowOuter(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2354,14 +2354,14 @@ nsFrame::DisplayBorderBackgroundOutline(nsDisplayListBuilder* aBuilder,
|
|||||||
aForceBackground);
|
aForceBackground);
|
||||||
|
|
||||||
if (shadows && shadows->HasShadowWithInset(true)) {
|
if (shadows && shadows->HasShadowWithInset(true)) {
|
||||||
aLists.BorderBackground()->AppendNewToTop(new (aBuilder)
|
aLists.BorderBackground()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayBoxShadowInner(aBuilder, this));
|
nsDisplayBoxShadowInner(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
// If there's a themed background, we should not create a border item.
|
// If there's a themed background, we should not create a border item.
|
||||||
// It won't be rendered.
|
// It won't be rendered.
|
||||||
if (!bgIsThemed && StyleBorder()->HasBorder()) {
|
if (!bgIsThemed && StyleBorder()->HasBorder()) {
|
||||||
aLists.BorderBackground()->AppendNewToTop(new (aBuilder)
|
aLists.BorderBackground()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayBorder(aBuilder, this));
|
nsDisplayBorder(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2497,14 +2497,14 @@ DisplayDebugBorders(nsDisplayListBuilder* aBuilder, nsIFrame* aFrame,
|
|||||||
// Draw a border around the child
|
// Draw a border around the child
|
||||||
// REVIEW: From nsContainerFrame::PaintChild
|
// REVIEW: From nsContainerFrame::PaintChild
|
||||||
if (nsFrame::GetShowFrameBorders() && !aFrame->GetRect().IsEmpty()) {
|
if (nsFrame::GetShowFrameBorders() && !aFrame->GetRect().IsEmpty()) {
|
||||||
aLists.Outlines()->AppendNewToTop(new (aBuilder)
|
aLists.Outlines()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayGeneric(aBuilder, aFrame, PaintDebugBorder, "DebugBorder",
|
nsDisplayGeneric(aBuilder, aFrame, PaintDebugBorder, "DebugBorder",
|
||||||
DisplayItemType::TYPE_DEBUG_BORDER));
|
DisplayItemType::TYPE_DEBUG_BORDER));
|
||||||
}
|
}
|
||||||
// Draw a border around the current event target
|
// Draw a border around the current event target
|
||||||
if (nsFrame::GetShowEventTargetFrameBorder() &&
|
if (nsFrame::GetShowEventTargetFrameBorder() &&
|
||||||
aFrame->PresShell()->GetDrawEventTargetFrame() == aFrame) {
|
aFrame->PresShell()->GetDrawEventTargetFrame() == aFrame) {
|
||||||
aLists.Outlines()->AppendNewToTop(new (aBuilder)
|
aLists.Outlines()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayGeneric(aBuilder, aFrame, PaintEventTargetBorder, "EventTargetBorder",
|
nsDisplayGeneric(aBuilder, aFrame, PaintEventTargetBorder, "EventTargetBorder",
|
||||||
DisplayItemType::TYPE_EVENT_TARGET_BORDER));
|
DisplayItemType::TYPE_EVENT_TARGET_BORDER));
|
||||||
}
|
}
|
||||||
@@ -3056,7 +3056,7 @@ nsIFrame::BuildDisplayListForStackingContext(nsDisplayListBuilder* aBuilder,
|
|||||||
if (aBuilder->BuildCompositorHitTestInfo()) {
|
if (aBuilder->BuildCompositorHitTestInfo()) {
|
||||||
CompositorHitTestInfo info = GetCompositorHitTestInfo(aBuilder);
|
CompositorHitTestInfo info = GetCompositorHitTestInfo(aBuilder);
|
||||||
if (info != CompositorHitTestInfo::eInvisibleToHitTest) {
|
if (info != CompositorHitTestInfo::eInvisibleToHitTest) {
|
||||||
set.BorderBackground()->AppendNewToBottom(
|
set.BorderBackground()->AppendToBottom(
|
||||||
new (aBuilder) nsDisplayCompositorHitTestInfo(aBuilder, this, info));
|
new (aBuilder) nsDisplayCompositorHitTestInfo(aBuilder, this, info));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -3076,7 +3076,7 @@ nsIFrame::BuildDisplayListForStackingContext(nsDisplayListBuilder* aBuilder,
|
|||||||
dirtyRect + aBuilder->GetCurrentFrameOffsetToReferenceFrame(),
|
dirtyRect + aBuilder->GetCurrentFrameOffsetToReferenceFrame(),
|
||||||
NS_RGBA(255, 0, 0, 64), false);
|
NS_RGBA(255, 0, 0, 64), false);
|
||||||
color->SetOverrideZIndex(INT32_MAX);
|
color->SetOverrideZIndex(INT32_MAX);
|
||||||
set.PositionedDescendants()->AppendNewToTop(color);
|
set.PositionedDescendants()->AppendToTop(color);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Sort PositionedDescendants() in CSS 'z-order' order. The list is already
|
// Sort PositionedDescendants() in CSS 'z-order' order. The list is already
|
||||||
@@ -3143,7 +3143,7 @@ nsIFrame::BuildDisplayListForStackingContext(nsDisplayListBuilder* aBuilder,
|
|||||||
*/
|
*/
|
||||||
if (aBuilder->ContainsBlendMode()) {
|
if (aBuilder->ContainsBlendMode()) {
|
||||||
DisplayListClipState::AutoSaveRestore blendContainerClipState(aBuilder);
|
DisplayListClipState::AutoSaveRestore blendContainerClipState(aBuilder);
|
||||||
resultList.AppendNewToTop(
|
resultList.AppendToTop(
|
||||||
nsDisplayBlendContainer::CreateForMixBlendMode(aBuilder, this, &resultList,
|
nsDisplayBlendContainer::CreateForMixBlendMode(aBuilder, this, &resultList,
|
||||||
containerItemASR));
|
containerItemASR));
|
||||||
if (aCreatedContainerItem) {
|
if (aCreatedContainerItem) {
|
||||||
@@ -3174,7 +3174,7 @@ nsIFrame::BuildDisplayListForStackingContext(nsDisplayListBuilder* aBuilder,
|
|||||||
bool handleOpacity = !usingMask && !useOpacity;
|
bool handleOpacity = !usingMask && !useOpacity;
|
||||||
|
|
||||||
/* List now emptied, so add the new list to the top. */
|
/* List now emptied, so add the new list to the top. */
|
||||||
resultList.AppendNewToTop(
|
resultList.AppendToTop(
|
||||||
new (aBuilder) nsDisplayFilter(aBuilder, this, &resultList,
|
new (aBuilder) nsDisplayFilter(aBuilder, this, &resultList,
|
||||||
handleOpacity));
|
handleOpacity));
|
||||||
}
|
}
|
||||||
@@ -3194,7 +3194,7 @@ nsIFrame::BuildDisplayListForStackingContext(nsDisplayListBuilder* aBuilder,
|
|||||||
? aBuilder->CurrentActiveScrolledRoot()
|
? aBuilder->CurrentActiveScrolledRoot()
|
||||||
: containerItemASR;
|
: containerItemASR;
|
||||||
/* List now emptied, so add the new list to the top. */
|
/* List now emptied, so add the new list to the top. */
|
||||||
resultList.AppendNewToTop(
|
resultList.AppendToTop(
|
||||||
new (aBuilder) nsDisplayMask(aBuilder, this, &resultList, !useOpacity,
|
new (aBuilder) nsDisplayMask(aBuilder, this, &resultList, !useOpacity,
|
||||||
maskASR));
|
maskASR));
|
||||||
}
|
}
|
||||||
@@ -3216,7 +3216,7 @@ nsIFrame::BuildDisplayListForStackingContext(nsDisplayListBuilder* aBuilder,
|
|||||||
// The clip we would set on an element with opacity would clip
|
// The clip we would set on an element with opacity would clip
|
||||||
// all descendant content, but some should not be clipped.
|
// all descendant content, but some should not be clipped.
|
||||||
DisplayListClipState::AutoSaveRestore opacityClipState(aBuilder);
|
DisplayListClipState::AutoSaveRestore opacityClipState(aBuilder);
|
||||||
resultList.AppendNewToTop(
|
resultList.AppendToTop(
|
||||||
new (aBuilder) nsDisplayOpacity(aBuilder, this, &resultList,
|
new (aBuilder) nsDisplayOpacity(aBuilder, this, &resultList,
|
||||||
containerItemASR,
|
containerItemASR,
|
||||||
opacityItemForEventsAndPluginsOnly));
|
opacityItemForEventsAndPluginsOnly));
|
||||||
@@ -3286,13 +3286,13 @@ nsIFrame::BuildDisplayListForStackingContext(nsDisplayListBuilder* aBuilder,
|
|||||||
new (aBuilder) nsDisplayTransform(aBuilder, this,
|
new (aBuilder) nsDisplayTransform(aBuilder, this,
|
||||||
&resultList, visibleRect, 0,
|
&resultList, visibleRect, 0,
|
||||||
allowAsyncAnimation);
|
allowAsyncAnimation);
|
||||||
resultList.AppendNewToTop(transformItem);
|
resultList.AppendToTop(transformItem);
|
||||||
|
|
||||||
if (hasPerspective) {
|
if (hasPerspective) {
|
||||||
if (clipCapturedBy == ContainerItemType::ePerspective) {
|
if (clipCapturedBy == ContainerItemType::ePerspective) {
|
||||||
clipState.Restore();
|
clipState.Restore();
|
||||||
}
|
}
|
||||||
resultList.AppendNewToTop(
|
resultList.AppendToTop(
|
||||||
new (aBuilder) nsDisplayPerspective(
|
new (aBuilder) nsDisplayPerspective(
|
||||||
aBuilder, this,
|
aBuilder, this,
|
||||||
GetContainingBlock(0, disp)->GetContent()->GetPrimaryFrame(),
|
GetContainingBlock(0, disp)->GetContent()->GetPrimaryFrame(),
|
||||||
@@ -3306,7 +3306,7 @@ nsIFrame::BuildDisplayListForStackingContext(nsDisplayListBuilder* aBuilder,
|
|||||||
|
|
||||||
if (clipCapturedBy == ContainerItemType::eOwnLayerForTransformWithRoundedClip) {
|
if (clipCapturedBy == ContainerItemType::eOwnLayerForTransformWithRoundedClip) {
|
||||||
clipState.Restore();
|
clipState.Restore();
|
||||||
resultList.AppendNewToTop(
|
resultList.AppendToTop(
|
||||||
new (aBuilder) nsDisplayOwnLayer(aBuilder, this, &resultList,
|
new (aBuilder) nsDisplayOwnLayer(aBuilder, this, &resultList,
|
||||||
aBuilder->CurrentActiveScrolledRoot(),
|
aBuilder->CurrentActiveScrolledRoot(),
|
||||||
nsDisplayOwnLayerFlags::eNone,
|
nsDisplayOwnLayerFlags::eNone,
|
||||||
@@ -3329,7 +3329,7 @@ nsIFrame::BuildDisplayListForStackingContext(nsDisplayListBuilder* aBuilder,
|
|||||||
// we need to take the containerItemASR since we might have fixed children.
|
// we need to take the containerItemASR since we might have fixed children.
|
||||||
const ActiveScrolledRoot* fixedASR =
|
const ActiveScrolledRoot* fixedASR =
|
||||||
ActiveScrolledRoot::PickAncestor(containerItemASR, aBuilder->CurrentActiveScrolledRoot());
|
ActiveScrolledRoot::PickAncestor(containerItemASR, aBuilder->CurrentActiveScrolledRoot());
|
||||||
resultList.AppendNewToTop(
|
resultList.AppendToTop(
|
||||||
new (aBuilder) nsDisplayFixedPosition(aBuilder, this, &resultList, fixedASR));
|
new (aBuilder) nsDisplayFixedPosition(aBuilder, this, &resultList, fixedASR));
|
||||||
if (aCreatedContainerItem) {
|
if (aCreatedContainerItem) {
|
||||||
*aCreatedContainerItem = true;
|
*aCreatedContainerItem = true;
|
||||||
@@ -3345,7 +3345,7 @@ nsIFrame::BuildDisplayListForStackingContext(nsDisplayListBuilder* aBuilder,
|
|||||||
// item's ASR is the ASR of the fixed descendant.
|
// item's ASR is the ASR of the fixed descendant.
|
||||||
const ActiveScrolledRoot* stickyASR =
|
const ActiveScrolledRoot* stickyASR =
|
||||||
ActiveScrolledRoot::PickAncestor(containerItemASR, aBuilder->CurrentActiveScrolledRoot());
|
ActiveScrolledRoot::PickAncestor(containerItemASR, aBuilder->CurrentActiveScrolledRoot());
|
||||||
resultList.AppendNewToTop(
|
resultList.AppendToTop(
|
||||||
new (aBuilder) nsDisplayStickyPosition(aBuilder, this, &resultList, stickyASR));
|
new (aBuilder) nsDisplayStickyPosition(aBuilder, this, &resultList, stickyASR));
|
||||||
if (aCreatedContainerItem) {
|
if (aCreatedContainerItem) {
|
||||||
*aCreatedContainerItem = true;
|
*aCreatedContainerItem = true;
|
||||||
@@ -3359,7 +3359,7 @@ nsIFrame::BuildDisplayListForStackingContext(nsDisplayListBuilder* aBuilder,
|
|||||||
|
|
||||||
if (useBlendMode) {
|
if (useBlendMode) {
|
||||||
DisplayListClipState::AutoSaveRestore blendModeClipState(aBuilder);
|
DisplayListClipState::AutoSaveRestore blendModeClipState(aBuilder);
|
||||||
resultList.AppendNewToTop(
|
resultList.AppendToTop(
|
||||||
new (aBuilder) nsDisplayBlendMode(aBuilder, this, &resultList,
|
new (aBuilder) nsDisplayBlendMode(aBuilder, this, &resultList,
|
||||||
effects->mMixBlendMode,
|
effects->mMixBlendMode,
|
||||||
containerItemASR));
|
containerItemASR));
|
||||||
@@ -3494,7 +3494,7 @@ nsIFrame::BuildDisplayListForChild(nsDisplayListBuilder* aBuilder,
|
|||||||
if (aBuilder->BuildCompositorHitTestInfo()) {
|
if (aBuilder->BuildCompositorHitTestInfo()) {
|
||||||
CompositorHitTestInfo info = child->GetCompositorHitTestInfo(aBuilder);
|
CompositorHitTestInfo info = child->GetCompositorHitTestInfo(aBuilder);
|
||||||
if (info != CompositorHitTestInfo::eInvisibleToHitTest) {
|
if (info != CompositorHitTestInfo::eInvisibleToHitTest) {
|
||||||
aLists.BorderBackground()->AppendNewToTop(
|
aLists.BorderBackground()->AppendToTop(
|
||||||
new (aBuilder) nsDisplayCompositorHitTestInfo(aBuilder, child, info));
|
new (aBuilder) nsDisplayCompositorHitTestInfo(aBuilder, child, info));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -3721,9 +3721,9 @@ nsIFrame::BuildDisplayListForChild(nsDisplayListBuilder* aBuilder,
|
|||||||
nsDisplayItem* item =
|
nsDisplayItem* item =
|
||||||
new (aBuilder) nsDisplayCompositorHitTestInfo(aBuilder, child, info);
|
new (aBuilder) nsDisplayCompositorHitTestInfo(aBuilder, child, info);
|
||||||
if (isPositioned) {
|
if (isPositioned) {
|
||||||
list.AppendNewToTop(item);
|
list.AppendToTop(item);
|
||||||
} else {
|
} else {
|
||||||
aLists.BorderBackground()->AppendNewToTop(item);
|
aLists.BorderBackground()->AppendToTop(item);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -3739,9 +3739,9 @@ nsIFrame::BuildDisplayListForChild(nsDisplayListBuilder* aBuilder,
|
|||||||
if (isPositioned) {
|
if (isPositioned) {
|
||||||
// We need this nsDisplayLayerEventRegions to be sorted with the positioned
|
// We need this nsDisplayLayerEventRegions to be sorted with the positioned
|
||||||
// elements as positioned elements will be sorted on top of normal elements
|
// elements as positioned elements will be sorted on top of normal elements
|
||||||
list.AppendNewToTop(eventRegions);
|
list.AppendToTop(eventRegions);
|
||||||
} else {
|
} else {
|
||||||
aLists.BorderBackground()->AppendNewToTop(eventRegions);
|
aLists.BorderBackground()->AppendToTop(eventRegions);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
nsDisplayLayerEventRegions* eventRegions = aBuilder->GetLayerEventRegions();
|
nsDisplayLayerEventRegions* eventRegions = aBuilder->GetLayerEventRegions();
|
||||||
@@ -3804,14 +3804,14 @@ nsIFrame::BuildDisplayListForChild(nsDisplayListBuilder* aBuilder,
|
|||||||
if (!list.IsEmpty()) {
|
if (!list.IsEmpty()) {
|
||||||
nsDisplayItem* item = WrapInWrapList(aBuilder, child, &list, wrapListASR, canSkipWrapList);
|
nsDisplayItem* item = WrapInWrapList(aBuilder, child, &list, wrapListASR, canSkipWrapList);
|
||||||
if (isSVG) {
|
if (isSVG) {
|
||||||
aLists.Content()->AppendNewToTop(item);
|
aLists.Content()->AppendToTop(item);
|
||||||
} else {
|
} else {
|
||||||
aLists.PositionedDescendants()->AppendNewToTop(item);
|
aLists.PositionedDescendants()->AppendToTop(item);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else if (!isSVG && disp->IsFloating(child)) {
|
} else if (!isSVG && disp->IsFloating(child)) {
|
||||||
if (!list.IsEmpty()) {
|
if (!list.IsEmpty()) {
|
||||||
aLists.Floats()->AppendNewToTop(WrapInWrapList(aBuilder, child, &list, wrapListASR));
|
aLists.Floats()->AppendToTop(WrapInWrapList(aBuilder, child, &list, wrapListASR));
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
aLists.Content()->AppendToTop(&list);
|
aLists.Content()->AppendToTop(&list);
|
||||||
@@ -10931,7 +10931,7 @@ nsIFrame::CreateOwnLayerIfNeeded(nsDisplayListBuilder* aBuilder,
|
|||||||
if (GetContent() &&
|
if (GetContent() &&
|
||||||
GetContent()->IsXULElement() &&
|
GetContent()->IsXULElement() &&
|
||||||
GetContent()->HasAttr(kNameSpaceID_None, nsGkAtoms::layer)) {
|
GetContent()->HasAttr(kNameSpaceID_None, nsGkAtoms::layer)) {
|
||||||
aList->AppendNewToTop(new (aBuilder)
|
aList->AppendToTop(new (aBuilder)
|
||||||
nsDisplayOwnLayer(aBuilder, this, aList, aBuilder->CurrentActiveScrolledRoot()));
|
nsDisplayOwnLayer(aBuilder, this, aList, aBuilder->CurrentActiveScrolledRoot()));
|
||||||
if (aCreatedContainerItem) {
|
if (aCreatedContainerItem) {
|
||||||
*aCreatedContainerItem = true;
|
*aCreatedContainerItem = true;
|
||||||
|
|||||||
@@ -679,7 +679,7 @@ nsHTMLFramesetFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
BuildDisplayListForInline(aBuilder, aLists);
|
BuildDisplayListForInline(aBuilder, aLists);
|
||||||
|
|
||||||
if (mDragger && aBuilder->IsForEventDelivery()) {
|
if (mDragger && aBuilder->IsForEventDelivery()) {
|
||||||
aLists.Content()->AppendNewToTop(
|
aLists.Content()->AppendToTop(
|
||||||
new (aBuilder) nsDisplayEventReceiver(aBuilder, this));
|
new (aBuilder) nsDisplayEventReceiver(aBuilder, this));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1422,7 +1422,7 @@ void
|
|||||||
nsHTMLFramesetBorderFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
nsHTMLFramesetBorderFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
||||||
const nsDisplayListSet& aLists)
|
const nsDisplayListSet& aLists)
|
||||||
{
|
{
|
||||||
aLists.Content()->AppendNewToTop(
|
aLists.Content()->AppendToTop(
|
||||||
new (aBuilder) nsDisplayFramesetBorder(aBuilder, this));
|
new (aBuilder) nsDisplayFramesetBorder(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1633,6 +1633,6 @@ void
|
|||||||
nsHTMLFramesetBlankFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
nsHTMLFramesetBlankFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
||||||
const nsDisplayListSet& aLists)
|
const nsDisplayListSet& aLists)
|
||||||
{
|
{
|
||||||
aLists.Content()->AppendNewToTop(
|
aLists.Content()->AppendToTop(
|
||||||
new (aBuilder) nsDisplayFramesetBlank(aBuilder, this));
|
new (aBuilder) nsDisplayFramesetBlank(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3031,9 +3031,9 @@ AppendInternalItemToTop(const nsDisplayListSet& aLists,
|
|||||||
{
|
{
|
||||||
if (aZIndex >= 0) {
|
if (aZIndex >= 0) {
|
||||||
aItem->SetOverrideZIndex(aZIndex);
|
aItem->SetOverrideZIndex(aZIndex);
|
||||||
aLists.PositionedDescendants()->AppendNewToTop(aItem);
|
aLists.PositionedDescendants()->AppendToTop(aItem);
|
||||||
} else {
|
} else {
|
||||||
aLists.Content()->AppendNewToTop(aItem);
|
aLists.Content()->AppendToTop(aItem);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3077,7 +3077,7 @@ AppendToTop(nsDisplayListBuilder* aBuilder, const nsDisplayListSet& aLists,
|
|||||||
int32_t zIndex = MaxZIndexInList(aLists.PositionedDescendants(), aBuilder);
|
int32_t zIndex = MaxZIndexInList(aLists.PositionedDescendants(), aBuilder);
|
||||||
AppendInternalItemToTop(aLists, newItem, zIndex);
|
AppendInternalItemToTop(aLists, newItem, zIndex);
|
||||||
} else {
|
} else {
|
||||||
aLists.BorderBackground()->AppendNewToTop(newItem);
|
aLists.BorderBackground()->AppendToTop(newItem);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3615,7 +3615,7 @@ ScrollFrameHelper::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
dirtyRect + aBuilder->GetCurrentFrameOffsetToReferenceFrame(),
|
dirtyRect + aBuilder->GetCurrentFrameOffsetToReferenceFrame(),
|
||||||
NS_RGBA(0, 0, 255, 64), false);
|
NS_RGBA(0, 0, 255, 64), false);
|
||||||
color->SetOverrideZIndex(INT32_MAX);
|
color->SetOverrideZIndex(INT32_MAX);
|
||||||
scrolledContent.PositionedDescendants()->AppendNewToTop(color);
|
scrolledContent.PositionedDescendants()->AppendToTop(color);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -481,7 +481,7 @@ nsHTMLCanvasFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
DisplayListClipState::AutoClipContainingBlockDescendantsToContentBox
|
DisplayListClipState::AutoClipContainingBlockDescendantsToContentBox
|
||||||
clip(aBuilder, this, clipFlags);
|
clip(aBuilder, this, clipFlags);
|
||||||
|
|
||||||
aLists.Content()->AppendNewToTop(
|
aLists.Content()->AppendToTop(
|
||||||
new (aBuilder) nsDisplayCanvas(aBuilder, this));
|
new (aBuilder) nsDisplayCanvas(aBuilder, this));
|
||||||
|
|
||||||
DisplaySelectionOverlay(aBuilder, aLists.Content(),
|
DisplaySelectionOverlay(aBuilder, aLists.Content(),
|
||||||
|
|||||||
@@ -1844,7 +1844,7 @@ nsImageFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
if (!imageOK || !mImage || !SizeIsAvailable(currentRequest)) {
|
if (!imageOK || !mImage || !SizeIsAvailable(currentRequest)) {
|
||||||
// No image yet, or image load failed. Draw the alt-text and an icon
|
// No image yet, or image load failed. Draw the alt-text and an icon
|
||||||
// indicating the status
|
// indicating the status
|
||||||
aLists.Content()->AppendNewToTop(new (aBuilder)
|
aLists.Content()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayAltFeedback(aBuilder, this));
|
nsDisplayAltFeedback(aBuilder, this));
|
||||||
|
|
||||||
// This image is visible (we are being asked to paint it) but it's not
|
// This image is visible (we are being asked to paint it) but it's not
|
||||||
@@ -1862,7 +1862,7 @@ nsImageFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
aLists.Content()->AppendNewToTop(new (aBuilder)
|
aLists.Content()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayImage(aBuilder, this, mImage, mPrevImage));
|
nsDisplayImage(aBuilder, this, mImage, mPrevImage));
|
||||||
|
|
||||||
// If we were previously displaying an icon, we're not anymore
|
// If we were previously displaying an icon, we're not anymore
|
||||||
@@ -1873,7 +1873,7 @@ nsImageFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
|
|
||||||
#ifdef DEBUG
|
#ifdef DEBUG
|
||||||
if (GetShowFrameBorders() && GetImageMap()) {
|
if (GetShowFrameBorders() && GetImageMap()) {
|
||||||
aLists.Outlines()->AppendNewToTop(new (aBuilder)
|
aLists.Outlines()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayGeneric(aBuilder, this, PaintDebugImageMap, "DebugImageMap",
|
nsDisplayGeneric(aBuilder, this, PaintDebugImageMap, "DebugImageMap",
|
||||||
DisplayItemType::TYPE_DEBUG_IMAGE_MAP));
|
DisplayItemType::TYPE_DEBUG_IMAGE_MAP));
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -586,13 +586,13 @@ nsPageFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
*aBuilder, content, child, backgroundRect, NS_RGBA(0,0,0,0));
|
*aBuilder, content, child, backgroundRect, NS_RGBA(0,0,0,0));
|
||||||
}
|
}
|
||||||
|
|
||||||
content.AppendNewToTop(new (aBuilder) nsDisplayTransform(aBuilder, child,
|
content.AppendToTop(new (aBuilder) nsDisplayTransform(aBuilder, child,
|
||||||
&content, content.GetVisibleRect(), ::ComputePageTransform));
|
&content, content.GetVisibleRect(), ::ComputePageTransform));
|
||||||
|
|
||||||
set.Content()->AppendToTop(&content);
|
set.Content()->AppendToTop(&content);
|
||||||
|
|
||||||
if (PresContext()->IsRootPaginatedDocument()) {
|
if (PresContext()->IsRootPaginatedDocument()) {
|
||||||
set.Content()->AppendNewToTop(new (aBuilder)
|
set.Content()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayHeaderFooter(aBuilder, this));
|
nsDisplayHeaderFooter(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -272,7 +272,7 @@ nsPlaceholderFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
|
|
||||||
#ifdef DEBUG
|
#ifdef DEBUG
|
||||||
if (GetShowFrameBorders()) {
|
if (GetShowFrameBorders()) {
|
||||||
aLists.Outlines()->AppendNewToTop(
|
aLists.Outlines()->AppendToTop(
|
||||||
new (aBuilder) nsDisplayGeneric(aBuilder, this, PaintDebugPlaceholder,
|
new (aBuilder) nsDisplayGeneric(aBuilder, this, PaintDebugPlaceholder,
|
||||||
"DebugPlaceholder",
|
"DebugPlaceholder",
|
||||||
DisplayItemType::TYPE_DEBUG_PLACEHOLDER));
|
DisplayItemType::TYPE_DEBUG_PLACEHOLDER));
|
||||||
|
|||||||
@@ -1192,7 +1192,7 @@ nsPluginFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
|
|
||||||
// determine if we are printing
|
// determine if we are printing
|
||||||
if (type == nsPresContext::eContext_Print) {
|
if (type == nsPresContext::eContext_Print) {
|
||||||
aLists.Content()->AppendNewToTop(new (aBuilder)
|
aLists.Content()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayGeneric(aBuilder, this, PaintPrintPlugin, "PrintPlugin",
|
nsDisplayGeneric(aBuilder, this, PaintPrintPlugin, "PrintPlugin",
|
||||||
DisplayItemType::TYPE_PRINT_PLUGIN));
|
DisplayItemType::TYPE_PRINT_PLUGIN));
|
||||||
} else {
|
} else {
|
||||||
@@ -1204,11 +1204,11 @@ nsPluginFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
if (aBuilder->IsPaintingToWindow() &&
|
if (aBuilder->IsPaintingToWindow() &&
|
||||||
state == LAYER_ACTIVE &&
|
state == LAYER_ACTIVE &&
|
||||||
IsTransparentMode()) {
|
IsTransparentMode()) {
|
||||||
aLists.Content()->AppendNewToTop(new (aBuilder)
|
aLists.Content()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayPluginReadback(aBuilder, this));
|
nsDisplayPluginReadback(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
aLists.Content()->AppendNewToTop(new (aBuilder)
|
aLists.Content()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayPlugin(aBuilder, this));
|
nsDisplayPlugin(aBuilder, this));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -747,7 +747,7 @@ nsSimplePageSequenceFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
content.AppendNewToTop(new (aBuilder)
|
content.AppendToTop(new (aBuilder)
|
||||||
nsDisplayTransform(aBuilder, this, &content, content.GetVisibleRect(),
|
nsDisplayTransform(aBuilder, this, &content, content.GetVisibleRect(),
|
||||||
::ComputePageSequenceTransform));
|
::ComputePageSequenceTransform));
|
||||||
|
|
||||||
|
|||||||
@@ -5233,7 +5233,7 @@ nsTextFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
aLists.Content()->AppendNewToTop(
|
aLists.Content()->AppendToTop(
|
||||||
new (aBuilder) nsDisplayText(aBuilder, this, isSelected));
|
new (aBuilder) nsDisplayText(aBuilder, this, isSelected));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -569,7 +569,7 @@ nsVideoFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
clip(aBuilder, this, clipFlags);
|
clip(aBuilder, this, clipFlags);
|
||||||
|
|
||||||
if (HasVideoElement() && !shouldDisplayPoster) {
|
if (HasVideoElement() && !shouldDisplayPoster) {
|
||||||
aLists.Content()->AppendNewToTop(
|
aLists.Content()->AppendToTop(
|
||||||
new (aBuilder) nsDisplayVideo(aBuilder, this));
|
new (aBuilder) nsDisplayVideo(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1988,7 +1988,7 @@ nsMathMLChar::Display(nsDisplayListBuilder* aBuilder,
|
|||||||
// purposes. Normally, users will set the background on the container frame.
|
// purposes. Normally, users will set the background on the container frame.
|
||||||
// paint the selection background -- beware MathML frames overlap a lot
|
// paint the selection background -- beware MathML frames overlap a lot
|
||||||
if (aSelectedRect && !aSelectedRect->IsEmpty()) {
|
if (aSelectedRect && !aSelectedRect->IsEmpty()) {
|
||||||
aLists.BorderBackground()->AppendNewToTop(new (aBuilder)
|
aLists.BorderBackground()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayMathMLSelectionRect(aBuilder, aForFrame, *aSelectedRect));
|
nsDisplayMathMLSelectionRect(aBuilder, aForFrame, *aSelectedRect));
|
||||||
}
|
}
|
||||||
else if (mRect.width && mRect.height) {
|
else if (mRect.width && mRect.height) {
|
||||||
@@ -2008,7 +2008,7 @@ nsMathMLChar::Display(nsDisplayListBuilder* aBuilder,
|
|||||||
nsDisplayMathMLCharDebug(aBuilder, aForFrame, mRect));
|
nsDisplayMathMLCharDebug(aBuilder, aForFrame, mRect));
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
aLists.Content()->AppendNewToTop(new (aBuilder)
|
aLists.Content()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayMathMLCharForeground(aBuilder, aForFrame, this,
|
nsDisplayMathMLCharForeground(aBuilder, aForFrame, this,
|
||||||
aIndex,
|
aIndex,
|
||||||
aSelectedRect &&
|
aSelectedRect &&
|
||||||
|
|||||||
@@ -624,7 +624,7 @@ nsMathMLContainerFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
if (!IsVisibleForPainting(aBuilder))
|
if (!IsVisibleForPainting(aBuilder))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
aLists.Content()->AppendNewToTop(
|
aLists.Content()->AppendToTop(
|
||||||
new (aBuilder) nsDisplayMathMLError(aBuilder, this));
|
new (aBuilder) nsDisplayMathMLError(aBuilder, this));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -318,7 +318,7 @@ nsMathMLFrame::DisplayBoundingMetrics(nsDisplayListBuilder* aBuilder,
|
|||||||
nscoord w = aMetrics.rightBearing - aMetrics.leftBearing;
|
nscoord w = aMetrics.rightBearing - aMetrics.leftBearing;
|
||||||
nscoord h = aMetrics.ascent + aMetrics.descent;
|
nscoord h = aMetrics.ascent + aMetrics.descent;
|
||||||
|
|
||||||
aLists.Content()->AppendNewToTop(new (aBuilder)
|
aLists.Content()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayMathMLBoundingMetrics(aBuilder, aFrame, nsRect(x,y,w,h)));
|
nsDisplayMathMLBoundingMetrics(aBuilder, aFrame, nsRect(x,y,w,h)));
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
@@ -370,7 +370,7 @@ nsMathMLFrame::DisplayBar(nsDisplayListBuilder* aBuilder,
|
|||||||
if (!aFrame->StyleVisibility()->IsVisible() || aRect.IsEmpty())
|
if (!aFrame->StyleVisibility()->IsVisible() || aRect.IsEmpty())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
aLists.Content()->AppendNewToTop(new (aBuilder)
|
aLists.Content()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayMathMLBar(aBuilder, aFrame, aRect, aIndex));
|
nsDisplayMathMLBar(aBuilder, aFrame, aRect, aIndex));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -873,6 +873,6 @@ nsMathMLmencloseFrame::DisplayNotation(nsDisplayListBuilder* aBuilder,
|
|||||||
aThickness <= 0)
|
aThickness <= 0)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
aLists.Content()->AppendNewToTop(new (aBuilder)
|
aLists.Content()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayNotation(aBuilder, aFrame, aRect, aThickness, aType));
|
nsDisplayNotation(aBuilder, aFrame, aRect, aThickness, aType));
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -656,7 +656,7 @@ nsMathMLmfracFrame::DisplaySlash(nsDisplayListBuilder* aBuilder,
|
|||||||
if (!aFrame->StyleVisibility()->IsVisible() || aRect.IsEmpty())
|
if (!aFrame->StyleVisibility()->IsVisible() || aRect.IsEmpty())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
aLists.Content()->AppendNewToTop(new (aBuilder)
|
aLists.Content()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayMathMLSlash(aBuilder, aFrame, aRect, aThickness,
|
nsDisplayMathMLSlash(aBuilder, aFrame, aRect, aThickness,
|
||||||
StyleVisibility()->mDirection));
|
StyleVisibility()->mDirection));
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1232,7 +1232,7 @@ nsMathMLmtdFrame::ProcessBorders(nsTableFrame* aFrame,
|
|||||||
nsDisplayListBuilder* aBuilder,
|
nsDisplayListBuilder* aBuilder,
|
||||||
const nsDisplayListSet& aLists)
|
const nsDisplayListSet& aLists)
|
||||||
{
|
{
|
||||||
aLists.BorderBackground()->AppendNewToTop(new (aBuilder)
|
aLists.BorderBackground()->AppendToTop(new (aBuilder)
|
||||||
nsDisplaymtdBorder(aBuilder, this));
|
nsDisplaymtdBorder(aBuilder, this));
|
||||||
return NS_OK;
|
return NS_OK;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2200,7 +2200,7 @@ nsDisplayListBuilder::AppendNewScrollInfoItemForHoisting(nsDisplayScrollInfoLaye
|
|||||||
{
|
{
|
||||||
MOZ_ASSERT(ShouldBuildScrollInfoItemsForHoisting());
|
MOZ_ASSERT(ShouldBuildScrollInfoItemsForHoisting());
|
||||||
MOZ_ASSERT(mScrollInfoItemsForHoisting);
|
MOZ_ASSERT(mScrollInfoItemsForHoisting);
|
||||||
mScrollInfoItemsForHoisting->AppendNewToTop(aScrollInfoItem);
|
mScrollInfoItemsForHoisting->AppendToTop(aScrollInfoItem);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool
|
bool
|
||||||
@@ -3526,7 +3526,7 @@ SpecialCutoutRegionCase(nsDisplayListBuilder* aBuilder,
|
|||||||
nsRegion region;
|
nsRegion region;
|
||||||
region.Sub(aBackgroundRect, *static_cast<nsRegion*>(cutoutRegion));
|
region.Sub(aBackgroundRect, *static_cast<nsRegion*>(cutoutRegion));
|
||||||
region.MoveBy(aBuilder->ToReferenceFrame(aFrame));
|
region.MoveBy(aBuilder->ToReferenceFrame(aFrame));
|
||||||
aList->AppendNewToTop(
|
aList->AppendToTop(
|
||||||
new (aBuilder) nsDisplaySolidColorRegion(aBuilder, aFrame, region, aColor));
|
new (aBuilder) nsDisplaySolidColorRegion(aBuilder, aFrame, region, aColor));
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
@@ -3641,14 +3641,14 @@ nsDisplayBackgroundImage::AppendBackgroundItemsToTop(nsDisplayListBuilder* aBuil
|
|||||||
drawBackgroundColor ? color : NS_RGBA(0, 0, 0, 0));
|
drawBackgroundColor ? color : NS_RGBA(0, 0, 0, 0));
|
||||||
}
|
}
|
||||||
bgItem->SetDependentFrame(aBuilder, dependentFrame);
|
bgItem->SetDependentFrame(aBuilder, dependentFrame);
|
||||||
bgItemList.AppendNewToTop(bgItem);
|
bgItemList.AppendToTop(bgItem);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (isThemed) {
|
if (isThemed) {
|
||||||
nsITheme* theme = presContext->GetTheme();
|
nsITheme* theme = presContext->GetTheme();
|
||||||
if (theme->NeedToClearBackgroundBehindWidget(aFrame, aFrame->StyleDisplay()->mAppearance) &&
|
if (theme->NeedToClearBackgroundBehindWidget(aFrame, aFrame->StyleDisplay()->mAppearance) &&
|
||||||
aBuilder->IsInChromeDocumentOrPopup() && !aBuilder->IsInTransform()) {
|
aBuilder->IsInChromeDocumentOrPopup() && !aBuilder->IsInTransform()) {
|
||||||
bgItemList.AppendNewToTop(
|
bgItemList.AppendToTop(
|
||||||
new (aBuilder) nsDisplayClearBackground(aBuilder, aFrame));
|
new (aBuilder) nsDisplayClearBackground(aBuilder, aFrame));
|
||||||
}
|
}
|
||||||
if (aSecondaryReferenceFrame) {
|
if (aSecondaryReferenceFrame) {
|
||||||
@@ -3658,12 +3658,12 @@ nsDisplayBackgroundImage::AppendBackgroundItemsToTop(nsDisplayListBuilder* aBuil
|
|||||||
bgRect,
|
bgRect,
|
||||||
aFrame);
|
aFrame);
|
||||||
bgItem->Init(aBuilder);
|
bgItem->Init(aBuilder);
|
||||||
bgItemList.AppendNewToTop(bgItem);
|
bgItemList.AppendToTop(bgItem);
|
||||||
} else {
|
} else {
|
||||||
nsDisplayThemedBackground* bgItem =
|
nsDisplayThemedBackground* bgItem =
|
||||||
new (aBuilder) nsDisplayThemedBackground(aBuilder, aFrame, bgRect);
|
new (aBuilder) nsDisplayThemedBackground(aBuilder, aFrame, bgRect);
|
||||||
bgItem->Init(aBuilder);
|
bgItem->Init(aBuilder);
|
||||||
bgItemList.AppendNewToTop(bgItem);
|
bgItemList.AppendToTop(bgItem);
|
||||||
}
|
}
|
||||||
aList->AppendToTop(&bgItemList);
|
aList->AppendToTop(&bgItemList);
|
||||||
return true;
|
return true;
|
||||||
@@ -3743,14 +3743,14 @@ nsDisplayBackgroundImage::AppendBackgroundItemsToTop(nsDisplayListBuilder* aBuil
|
|||||||
}
|
}
|
||||||
bgItem->SetDependentFrame(aBuilder, dependentFrame);
|
bgItem->SetDependentFrame(aBuilder, dependentFrame);
|
||||||
if (aSecondaryReferenceFrame) {
|
if (aSecondaryReferenceFrame) {
|
||||||
thisItemList.AppendNewToTop(
|
thisItemList.AppendToTop(
|
||||||
nsDisplayTableFixedPosition::CreateForFixedBackground(aBuilder,
|
nsDisplayTableFixedPosition::CreateForFixedBackground(aBuilder,
|
||||||
aSecondaryReferenceFrame,
|
aSecondaryReferenceFrame,
|
||||||
bgItem,
|
bgItem,
|
||||||
i,
|
i,
|
||||||
aFrame));
|
aFrame));
|
||||||
} else {
|
} else {
|
||||||
thisItemList.AppendNewToTop(
|
thisItemList.AppendToTop(
|
||||||
nsDisplayFixedPosition::CreateForFixedBackground(aBuilder, aFrame, bgItem, i));
|
nsDisplayFixedPosition::CreateForFixedBackground(aBuilder, aFrame, bgItem, i));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3766,7 +3766,7 @@ nsDisplayBackgroundImage::AppendBackgroundItemsToTop(nsDisplayListBuilder* aBuil
|
|||||||
bgItem = new (aBuilder) nsDisplayBackgroundImage(bgData);
|
bgItem = new (aBuilder) nsDisplayBackgroundImage(bgData);
|
||||||
}
|
}
|
||||||
bgItem->SetDependentFrame(aBuilder, dependentFrame);
|
bgItem->SetDependentFrame(aBuilder, dependentFrame);
|
||||||
thisItemList.AppendNewToTop(bgItem);
|
thisItemList.AppendToTop(bgItem);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (bg->mImage.mLayers[i].mBlendMode != NS_STYLE_BLEND_NORMAL) {
|
if (bg->mImage.mLayers[i].mBlendMode != NS_STYLE_BLEND_NORMAL) {
|
||||||
@@ -3775,12 +3775,12 @@ nsDisplayBackgroundImage::AppendBackgroundItemsToTop(nsDisplayListBuilder* aBuil
|
|||||||
// fine, because the item will have a scrolled clip that limits the
|
// fine, because the item will have a scrolled clip that limits the
|
||||||
// item with respect to asr.
|
// item with respect to asr.
|
||||||
if (aSecondaryReferenceFrame) {
|
if (aSecondaryReferenceFrame) {
|
||||||
thisItemList.AppendNewToTop(
|
thisItemList.AppendToTop(
|
||||||
new (aBuilder) nsDisplayTableBlendMode(aBuilder, aSecondaryReferenceFrame, &thisItemList,
|
new (aBuilder) nsDisplayTableBlendMode(aBuilder, aSecondaryReferenceFrame, &thisItemList,
|
||||||
bg->mImage.mLayers[i].mBlendMode,
|
bg->mImage.mLayers[i].mBlendMode,
|
||||||
asr, i + 1, aFrame));
|
asr, i + 1, aFrame));
|
||||||
} else {
|
} else {
|
||||||
thisItemList.AppendNewToTop(
|
thisItemList.AppendToTop(
|
||||||
new (aBuilder) nsDisplayBlendMode(aBuilder, aFrame, &thisItemList,
|
new (aBuilder) nsDisplayBlendMode(aBuilder, aFrame, &thisItemList,
|
||||||
bg->mImage.mLayers[i].mBlendMode,
|
bg->mImage.mLayers[i].mBlendMode,
|
||||||
asr, i + 1));
|
asr, i + 1));
|
||||||
@@ -3792,11 +3792,11 @@ nsDisplayBackgroundImage::AppendBackgroundItemsToTop(nsDisplayListBuilder* aBuil
|
|||||||
if (needBlendContainer) {
|
if (needBlendContainer) {
|
||||||
DisplayListClipState::AutoSaveRestore blendContainerClip(aBuilder);
|
DisplayListClipState::AutoSaveRestore blendContainerClip(aBuilder);
|
||||||
if (aSecondaryReferenceFrame) {
|
if (aSecondaryReferenceFrame) {
|
||||||
bgItemList.AppendNewToTop(
|
bgItemList.AppendToTop(
|
||||||
nsDisplayTableBlendContainer::CreateForBackgroundBlendMode(aBuilder, aSecondaryReferenceFrame,
|
nsDisplayTableBlendContainer::CreateForBackgroundBlendMode(aBuilder, aSecondaryReferenceFrame,
|
||||||
&bgItemList, asr, aFrame));
|
&bgItemList, asr, aFrame));
|
||||||
} else {
|
} else {
|
||||||
bgItemList.AppendNewToTop(
|
bgItemList.AppendToTop(
|
||||||
nsDisplayBlendContainer::CreateForBackgroundBlendMode(aBuilder, aFrame, &bgItemList, asr));
|
nsDisplayBlendContainer::CreateForBackgroundBlendMode(aBuilder, aFrame, &bgItemList, asr));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2735,40 +2735,20 @@ public:
|
|||||||
* be in a list and cannot be null.
|
* be in a list and cannot be null.
|
||||||
*/
|
*/
|
||||||
void AppendToTop(nsDisplayItem* aItem) {
|
void AppendToTop(nsDisplayItem* aItem) {
|
||||||
NS_ASSERTION(aItem, "No item to append!");
|
MOZ_ASSERT(aItem, "No item to append!");
|
||||||
NS_ASSERTION(!aItem->mAbove, "Already in a list!");
|
MOZ_ASSERT(!aItem->mAbove, "Already in a list!");
|
||||||
mTop->mAbove = aItem;
|
mTop->mAbove = aItem;
|
||||||
mTop = aItem;
|
mTop = aItem;
|
||||||
mLength++;
|
mLength++;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Append a new item to the top of the list. The intended usage is
|
|
||||||
* AppendNewToTop(new ...);
|
|
||||||
*/
|
|
||||||
void AppendNewToTop(nsDisplayItem* aItem) {
|
|
||||||
if (aItem) {
|
|
||||||
AppendToTop(aItem);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Append a new item to the bottom of the list. The intended usage is
|
|
||||||
* AppendNewToBottom(new ...);
|
|
||||||
*/
|
|
||||||
void AppendNewToBottom(nsDisplayItem* aItem) {
|
|
||||||
if (aItem) {
|
|
||||||
AppendToBottom(aItem);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Append a new item to the bottom of the list. The item must be non-null
|
* Append a new item to the bottom of the list. The item must be non-null
|
||||||
* and not already in a list.
|
* and not already in a list.
|
||||||
*/
|
*/
|
||||||
void AppendToBottom(nsDisplayItem* aItem) {
|
void AppendToBottom(nsDisplayItem* aItem) {
|
||||||
NS_ASSERTION(aItem, "No item to append!");
|
MOZ_ASSERT(aItem, "No item to append!");
|
||||||
NS_ASSERTION(!aItem->mAbove, "Already in a list!");
|
MOZ_ASSERT(!aItem->mAbove, "Already in a list!");
|
||||||
aItem->mAbove = mSentinel.mAbove;
|
aItem->mAbove = mSentinel.mAbove;
|
||||||
mSentinel.mAbove = aItem;
|
mSentinel.mAbove = aItem;
|
||||||
if (mTop == &mSentinel) {
|
if (mTop == &mSentinel) {
|
||||||
@@ -3309,7 +3289,7 @@ protected:
|
|||||||
PR_BEGIN_MACRO \
|
PR_BEGIN_MACRO \
|
||||||
if (!aBuilder->IsBackgroundOnly() && !aBuilder->IsForEventDelivery() && \
|
if (!aBuilder->IsBackgroundOnly() && !aBuilder->IsForEventDelivery() && \
|
||||||
PresShell()->IsPaintingFrameCounts()) { \
|
PresShell()->IsPaintingFrameCounts()) { \
|
||||||
aLists.Outlines()->AppendNewToTop( \
|
aLists.Outlines()->AppendToTop( \
|
||||||
new (aBuilder) nsDisplayReflowCount(aBuilder, this, _name)); \
|
new (aBuilder) nsDisplayReflowCount(aBuilder, this, _name)); \
|
||||||
} \
|
} \
|
||||||
PR_END_MACRO
|
PR_END_MACRO
|
||||||
@@ -3318,7 +3298,7 @@ protected:
|
|||||||
PR_BEGIN_MACRO \
|
PR_BEGIN_MACRO \
|
||||||
if (!aBuilder->IsBackgroundOnly() && !aBuilder->IsForEventDelivery() && \
|
if (!aBuilder->IsBackgroundOnly() && !aBuilder->IsForEventDelivery() && \
|
||||||
PresShell()->IsPaintingFrameCounts()) { \
|
PresShell()->IsPaintingFrameCounts()) { \
|
||||||
aLists.Outlines()->AppendNewToTop( \
|
aLists.Outlines()->AppendToTop( \
|
||||||
new (aBuilder) nsDisplayReflowCount(aBuilder, this, _name, _color)); \
|
new (aBuilder) nsDisplayReflowCount(aBuilder, this, _name, _color)); \
|
||||||
} \
|
} \
|
||||||
PR_END_MACRO
|
PR_END_MACRO
|
||||||
|
|||||||
@@ -259,7 +259,7 @@ SVGGeometryFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
DisplayOutline(aBuilder, aLists);
|
DisplayOutline(aBuilder, aLists);
|
||||||
aLists.Content()->AppendNewToTop(
|
aLists.Content()->AppendToTop(
|
||||||
new (aBuilder) nsDisplaySVGGeometry(aBuilder, this));
|
new (aBuilder) nsDisplaySVGGeometry(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -3202,7 +3202,7 @@ SVGTextFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
DisplayOutline(aBuilder, aLists);
|
DisplayOutline(aBuilder, aLists);
|
||||||
aLists.Content()->AppendNewToTop(
|
aLists.Content()->AppendToTop(
|
||||||
new (aBuilder) nsDisplaySVGText(aBuilder, this));
|
new (aBuilder) nsDisplaySVGText(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -787,9 +787,9 @@ nsSVGOuterSVGFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
nsDisplayListSet set(&newList, &newList, &newList,
|
nsDisplayListSet set(&newList, &newList, &newList,
|
||||||
&newList, &newList, &newList);
|
&newList, &newList, &newList);
|
||||||
BuildDisplayListForNonBlockChildren(aBuilder, set);
|
BuildDisplayListForNonBlockChildren(aBuilder, set);
|
||||||
aLists.Content()->AppendNewToTop(new (aBuilder) nsDisplaySVGWrapper(aBuilder, this, &newList));
|
aLists.Content()->AppendToTop(new (aBuilder) nsDisplaySVGWrapper(aBuilder, this, &newList));
|
||||||
} else if (IsVisibleForPainting(aBuilder) || !aBuilder->IsForPainting()) {
|
} else if (IsVisibleForPainting(aBuilder) || !aBuilder->IsForPainting()) {
|
||||||
aLists.Content()->AppendNewToTop(
|
aLists.Content()->AppendToTop(
|
||||||
new (aBuilder) nsDisplayOuterSVG(aBuilder, this));
|
new (aBuilder) nsDisplayOuterSVG(aBuilder, this));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -391,7 +391,7 @@ nsTableCellFrame::ProcessBorders(nsTableFrame* aFrame,
|
|||||||
|
|
||||||
if (!GetContentEmpty() ||
|
if (!GetContentEmpty() ||
|
||||||
StyleTableBorder()->mEmptyCells == NS_STYLE_TABLE_EMPTY_CELLS_SHOW) {
|
StyleTableBorder()->mEmptyCells == NS_STYLE_TABLE_EMPTY_CELLS_SHOW) {
|
||||||
aLists.BorderBackground()->AppendNewToTop(new (aBuilder)
|
aLists.BorderBackground()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayBorder(aBuilder, this));
|
nsDisplayBorder(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -495,7 +495,7 @@ nsTableCellFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
// display outset box-shadows if we need to.
|
// display outset box-shadows if we need to.
|
||||||
bool hasBoxShadow = !!StyleEffects()->mBoxShadow;
|
bool hasBoxShadow = !!StyleEffects()->mBoxShadow;
|
||||||
if (hasBoxShadow) {
|
if (hasBoxShadow) {
|
||||||
aLists.BorderBackground()->AppendNewToTop(
|
aLists.BorderBackground()->AppendToTop(
|
||||||
new (aBuilder) nsDisplayBoxShadowOuter(aBuilder, this));
|
new (aBuilder) nsDisplayBoxShadowOuter(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -511,7 +511,7 @@ nsTableCellFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
|
|
||||||
// display inset box-shadows if we need to.
|
// display inset box-shadows if we need to.
|
||||||
if (hasBoxShadow) {
|
if (hasBoxShadow) {
|
||||||
aLists.BorderBackground()->AppendNewToTop(
|
aLists.BorderBackground()->AppendToTop(
|
||||||
new (aBuilder) nsDisplayBoxShadowInner(aBuilder, this));
|
new (aBuilder) nsDisplayBoxShadowInner(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -520,7 +520,7 @@ nsTableCellFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
|
|
||||||
// and display the selection border if we need to
|
// and display the selection border if we need to
|
||||||
if (IsSelected()) {
|
if (IsSelected()) {
|
||||||
aLists.BorderBackground()->AppendNewToTop(new (aBuilder)
|
aLists.BorderBackground()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayTableCellSelection(aBuilder, this));
|
nsDisplayTableCellSelection(aBuilder, this));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1533,7 +1533,7 @@ nsTableFrame::DisplayGenericTablePart(nsDisplayListBuilder* aBuilder,
|
|||||||
|
|
||||||
// Paint the outset box-shadows for the table frames
|
// Paint the outset box-shadows for the table frames
|
||||||
if (aFrame->StyleEffects()->mBoxShadow) {
|
if (aFrame->StyleEffects()->mBoxShadow) {
|
||||||
aLists.BorderBackground()->AppendNewToTop(
|
aLists.BorderBackground()->AppendToTop(
|
||||||
new (aBuilder) nsDisplayBoxShadowOuter(aBuilder, aFrame));
|
new (aBuilder) nsDisplayBoxShadowOuter(aBuilder, aFrame));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1601,7 +1601,7 @@ nsTableFrame::DisplayGenericTablePart(nsDisplayListBuilder* aBuilder,
|
|||||||
|
|
||||||
// Paint the inset box-shadows for the table frames
|
// Paint the inset box-shadows for the table frames
|
||||||
if (aFrame->StyleEffects()->mBoxShadow) {
|
if (aFrame->StyleEffects()->mBoxShadow) {
|
||||||
aLists.BorderBackground()->AppendNewToTop(
|
aLists.BorderBackground()->AppendToTop(
|
||||||
new (aBuilder) nsDisplayBoxShadowInner(aBuilder, aFrame));
|
new (aBuilder) nsDisplayBoxShadowInner(aBuilder, aFrame));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1616,13 +1616,13 @@ nsTableFrame::DisplayGenericTablePart(nsDisplayListBuilder* aBuilder,
|
|||||||
// In the collapsed border model, overlay all collapsed borders.
|
// In the collapsed border model, overlay all collapsed borders.
|
||||||
if (table->IsBorderCollapse()) {
|
if (table->IsBorderCollapse()) {
|
||||||
if (table->HasBCBorders()) {
|
if (table->HasBCBorders()) {
|
||||||
aLists.BorderBackground()->AppendNewToTop(
|
aLists.BorderBackground()->AppendToTop(
|
||||||
new (aBuilder) nsDisplayTableBorderCollapse(aBuilder, table));
|
new (aBuilder) nsDisplayTableBorderCollapse(aBuilder, table));
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
const nsStyleBorder* borderStyle = aFrame->StyleBorder();
|
const nsStyleBorder* borderStyle = aFrame->StyleBorder();
|
||||||
if (borderStyle->HasBorder()) {
|
if (borderStyle->HasBorder()) {
|
||||||
aLists.BorderBackground()->AppendNewToTop(
|
aLists.BorderBackground()->AppendToTop(
|
||||||
new (aBuilder) nsDisplayBorder(aBuilder, table));
|
new (aBuilder) nsDisplayBorder(aBuilder, table));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1333,10 +1333,10 @@ nsBoxFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
|
|
||||||
#ifdef DEBUG_LAYOUT
|
#ifdef DEBUG_LAYOUT
|
||||||
if (mState & NS_STATE_CURRENTLY_IN_DEBUG) {
|
if (mState & NS_STATE_CURRENTLY_IN_DEBUG) {
|
||||||
destination.BorderBackground()->AppendNewToTop(new (aBuilder)
|
destination.BorderBackground()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayGeneric(aBuilder, this, PaintXULDebugBackground,
|
nsDisplayGeneric(aBuilder, this, PaintXULDebugBackground,
|
||||||
"XULDebugBackground"));
|
"XULDebugBackground"));
|
||||||
destination.Outlines()->AppendNewToTop(new (aBuilder)
|
destination.Outlines()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayXULDebug(aBuilder, this));
|
nsDisplayXULDebug(aBuilder, this));
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
@@ -1369,7 +1369,7 @@ nsBoxFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
DisplayListClipState::AutoSaveRestore ownLayerClipState(aBuilder);
|
DisplayListClipState::AutoSaveRestore ownLayerClipState(aBuilder);
|
||||||
|
|
||||||
// Wrap the list to make it its own layer
|
// Wrap the list to make it its own layer
|
||||||
aLists.Content()->AppendNewToTop(new (aBuilder)
|
aLists.Content()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayOwnLayer(aBuilder, this, &masterList, ownLayerASR,
|
nsDisplayOwnLayer(aBuilder, this, &masterList, ownLayerASR,
|
||||||
nsDisplayOwnLayerFlags::eNone,
|
nsDisplayOwnLayerFlags::eNone,
|
||||||
mozilla::layers::FrameMetrics::NULL_SCROLL_ID,
|
mozilla::layers::FrameMetrics::NULL_SCROLL_ID,
|
||||||
|
|||||||
@@ -153,7 +153,7 @@ nsGroupBoxFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
nsDisplayBackgroundImage::AppendBackgroundItemsToTop(
|
nsDisplayBackgroundImage::AppendBackgroundItemsToTop(
|
||||||
aBuilder, this, GetBackgroundRectRelativeToSelf(),
|
aBuilder, this, GetBackgroundRectRelativeToSelf(),
|
||||||
aLists.BorderBackground());
|
aLists.BorderBackground());
|
||||||
aLists.BorderBackground()->AppendNewToTop(new (aBuilder)
|
aLists.BorderBackground()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayXULGroupBorder(aBuilder, this));
|
nsDisplayXULGroupBorder(aBuilder, this));
|
||||||
|
|
||||||
DisplayOutline(aBuilder, aLists);
|
DisplayOutline(aBuilder, aLists);
|
||||||
|
|||||||
@@ -345,7 +345,7 @@ nsImageBoxFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
clip(aBuilder, this, clipFlags);
|
clip(aBuilder, this, clipFlags);
|
||||||
|
|
||||||
nsDisplayList list;
|
nsDisplayList list;
|
||||||
list.AppendNewToTop(
|
list.AppendToTop(
|
||||||
new (aBuilder) nsDisplayXULImage(aBuilder, this));
|
new (aBuilder) nsDisplayXULImage(aBuilder, this));
|
||||||
|
|
||||||
CreateOwnLayerIfNeeded(aBuilder, &list);
|
CreateOwnLayerIfNeeded(aBuilder, &list);
|
||||||
|
|||||||
@@ -114,7 +114,7 @@ nsLeafBoxFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
if (!aBuilder->IsForEventDelivery() || !IsVisibleForPainting(aBuilder))
|
if (!aBuilder->IsForEventDelivery() || !IsVisibleForPainting(aBuilder))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
aLists.Content()->AppendNewToTop(new (aBuilder)
|
aLists.Content()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayEventReceiver(aBuilder, this));
|
nsDisplayEventReceiver(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -326,7 +326,7 @@ nsSliderFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
if (aBuilder->IsForEventDelivery() && isDraggingThumb()) {
|
if (aBuilder->IsForEventDelivery() && isDraggingThumb()) {
|
||||||
// This is EVIL, we shouldn't be messing with event delivery just to get
|
// This is EVIL, we shouldn't be messing with event delivery just to get
|
||||||
// thumb mouse drag events to arrive at the slider!
|
// thumb mouse drag events to arrive at the slider!
|
||||||
aLists.Outlines()->AppendNewToTop(new (aBuilder)
|
aLists.Outlines()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayEventReceiver(aBuilder, this));
|
nsDisplayEventReceiver(aBuilder, this));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -458,7 +458,7 @@ nsSliderFrame::BuildDisplayListForChildren(nsDisplayListBuilder* aBuilder,
|
|||||||
|
|
||||||
// Wrap the list to make it its own layer.
|
// Wrap the list to make it its own layer.
|
||||||
const ActiveScrolledRoot* ownLayerASR = contASRTracker.GetContainerASR();
|
const ActiveScrolledRoot* ownLayerASR = contASRTracker.GetContainerASR();
|
||||||
aLists.Content()->AppendNewToTop(new (aBuilder)
|
aLists.Content()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayOwnLayer(aBuilder, this, &masterList, ownLayerASR,
|
nsDisplayOwnLayer(aBuilder, this, &masterList, ownLayerASR,
|
||||||
flags, scrollTargetId,
|
flags, scrollTargetId,
|
||||||
ScrollThumbData{scrollDirection,
|
ScrollThumbData{scrollDirection,
|
||||||
|
|||||||
@@ -374,7 +374,7 @@ nsSplitterFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
if (mInner->mDragging && aBuilder->IsForEventDelivery())
|
if (mInner->mDragging && aBuilder->IsForEventDelivery())
|
||||||
{
|
{
|
||||||
// XXX It's probably better not to check visibility here, right?
|
// XXX It's probably better not to check visibility here, right?
|
||||||
aLists.Outlines()->AppendNewToTop(new (aBuilder)
|
aLists.Outlines()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayEventReceiver(aBuilder, this));
|
nsDisplayEventReceiver(aBuilder, this));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -371,7 +371,7 @@ nsTextBoxFrame::BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
|||||||
|
|
||||||
nsLeafBoxFrame::BuildDisplayList(aBuilder, aLists);
|
nsLeafBoxFrame::BuildDisplayList(aBuilder, aLists);
|
||||||
|
|
||||||
aLists.Content()->AppendNewToTop(new (aBuilder)
|
aLists.Content()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayXULTextBox(aBuilder, this));
|
nsDisplayXULTextBox(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -126,7 +126,7 @@ nsTreeColFrame::BuildDisplayListForChildren(nsDisplayListBuilder* aBuilder,
|
|||||||
|
|
||||||
WrapListsInRedirector(aBuilder, set, aLists);
|
WrapListsInRedirector(aBuilder, set, aLists);
|
||||||
|
|
||||||
aLists.Content()->AppendNewToTop(new (aBuilder)
|
aLists.Content()->AppendToTop(new (aBuilder)
|
||||||
nsDisplayXULTreeColSplitterTarget(aBuilder, this));
|
nsDisplayXULTreeColSplitterTarget(aBuilder, this));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user