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

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

Issue 574373004: Drop redundant checks for a color when the primary resource is a color (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 3 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/rendering/svg/RenderSVGResource.cpp
diff --git a/Source/core/rendering/svg/RenderSVGResource.cpp b/Source/core/rendering/svg/RenderSVGResource.cpp
index cc9c6067a21cf5a79306573ba73d998ec52587d5..abbbede9694e7d0c18c726253397d22a67112410 100644
--- a/Source/core/rendering/svg/RenderSVGResource.cpp
+++ b/Source/core/rendering/svg/RenderSVGResource.cpp
@@ -109,9 +109,8 @@ RenderSVGResource* RenderSVGResource::requestPaintingResource(RenderSVGResourceM
// If the primary resource is just a color, return immediately.
RenderSVGResourceSolidColor* colorResource = RenderSVGResource::sharedSolidPaintingResource();
if (paintType < SVG_PAINTTYPE_URI_NONE) {
- if (!hasColor && !inheritColorFromParentStyle(object, applyToFill, color))
- return 0;
-
+ // |paintType| will be either <current-color> or <rgb-color> here - both of which will have a color.
+ ASSERT(hasColor);
colorResource->setColor(color);
return colorResource;
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698