| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "content/renderer/compositor_bindings/web_animation_impl.h" | 5 #include "cc/blink/web_animation_impl.h" |
| 6 | 6 |
| 7 #include "cc/animation/animation.h" | 7 #include "cc/animation/animation.h" |
| 8 #include "cc/animation/animation_curve.h" | 8 #include "cc/animation/animation_curve.h" |
| 9 #include "cc/animation/animation_id_provider.h" | 9 #include "cc/animation/animation_id_provider.h" |
| 10 #include "content/renderer/compositor_bindings/web_filter_animation_curve_impl.h
" | 10 #include "cc/blink/web_filter_animation_curve_impl.h" |
| 11 #include "content/renderer/compositor_bindings/web_float_animation_curve_impl.h" | 11 #include "cc/blink/web_float_animation_curve_impl.h" |
| 12 #include "content/renderer/compositor_bindings/web_scroll_offset_animation_curve
_impl.h" | 12 #include "cc/blink/web_scroll_offset_animation_curve_impl.h" |
| 13 #include "content/renderer/compositor_bindings/web_transform_animation_curve_imp
l.h" | 13 #include "cc/blink/web_transform_animation_curve_impl.h" |
| 14 #include "third_party/WebKit/public/platform/WebCompositorAnimation.h" | 14 #include "third_party/WebKit/public/platform/WebCompositorAnimation.h" |
| 15 | 15 |
| 16 using cc::Animation; | 16 using cc::Animation; |
| 17 using cc::AnimationIdProvider; | 17 using cc::AnimationIdProvider; |
| 18 | 18 |
| 19 using blink::WebCompositorAnimation; | 19 using blink::WebCompositorAnimation; |
| 20 using blink::WebCompositorAnimationCurve; | 20 using blink::WebCompositorAnimationCurve; |
| 21 | 21 |
| 22 namespace content { | 22 namespace cc_blink { |
| 23 | 23 |
| 24 WebCompositorAnimationImpl::WebCompositorAnimationImpl( | 24 WebCompositorAnimationImpl::WebCompositorAnimationImpl( |
| 25 const WebCompositorAnimationCurve& web_curve, | 25 const WebCompositorAnimationCurve& web_curve, |
| 26 TargetProperty target_property, | 26 TargetProperty target_property, |
| 27 int animation_id, | 27 int animation_id, |
| 28 int group_id) { | 28 int group_id) { |
| 29 if (!animation_id) | 29 if (!animation_id) |
| 30 animation_id = AnimationIdProvider::NextAnimationId(); | 30 animation_id = AnimationIdProvider::NextAnimationId(); |
| 31 if (!group_id) | 31 if (!group_id) |
| 32 group_id = AnimationIdProvider::NextGroupId(); | 32 group_id = AnimationIdProvider::NextGroupId(); |
| (...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 159 else | 159 else |
| 160 animation_->set_direction(cc::Animation::Normal); | 160 animation_->set_direction(cc::Animation::Normal); |
| 161 } | 161 } |
| 162 #endif | 162 #endif |
| 163 | 163 |
| 164 scoped_ptr<cc::Animation> WebCompositorAnimationImpl::PassAnimation() { | 164 scoped_ptr<cc::Animation> WebCompositorAnimationImpl::PassAnimation() { |
| 165 animation_->set_needs_synchronized_start_time(true); | 165 animation_->set_needs_synchronized_start_time(true); |
| 166 return animation_.Pass(); | 166 return animation_.Pass(); |
| 167 } | 167 } |
| 168 | 168 |
| 169 } // namespace content | 169 } // namespace cc_blink |
| 170 | |
| OLD | NEW |