| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "webkit/compositor_bindings/web_transform_operations_impl.h" | 5 #include "webkit/compositor_bindings/web_transform_operations_impl.h" |
| 6 #include "webkit/compositor_bindings/web_transformation_matrix_util.h" |
| 6 | 7 |
| 7 namespace webkit { | 8 namespace webkit { |
| 8 | 9 |
| 9 WebTransformOperationsImpl::WebTransformOperationsImpl() { | 10 WebTransformOperationsImpl::WebTransformOperationsImpl() { |
| 10 } | 11 } |
| 11 | 12 |
| 12 const cc::TransformOperations& | 13 const cc::TransformOperations& |
| 13 WebTransformOperationsImpl::AsTransformOperations() const { | 14 WebTransformOperationsImpl::AsTransformOperations() const { |
| 14 return transform_operations_; | 15 return transform_operations_; |
| 15 } | 16 } |
| (...skipping 21 matching lines...) Expand all Loading... |
| 37 void WebTransformOperationsImpl::appendSkew(double x, double y) { | 38 void WebTransformOperationsImpl::appendSkew(double x, double y) { |
| 38 transform_operations_.AppendSkew(x, y); | 39 transform_operations_.AppendSkew(x, y); |
| 39 } | 40 } |
| 40 | 41 |
| 41 void WebTransformOperationsImpl::appendPerspective(double depth) { | 42 void WebTransformOperationsImpl::appendPerspective(double depth) { |
| 42 transform_operations_.AppendPerspective(depth); | 43 transform_operations_.AppendPerspective(depth); |
| 43 } | 44 } |
| 44 | 45 |
| 45 void WebTransformOperationsImpl::appendMatrix( | 46 void WebTransformOperationsImpl::appendMatrix( |
| 46 const WebKit::WebTransformationMatrix& matrix) { | 47 const WebKit::WebTransformationMatrix& matrix) { |
| 47 transform_operations_.AppendMatrix(matrix); | 48 transform_operations_.AppendMatrix( |
| 49 WebTransformationMatrixUtil::ToTransform(matrix)); |
| 48 } | 50 } |
| 49 | 51 |
| 50 void WebTransformOperationsImpl::appendIdentity() { | 52 void WebTransformOperationsImpl::appendIdentity() { |
| 51 transform_operations_.AppendIdentity(); | 53 transform_operations_.AppendIdentity(); |
| 52 } | 54 } |
| 53 | 55 |
| 54 bool WebTransformOperationsImpl::isIdentity() const { | 56 bool WebTransformOperationsImpl::isIdentity() const { |
| 55 return transform_operations_.IsIdentity(); | 57 return transform_operations_.IsIdentity(); |
| 56 } | 58 } |
| 57 | 59 |
| 58 WebTransformOperationsImpl::~WebTransformOperationsImpl() { | 60 WebTransformOperationsImpl::~WebTransformOperationsImpl() { |
| 59 } | 61 } |
| 60 | 62 |
| 61 } // namespace webkit | 63 } // namespace webkit |
| OLD | NEW |