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

Side by Side Diff: Source/core/svg/SVGStopElement.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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/core/svg/SVGStopElement.h ('k') | Source/core/svg/SVGString.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2004, 2005, 2007, 2008 Nikolas Zimmermann <zimmermann@kde.org> 2 * Copyright (C) 2004, 2005, 2007, 2008 Nikolas Zimmermann <zimmermann@kde.org>
3 * Copyright (C) 2004, 2005, 2006, 2007 Rob Buis <buis@kde.org> 3 * Copyright (C) 2004, 2005, 2006, 2007 Rob Buis <buis@kde.org>
4 * 4 *
5 * This library is free software; you can redistribute it and/or 5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Library General Public 6 * modify it under the terms of the GNU Library General Public
7 * License as published by the Free Software Foundation; either 7 * License as published by the Free Software Foundation; either
8 * version 2 of the License, or (at your option) any later version. 8 * version 2 of the License, or (at your option) any later version.
9 * 9 *
10 * This library is distributed in the hope that it will be useful, 10 * This library is distributed in the hope that it will be useful,
(...skipping 14 matching lines...) Expand all
25 25
26 namespace blink { 26 namespace blink {
27 27
28 inline SVGStopElement::SVGStopElement(Document& document) 28 inline SVGStopElement::SVGStopElement(Document& document)
29 : SVGElement(SVGNames::stopTag, document) 29 : SVGElement(SVGNames::stopTag, document)
30 , m_offset(SVGAnimatedNumber::create(this, SVGNames::offsetAttr, SVGNumberAc ceptPercentage::create())) 30 , m_offset(SVGAnimatedNumber::create(this, SVGNames::offsetAttr, SVGNumberAc ceptPercentage::create()))
31 { 31 {
32 addToPropertyMap(m_offset); 32 addToPropertyMap(m_offset);
33 } 33 }
34 34
35 void SVGStopElement::trace(Visitor* visitor)
36 {
37 visitor->trace(m_offset);
38 SVGElement::trace(visitor);
39 }
40
35 DEFINE_NODE_FACTORY(SVGStopElement) 41 DEFINE_NODE_FACTORY(SVGStopElement)
36 42
37 void SVGStopElement::parseAttribute(const QualifiedName& name, const AtomicStrin g& value) 43 void SVGStopElement::parseAttribute(const QualifiedName& name, const AtomicStrin g& value)
38 { 44 {
39 parseAttributeNew(name, value); 45 parseAttributeNew(name, value);
40 } 46 }
41 47
42 void SVGStopElement::svgAttributeChanged(const QualifiedName& attrName) 48 void SVGStopElement::svgAttributeChanged(const QualifiedName& attrName)
43 { 49 {
44 if (attrName == SVGNames::offsetAttr) { 50 if (attrName == SVGNames::offsetAttr) {
(...skipping 24 matching lines...) Expand all
69 // which the renderer or style is null. This entire class is scheduled for r emoval (Bug WK 86941) 75 // which the renderer or style is null. This entire class is scheduled for r emoval (Bug WK 86941)
70 // and we will tolerate this null check until then. 76 // and we will tolerate this null check until then.
71 if (!style) 77 if (!style)
72 return Color(Color::transparent); // Transparent black. 78 return Color(Color::transparent); // Transparent black.
73 79
74 const SVGRenderStyle& svgStyle = style->svgStyle(); 80 const SVGRenderStyle& svgStyle = style->svgStyle();
75 return svgStyle.stopColor().combineWithAlpha(svgStyle.stopOpacity()); 81 return svgStyle.stopColor().combineWithAlpha(svgStyle.stopOpacity());
76 } 82 }
77 83
78 } // namespace blink 84 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/svg/SVGStopElement.h ('k') | Source/core/svg/SVGString.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698