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

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

Issue 2814453002: Add CSS conic-gradient calc() support (Closed)
Patch Set: Created 3 years, 8 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/CSSGradientValue.cpp
diff --git a/third_party/WebKit/Source/core/css/CSSGradientValue.cpp b/third_party/WebKit/Source/core/css/CSSGradientValue.cpp
index 9b5ee54f4a273f4ee69bf23d08304a63f9c77fdc..b8479450a6d75107b05c978732c4d71c90715681 100644
--- a/third_party/WebKit/Source/core/css/CSSGradientValue.cpp
+++ b/third_party/WebKit/Source/core/css/CSSGradientValue.cpp
@@ -597,7 +597,8 @@ void CSSGradientValue::AddStops(
->ToCalcValue(conversion_data)
->Evaluate(gradient_length);
stops[i].offset = (gradient_length > 0) ? length / gradient_length : 0;
- } else if (stop.offset_->IsAngle()) {
+ } else if (CSSPrimitiveValue::IsAngle(
+ stop.offset_->TypeWithCalcResolved())) {
stops[i].offset = stop.offset_->ComputeDegrees() / 360.0f;
} else {
NOTREACHED();

Powered by Google App Engine
This is Rietveld 408576698