From 1d126c1d566d104a0976992c63c624785825770d Mon Sep 17 00:00:00 2001 From: Botond Ballo Date: Fri, 9 Mar 2018 17:26:24 -0500 Subject: Bug 1443092 - Avoid calling SVGAnimatedEnumeration::AnimVal() from nsSVGUtils::GetBBox(). r=jwatt, a=RyanVM AnimVal() is a DOM getter, and it flushes animations, which we don't want in GetBBox() which is called from display list building cide and FrameLayerBuilder. MozReview-Commit-ID: DWgm7wAV7C0 --- layout/svg/nsSVGUtils.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'layout/svg') diff --git a/layout/svg/nsSVGUtils.cpp b/layout/svg/nsSVGUtils.cpp index ff74d5baf..344ebf645 100644 --- a/layout/svg/nsSVGUtils.cpp +++ b/layout/svg/nsSVGUtils.cpp @@ -1127,8 +1127,7 @@ nsSVGUtils::GetBBox(nsIFrame *aFrame, uint32_t aFlags) if (clipPathFrame && isOK) { SVGClipPathElement *clipContent = static_cast(clipPathFrame->GetContent()); - RefPtr units = clipContent->ClipPathUnits(); - if (units->AnimVal() == SVG_UNIT_TYPE_OBJECTBOUNDINGBOX) { + if (clipContent->IsUnitsObjectBoundingBox()) { matrix.Translate(gfxPoint(x, y)); matrix.Scale(width, height); } else if (aFrame->GetType() == nsGkAtoms::svgForeignObjectFrame) { -- cgit v1.2.3