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 "cc/animation/animation_player.h" | 5 #include "cc/animation/animation_player.h" |
6 | 6 |
7 #include "base/containers/hash_tables.h" | 7 #include "base/containers/hash_tables.h" |
8 #include "cc/animation/animation_delegate.h" | 8 #include "cc/animation/animation_delegate.h" |
9 #include "cc/animation/animation_host.h" | 9 #include "cc/animation/animation_host.h" |
10 #include "cc/animation/animation_registrar.h" | 10 #include "cc/animation/animation_registrar.h" |
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
72 float opacity) override { | 72 float opacity) override { |
73 SetLayerMutated(layer_id, active_tree, Animation::OPACITY); | 73 SetLayerMutated(layer_id, active_tree, Animation::OPACITY); |
74 } | 74 } |
75 | 75 |
76 void SetLayerTransformMutated(int layer_id, | 76 void SetLayerTransformMutated(int layer_id, |
77 bool active_tree, | 77 bool active_tree, |
78 const gfx::Transform& transform) override { | 78 const gfx::Transform& transform) override { |
79 SetLayerMutated(layer_id, active_tree, Animation::TRANSFORM); | 79 SetLayerMutated(layer_id, active_tree, Animation::TRANSFORM); |
80 } | 80 } |
81 | 81 |
| 82 void ScrollOffsetAnimationFinished() override {} |
| 83 gfx::ScrollOffset GetScrollOffsetForAnimation(int layer_id) const override { |
| 84 return gfx::ScrollOffset(); |
| 85 } |
| 86 |
82 void SetLayerScrollOffsetMutated( | 87 void SetLayerScrollOffsetMutated( |
83 int layer_id, | 88 int layer_id, |
84 bool active_tree, | 89 bool active_tree, |
85 const gfx::ScrollOffset& scroll_offset) override { | 90 const gfx::ScrollOffset& scroll_offset) override { |
86 SetLayerMutated(layer_id, active_tree, Animation::SCROLL_OFFSET); | 91 SetLayerMutated(layer_id, active_tree, Animation::SCROLL_OFFSET); |
87 } | 92 } |
88 | 93 |
89 bool mutators_need_commit() const { return mutators_need_commit_; } | 94 bool mutators_need_commit() const { return mutators_need_commit_; } |
90 void set_mutators_need_commit(bool need) { mutators_need_commit_ = need; } | 95 void set_mutators_need_commit(bool need) { mutators_need_commit_ = need; } |
91 | 96 |
(...skipping 386 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
478 EXPECT_TRUE(client_.mutators_need_commit()); | 483 EXPECT_TRUE(client_.mutators_need_commit()); |
479 client_.set_mutators_need_commit(false); | 484 client_.set_mutators_need_commit(false); |
480 | 485 |
481 player_->RemoveAnimation(animation_id); | 486 player_->RemoveAnimation(animation_id); |
482 EXPECT_TRUE(client_.mutators_need_commit()); | 487 EXPECT_TRUE(client_.mutators_need_commit()); |
483 client_.set_mutators_need_commit(false); | 488 client_.set_mutators_need_commit(false); |
484 } | 489 } |
485 | 490 |
486 } // namespace | 491 } // namespace |
487 } // namespace cc | 492 } // namespace cc |
OLD | NEW |