OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "core/animation/CSSScaleInterpolationType.h" | 5 #include "core/animation/CSSScaleInterpolationType.h" |
6 | 6 |
| 7 #include <memory> |
7 #include "core/css/CSSPrimitiveValue.h" | 8 #include "core/css/CSSPrimitiveValue.h" |
8 #include "core/css/CSSValueList.h" | 9 #include "core/css/CSSValueList.h" |
9 #include "core/css/resolver/StyleResolverState.h" | 10 #include "core/css/resolver/StyleResolverState.h" |
10 #include "wtf/PtrUtil.h" | 11 #include "wtf/PtrUtil.h" |
11 #include <memory> | |
12 | 12 |
13 namespace blink { | 13 namespace blink { |
14 | 14 |
15 namespace { | 15 namespace { |
16 | 16 |
17 struct Scale { | 17 struct Scale { |
18 Scale(double x, double y, double z) { init(x, y, z, false); } | 18 Scale(double x, double y, double z) { init(x, y, z, false); } |
19 explicit Scale() { init(1, 1, 1, true); } | 19 explicit Scale() { init(1, 1, 1, true); } |
20 explicit Scale(const ScaleTransformOperation* scale) { | 20 explicit Scale(const ScaleTransformOperation* scale) { |
21 if (scale) | 21 if (scale) |
(...skipping 225 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
247 if (scale.isNone) { | 247 if (scale.isNone) { |
248 state.style()->setScale(nullptr); | 248 state.style()->setScale(nullptr); |
249 return; | 249 return; |
250 } | 250 } |
251 state.style()->setScale(ScaleTransformOperation::create( | 251 state.style()->setScale(ScaleTransformOperation::create( |
252 scale.array[0], scale.array[1], scale.array[2], | 252 scale.array[0], scale.array[1], scale.array[2], |
253 TransformOperation::Scale3D)); | 253 TransformOperation::Scale3D)); |
254 } | 254 } |
255 | 255 |
256 } // namespace blink | 256 } // namespace blink |
OLD | NEW |