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

Unified Diff: third_party/WebKit/Source/core/animation/SVGLengthInterpolationType.cpp

Issue 2130753003: Support viewport units for SVG Length animations (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: moved TCs to existing file Created 4 years, 5 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 | « third_party/WebKit/LayoutTests/animations/svg-attribute-interpolation/svg-width-interpolation.html ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/animation/SVGLengthInterpolationType.cpp
diff --git a/third_party/WebKit/Source/core/animation/SVGLengthInterpolationType.cpp b/third_party/WebKit/Source/core/animation/SVGLengthInterpolationType.cpp
index 54e47b41ea9de408c83311e72e5b44cb2f56d3fc..29b6bf2e67ec83eb4032dca12989053576860714 100644
--- a/third_party/WebKit/Source/core/animation/SVGLengthInterpolationType.cpp
+++ b/third_party/WebKit/Source/core/animation/SVGLengthInterpolationType.cpp
@@ -23,6 +23,10 @@ enum LengthInterpolatedUnit {
LengthInterpolatedEXS,
LengthInterpolatedREMS,
LengthInterpolatedCHS,
+ LengthInterpolatedViewportWidth,
+ LengthInterpolatedViewportHeight,
+ LengthInterpolatedViewportMin,
+ LengthInterpolatedViewportMax,
};
static const CSSPrimitiveValue::UnitType unitTypes[] = {
@@ -31,7 +35,11 @@ static const CSSPrimitiveValue::UnitType unitTypes[] = {
CSSPrimitiveValue::UnitType::Ems,
CSSPrimitiveValue::UnitType::Exs,
CSSPrimitiveValue::UnitType::Rems,
- CSSPrimitiveValue::UnitType::Chs
+ CSSPrimitiveValue::UnitType::Chs,
+ CSSPrimitiveValue::UnitType::ViewportWidth,
+ CSSPrimitiveValue::UnitType::ViewportHeight,
+ CSSPrimitiveValue::UnitType::ViewportMin,
+ CSSPrimitiveValue::UnitType::ViewportMax,
};
const size_t numLengthInterpolatedUnits = WTF_ARRAY_LENGTH(unitTypes);
@@ -71,6 +79,14 @@ LengthInterpolatedUnit convertToInterpolatedUnit(CSSPrimitiveValue::UnitType uni
return LengthInterpolatedREMS;
case CSSPrimitiveValue::UnitType::Chs:
return LengthInterpolatedCHS;
+ case CSSPrimitiveValue::UnitType::ViewportWidth:
+ return LengthInterpolatedViewportWidth;
+ case CSSPrimitiveValue::UnitType::ViewportHeight:
+ return LengthInterpolatedViewportHeight;
+ case CSSPrimitiveValue::UnitType::ViewportMin:
+ return LengthInterpolatedViewportMin;
+ case CSSPrimitiveValue::UnitType::ViewportMax:
+ return LengthInterpolatedViewportMax;
}
}
« no previous file with comments | « third_party/WebKit/LayoutTests/animations/svg-attribute-interpolation/svg-width-interpolation.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698