Backed out changeset b954874c5ced (bug 1379344) for failing reftests 1111753-1.html, 1119117-1b.html and clipped-opacity-containing-unclipped-mixblendmode-ref.html. r=backout on a CLOSED TREE

This commit is contained in:
Sebastian Hengst 2017-08-04 09:24:42 +02:00
parent a773ee4276
commit d55e18d804
2 changed files with 4 additions and 15 deletions

View File

@ -1892,8 +1892,7 @@ nsDisplayList::GetBounds(nsDisplayListBuilder* aBuilder) const {
nsRect
nsDisplayList::GetClippedBoundsWithRespectToASR(nsDisplayListBuilder* aBuilder,
const ActiveScrolledRoot* aASR,
nsRect* aVisibleRect) const {
const ActiveScrolledRoot* aASR) const {
nsRect bounds;
for (nsDisplayItem* i = GetBottom(); i != nullptr; i = i->GetAbove()) {
nsRect r = i->GetClippedBounds(aBuilder);
@ -1908,9 +1907,6 @@ nsDisplayList::GetClippedBoundsWithRespectToASR(nsDisplayListBuilder* aBuilder,
if (clip) {
r = clip->GetClipRect();
}
if (aVisibleRect) {
aVisibleRect->UnionRect(*aVisibleRect, i->GetVisibleRect());
}
}
bounds.UnionRect(bounds, r);
}

View File

@ -2517,14 +2517,9 @@ public:
* If there is an item in this list which is not bounded with respect to
* aASR (i.e. which does not have "finite bounds" with respect to aASR),
* then this method trigger an assertion failure.
* The optional aVisibleRect out argument can be set to non-null if the
* caller is also interested to know the visible rect. This can be used
* to get the visible rect efficiently without traversing the display list
* twice.
*/
nsRect GetClippedBoundsWithRespectToASR(nsDisplayListBuilder* aBuilder,
const ActiveScrolledRoot* aASR,
nsRect* aVisibleRect = nullptr) const;
const ActiveScrolledRoot* aASR) const;
/**
* Find the topmost display item that returns a non-null frame, and return
@ -3827,9 +3822,7 @@ public:
*/
virtual void UpdateBounds(nsDisplayListBuilder* aBuilder) override
{
nsRect visibleRect;
mBounds = mList.GetClippedBoundsWithRespectToASR(aBuilder, mActiveScrolledRoot,
&visibleRect);
mBounds = mList.GetClippedBoundsWithRespectToASR(aBuilder, mActiveScrolledRoot);
// The display list may contain content that's visible outside the visible
// rect (i.e. the current dirty rect) passed in when the item was created.
// This happens when the dirty rect has been restricted to the visual
@ -3837,7 +3830,7 @@ public:
// rects in nsDisplayListBuilder::MarkOutOfFlowFrameForDisplay), but that
// frame contains placeholders for out-of-flows that aren't descendants of
// the frame.
mVisibleRect.UnionRect(mBaseVisibleRect, visibleRect);
mVisibleRect.UnionRect(mBaseVisibleRect, mList.GetVisibleRect());
}
virtual void HitTest(nsDisplayListBuilder* aBuilder, const nsRect& aRect,
HitTestState* aState, nsTArray<nsIFrame*> *aOutFrames) override;