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

Unified Diff: third_party/WebKit/Source/core/css/ComputedStyleCSSValueMapping.cpp

Issue 2322343003: Add support for <basic-shape> to 'clip-path' on SVG elements (Closed)
Patch Set: Update SPv2 expectations Created 4 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
Index: third_party/WebKit/Source/core/css/ComputedStyleCSSValueMapping.cpp
diff --git a/third_party/WebKit/Source/core/css/ComputedStyleCSSValueMapping.cpp b/third_party/WebKit/Source/core/css/ComputedStyleCSSValueMapping.cpp
index 23d3b172a14fb8cf40de6a0d323e4f1704f79f85..d976d6a38e2683525bcb516655afa4ae813140ac 100644
--- a/third_party/WebKit/Source/core/css/ComputedStyleCSSValueMapping.cpp
+++ b/third_party/WebKit/Source/core/css/ComputedStyleCSSValueMapping.cpp
@@ -2651,7 +2651,9 @@ const CSSValue* ComputedStyleCSSValueMapping::get(CSSPropertyID propertyID, cons
case CSSPropertyCounterReset:
return valueForCounterDirectives(style, propertyID);
case CSSPropertyWebkitClipPath:
- if (ClipPathOperation* operation = style.clipPath()) {
+ case CSSPropertyClipPath:
+ if (ClipPathOperation* operation = propertyID == CSSPropertyWebkitClipPath
+ ? style.clipPath() : style.svgStyle().clipPath()) {
if (operation->type() == ClipPathOperation::SHAPE)
return valueForBasicShape(style, toShapeClipPathOperation(operation)->basicShape());
if (operation->type() == ClipPathOperation::REFERENCE)
@@ -2847,10 +2849,6 @@ const CSSValue* ComputedStyleCSSValueMapping::get(CSSPropertyID propertyID, cons
return CSSPrimitiveValue::create(svgStyle.dominantBaseline());
case CSSPropertyTextAnchor:
return CSSPrimitiveValue::create(svgStyle.textAnchor());
- case CSSPropertyClipPath:
- if (!svgStyle.clipperResource().isEmpty())
- return CSSURIValue::create(serializeAsFragmentIdentifier(svgStyle.clipperResource()));
- return CSSPrimitiveValue::createIdentifier(CSSValueNone);
case CSSPropertyMask:
if (!svgStyle.maskerResource().isEmpty())
return CSSURIValue::create(serializeAsFragmentIdentifier(svgStyle.maskerResource()));
« no previous file with comments | « third_party/WebKit/Source/core/css/CSSProperties.in ('k') | third_party/WebKit/Source/core/css/parser/CSSPropertyParser.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698