Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1077)

Unified Diff: Source/core/rendering/svg/RenderSVGResourceFilter.cpp

Issue 678163002: Oilpan: move SVG property hierarchy to the heap. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebased upto r185213 Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/core/rendering/svg/RenderSVGResourceFilter.cpp
diff --git a/Source/core/rendering/svg/RenderSVGResourceFilter.cpp b/Source/core/rendering/svg/RenderSVGResourceFilter.cpp
index 920a0027dc21e0423856d704f981e73b85fc405f..25f131f1279bf60b9848ba968ea26648b2fbed38 100644
--- a/Source/core/rendering/svg/RenderSVGResourceFilter.cpp
+++ b/Source/core/rendering/svg/RenderSVGResourceFilter.cpp
@@ -33,6 +33,14 @@
namespace blink {
+void FilterData::trace(Visitor* visitor)
+{
+#if ENABLE(OILPAN)
+ visitor->trace(filter);
+ visitor->trace(builder);
+#endif
+}
+
RenderSVGResourceFilter::RenderSVGResourceFilter(SVGFilterElement* node)
: RenderSVGResourceContainer(node)
{
@@ -42,6 +50,14 @@ RenderSVGResourceFilter::~RenderSVGResourceFilter()
{
}
+void RenderSVGResourceFilter::trace(Visitor* visitor)
+{
+#if ENABLE(OILPAN)
+ visitor->trace(m_filter);
+#endif
+ RenderSVGResourceContainer::trace(visitor);
+}
+
void RenderSVGResourceFilter::destroy()
{
m_filter.clear();
@@ -68,19 +84,19 @@ void RenderSVGResourceFilter::removeClientFromCache(RenderObject* client, bool m
markClientForInvalidation(client, markForInvalidation ? BoundariesInvalidation : ParentOnlyInvalidation);
}
-PassRefPtr<SVGFilterBuilder> RenderSVGResourceFilter::buildPrimitives(SVGFilter* filter)
+PassRefPtrWillBeRawPtr<SVGFilterBuilder> RenderSVGResourceFilter::buildPrimitives(SVGFilter* filter)
{
SVGFilterElement* filterElement = toSVGFilterElement(element());
FloatRect targetBoundingBox = filter->targetBoundingBox();
// Add effects to the builder
- RefPtr<SVGFilterBuilder> builder = SVGFilterBuilder::create(SourceGraphic::create(filter), SourceAlpha::create(filter));
+ RefPtrWillBeRawPtr<SVGFilterBuilder> builder = SVGFilterBuilder::create(SourceGraphic::create(filter), SourceAlpha::create(filter));
for (SVGElement* element = Traversal<SVGElement>::firstChild(*filterElement); element; element = Traversal<SVGElement>::nextSibling(*element)) {
if (!element->isFilterEffect() || !element->renderer())
continue;
SVGFilterPrimitiveStandardAttributes* effectElement = static_cast<SVGFilterPrimitiveStandardAttributes*>(element);
- RefPtr<FilterEffect> effect = effectElement->build(builder.get(), filter);
+ RefPtrWillBeRawPtr<FilterEffect> effect = effectElement->build(builder.get(), filter);
if (!effect) {
builder->clearEffects();
return nullptr;
@@ -192,7 +208,7 @@ bool RenderSVGResourceFilter::prepareEffect(RenderObject* object, GraphicsContex
return false; // Already built, or we're in a cycle. Regardless, just do nothing more now.
}
- OwnPtr<FilterData> filterData(adoptPtr(new FilterData));
+ OwnPtrWillBeRawPtr<FilterData> filterData = FilterData::create();
FloatRect targetBoundingBox = object->objectBoundingBox();
SVGFilterElement* filterElement = toSVGFilterElement(element());
« no previous file with comments | « Source/core/rendering/svg/RenderSVGResourceFilter.h ('k') | Source/core/rendering/svg/RenderSVGResourceLinearGradient.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698