Bug 1052999 - Stop using FOR_PAINTING in nsSVGForeignObjectFrame::GetInvalidRegion. r=longsonr

This commit is contained in:
Jonathan Watt 2014-08-13 13:36:41 +01:00
parent 611f420f83
commit 04e2673287

View File

@ -570,11 +570,14 @@ nsSVGForeignObjectFrame::DoReflow()
nsRect
nsSVGForeignObjectFrame::GetInvalidRegion()
{
MOZ_ASSERT(!NS_SVGDisplayListPaintingEnabled(),
"Only called by nsDisplayOuterSVG code");
nsIFrame* kid = GetFirstPrincipalChild();
if (kid->HasInvalidFrameInSubtree()) {
gfxRect r(mRect.x, mRect.y, mRect.width, mRect.height);
r.Scale(1.0 / nsPresContext::AppUnitsPerCSSPixel());
nsRect rect = nsSVGUtils::ToCanvasBounds(r, GetCanvasTM(FOR_PAINTING), PresContext());
nsRect rect = nsSVGUtils::ToCanvasBounds(r, GetCanvasTM(FOR_OUTERSVG_TM), PresContext());
rect = nsSVGUtils::GetPostFilterVisualOverflowRect(this, rect);
return rect;
}