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

Side by Side Diff: third_party/WebKit/Source/platform/animation/WebTransformOperations.cpp

Issue 1616653002: CC Animation: Move files from cc_blink to Source/platform/animation (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix ScrollAnimatorCompositorCoordinator for MSVC. Created 4 years, 10 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 unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "platform/animation/WebTransformOperations.h"
6
7 #include "ui/gfx/transform.h"
8 #include <algorithm>
9
10 namespace blink {
11
12 WebTransformOperations::WebTransformOperations()
13 {
14 }
15
16 const cc::TransformOperations& WebTransformOperations::AsTransformOperations() c onst
17 {
18 return m_transformOperations;
19 }
20
21 bool WebTransformOperations::canBlendWith(const blink::WebTransformOperations& o ther) const
22 {
23 return m_transformOperations.CanBlendWith(other.m_transformOperations);
24 }
25
26 void WebTransformOperations::appendTranslate(double x, double y, double z)
27 {
28 m_transformOperations.AppendTranslate(x, y, z);
29 }
30
31 void WebTransformOperations::appendRotate(double x,
32 double y,
33 double z,
34 double degrees)
35 {
36 m_transformOperations.AppendRotate(x, y, z, degrees);
37 }
38
39 void WebTransformOperations::appendScale(double x, double y, double z)
40 {
41 m_transformOperations.AppendScale(x, y, z);
42 }
43
44 void WebTransformOperations::appendSkew(double x, double y)
45 {
46 m_transformOperations.AppendSkew(x, y);
47 }
48
49 void WebTransformOperations::appendPerspective(double depth)
50 {
51 m_transformOperations.AppendPerspective(depth);
52 }
53
54 void WebTransformOperations::appendMatrix(const SkMatrix44& matrix)
55 {
56 gfx::Transform transform(gfx::Transform::kSkipInitialization);
57 transform.matrix() = matrix;
58 m_transformOperations.AppendMatrix(transform);
59 }
60
61 void WebTransformOperations::appendIdentity()
62 {
63 m_transformOperations.AppendIdentity();
64 }
65
66 bool WebTransformOperations::isIdentity() const
67 {
68 return m_transformOperations.IsIdentity();
69 }
70
71 WebTransformOperations::~WebTransformOperations()
esprehn 2016/01/28 03:40:40 maybe move this up with the constructor above?
loyso (OOO) 2016/01/28 07:10:09 Done.
72 {
73 }
74
75 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698