Index: third_party/WebKit/Source/core/animation/LengthListPropertyFunctions.cpp |
diff --git a/third_party/WebKit/Source/core/animation/LengthListPropertyFunctions.cpp b/third_party/WebKit/Source/core/animation/LengthListPropertyFunctions.cpp |
index 62680c3450d5a13992161e2c35fd823e47a464e1..28fc54865a575bfbacbf85944dfa558a2387d185 100644 |
--- a/third_party/WebKit/Source/core/animation/LengthListPropertyFunctions.cpp |
+++ b/third_party/WebKit/Source/core/animation/LengthListPropertyFunctions.cpp |
@@ -76,6 +76,8 @@ ValueRange LengthListPropertyFunctions::valueRange(CSSPropertyID property) |
switch (property) { |
case CSSPropertyBackgroundPositionX: |
case CSSPropertyBackgroundPositionY: |
+ case CSSPropertyObjectPosition: |
+ case CSSPropertyPerspectiveOrigin: |
case CSSPropertyWebkitMaskPositionX: |
case CSSPropertyWebkitMaskPositionY: |
return ValueRangeAll; |
@@ -98,10 +100,21 @@ Vector<Length> LengthListPropertyFunctions::getLengthList(CSSPropertyID property |
{ |
Vector<Length> result; |
- if (property == CSSPropertyStrokeDasharray) { |
+ switch (property) { |
+ case CSSPropertyStrokeDasharray: |
if (style.strokeDashArray()) |
result.appendVector(style.strokeDashArray()->vector()); |
return result; |
+ case CSSPropertyObjectPosition: |
+ result.append(style.objectPosition().x()); |
+ result.append(style.objectPosition().y()); |
+ return result; |
+ case CSSPropertyPerspectiveOrigin: |
+ result.append(style.perspectiveOrigin().x()); |
+ result.append(style.perspectiveOrigin().y()); |
+ return result; |
+ default: |
+ break; |
} |
const FillLayer* fillLayer = getFillLayer(property, style); |
@@ -115,9 +128,18 @@ Vector<Length> LengthListPropertyFunctions::getLengthList(CSSPropertyID property |
void LengthListPropertyFunctions::setLengthList(CSSPropertyID property, ComputedStyle& style, Vector<Length>&& lengthList) |
{ |
- if (property == CSSPropertyStrokeDasharray) { |
+ switch (property) { |
+ case CSSPropertyStrokeDasharray: |
style.setStrokeDashArray(lengthList.isEmpty() ? nullptr : RefVector<Length>::create(std::move(lengthList))); |
return; |
+ case CSSPropertyObjectPosition: |
+ style.setObjectPosition(LengthPoint(lengthList[0], lengthList[1])); |
+ return; |
+ case CSSPropertyPerspectiveOrigin: |
+ style.setPerspectiveOrigin(LengthPoint(lengthList[0], lengthList[1])); |
+ return; |
+ default: |
+ break; |
} |
FillLayer* fillLayer = accessFillLayer(property, style); |