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

Unified Diff: Source/WebCore/rendering/svg/SVGResources.cpp

Issue 7002001: Revert 79985 - 2011-03-01 Nikolas Zimmermann <nzimmermann@rim.com> (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/742/
Patch Set: Created 9 years, 7 months 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
« no previous file with comments | « Source/WebCore/rendering/svg/RenderSVGResourceClipper.cpp ('k') | Source/WebCore/svg/SVGColor.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/WebCore/rendering/svg/SVGResources.cpp
===================================================================
--- Source/WebCore/rendering/svg/SVGResources.cpp (revision 86165)
+++ Source/WebCore/rendering/svg/SVGResources.cpp (working copy)
@@ -152,12 +152,15 @@
return SVGURIReference::getTarget(target);
}
-static inline RenderSVGResourceContainer* paintingResourceFromSVGPaint(Document* document, const SVGPaint::SVGPaintType& paintType, const String& paintUri, AtomicString& id, bool& hasPendingResource)
+static inline RenderSVGResourceContainer* paintingResourceFromSVGPaint(Document* document, SVGPaint* paint, AtomicString& id, bool& hasPendingResource)
{
+ ASSERT(paint);
+
+ SVGPaint::SVGPaintType paintType = paint->paintType();
if (paintType != SVGPaint::SVG_PAINTTYPE_URI && paintType != SVGPaint::SVG_PAINTTYPE_URI_RGBCOLOR)
return 0;
- id = SVGURIReference::getTarget(paintUri);
+ id = SVGURIReference::getTarget(paint->uri());
RenderSVGResourceContainer* container = getRenderSVGResourceContainerById(document, id);
if (!container) {
hasPendingResource = true;
@@ -256,7 +259,7 @@
if (style->hasFill()) {
bool hasPendingResource = false;
AtomicString id;
- if (setFill(paintingResourceFromSVGPaint(document, style->fillPaintType(), style->fillPaintUri(), id, hasPendingResource)))
+ if (setFill(paintingResourceFromSVGPaint(document, style->fillPaint(), id, hasPendingResource)))
foundResources = true;
else if (hasPendingResource)
registerPendingResource(extensions, id, element);
@@ -265,7 +268,7 @@
if (style->hasStroke()) {
bool hasPendingResource = false;
AtomicString id;
- if (setStroke(paintingResourceFromSVGPaint(document, style->strokePaintType(), style->strokePaintUri(), id, hasPendingResource)))
+ if (setStroke(paintingResourceFromSVGPaint(document, style->strokePaint(), id, hasPendingResource)))
foundResources = true;
else if (hasPendingResource)
registerPendingResource(extensions, id, element);
« no previous file with comments | « Source/WebCore/rendering/svg/RenderSVGResourceClipper.cpp ('k') | Source/WebCore/svg/SVGColor.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698