Index: third_party/WebKit/Source/core/paint/FilterEffectBuilder.cpp |
diff --git a/third_party/WebKit/Source/core/paint/FilterEffectBuilder.cpp b/third_party/WebKit/Source/core/paint/FilterEffectBuilder.cpp |
index 77b99c825d2df639ed17b430763d369a932dd3b8..ccb4b0496792004ba6ec5b3f747668aa34155b87 100644 |
--- a/third_party/WebKit/Source/core/paint/FilterEffectBuilder.cpp |
+++ b/third_party/WebKit/Source/core/paint/FilterEffectBuilder.cpp |
@@ -26,8 +26,8 @@ |
#include "core/paint/FilterEffectBuilder.h" |
-#include "core/layout/svg/ReferenceFilterBuilder.h" |
#include "core/style/FilterOperations.h" |
+#include "core/svg/SVGElementProxy.h" |
#include "core/svg/SVGFilterElement.h" |
#include "core/svg/SVGLengthContext.h" |
#include "core/svg/graphics/filters/SVGFilterBuilder.h" |
@@ -404,13 +404,13 @@ CompositorFilterOperations FilterEffectBuilder::buildFilterOperations( |
Filter* FilterEffectBuilder::buildReferenceFilter( |
const ReferenceFilterOperation& referenceOperation, |
FilterEffect* previousEffect) const { |
- DCHECK(m_targetContext && m_targetContext->isElementNode()); |
- SVGFilterElement* filterElement = |
- ReferenceFilterBuilder::resolveFilterReference( |
- referenceOperation, toElement(*m_targetContext)); |
- if (!filterElement) |
+ DCHECK(m_targetContext); |
+ Element* filterElement = referenceOperation.elementProxy().findElement( |
+ m_targetContext->treeScope()); |
+ if (!isSVGFilterElement(filterElement)) |
return nullptr; |
- return buildReferenceFilter(*filterElement, previousEffect); |
+ return buildReferenceFilter(toSVGFilterElement(*filterElement), |
+ previousEffect); |
} |
Filter* FilterEffectBuilder::buildReferenceFilter( |