| 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 #ifndef CC_TEST_ANIMATION_TIMELINES_TEST_COMMON_H_ | 5 #ifndef CC_TEST_ANIMATION_TIMELINES_TEST_COMMON_H_ |
| 6 #define CC_TEST_ANIMATION_TIMELINES_TEST_COMMON_H_ | 6 #define CC_TEST_ANIMATION_TIMELINES_TEST_COMMON_H_ |
| 7 | 7 |
| 8 #include "base/containers/scoped_ptr_hash_map.h" | 8 #include "base/containers/scoped_ptr_hash_map.h" |
| 9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
| 10 #include "cc/animation/animation.h" | 10 #include "cc/animation/animation.h" |
| (...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 69 class TestHostClient : public MutatorHostClient { | 69 class TestHostClient : public MutatorHostClient { |
| 70 public: | 70 public: |
| 71 explicit TestHostClient(ThreadInstance thread_instance); | 71 explicit TestHostClient(ThreadInstance thread_instance); |
| 72 ~TestHostClient(); | 72 ~TestHostClient(); |
| 73 | 73 |
| 74 void ClearMutatedProperties(); | 74 void ClearMutatedProperties(); |
| 75 | 75 |
| 76 bool IsLayerInTree(int layer_id, LayerTreeType tree_type) const override; | 76 bool IsLayerInTree(int layer_id, LayerTreeType tree_type) const override; |
| 77 | 77 |
| 78 void SetMutatorsNeedCommit() override; | 78 void SetMutatorsNeedCommit() override; |
| 79 void SetMutatorsNeedRebuildPropertyTrees() override; |
| 79 | 80 |
| 80 void SetLayerFilterMutated(int layer_id, | 81 void SetLayerFilterMutated(int layer_id, |
| 81 LayerTreeType tree_type, | 82 LayerTreeType tree_type, |
| 82 const FilterOperations& filters) override; | 83 const FilterOperations& filters) override; |
| 83 | 84 |
| 84 void SetLayerOpacityMutated(int layer_id, | 85 void SetLayerOpacityMutated(int layer_id, |
| 85 LayerTreeType tree_type, | 86 LayerTreeType tree_type, |
| 86 float opacity) override; | 87 float opacity) override; |
| 87 | 88 |
| 88 void SetLayerTransformMutated(int layer_id, | 89 void SetLayerTransformMutated(int layer_id, |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 158 bool finished_; | 159 bool finished_; |
| 159 }; | 160 }; |
| 160 | 161 |
| 161 class AnimationTimelinesTest : public testing::Test { | 162 class AnimationTimelinesTest : public testing::Test { |
| 162 public: | 163 public: |
| 163 AnimationTimelinesTest(); | 164 AnimationTimelinesTest(); |
| 164 ~AnimationTimelinesTest() override; | 165 ~AnimationTimelinesTest() override; |
| 165 | 166 |
| 166 protected: | 167 protected: |
| 167 void SetUp() override; | 168 void SetUp() override; |
| 169 void TearDown() override; |
| 168 | 170 |
| 169 void GetImplTimelineAndPlayerByID(); | 171 void GetImplTimelineAndPlayerByID(); |
| 170 | 172 |
| 171 void ReleaseRefPtrs(); | 173 void ReleaseRefPtrs(); |
| 172 | 174 |
| 173 void AnimateLayersTransferEvents(base::TimeTicks time, | 175 void AnimateLayersTransferEvents(base::TimeTicks time, |
| 174 unsigned expect_events); | 176 unsigned expect_events); |
| 175 | 177 |
| 176 AnimationPlayer* GetPlayerForLayerId(int layer_id); | 178 AnimationPlayer* GetPlayerForLayerId(int layer_id); |
| 177 AnimationPlayer* GetImplPlayerForLayerId(int layer_id); | 179 AnimationPlayer* GetImplPlayerForLayerId(int layer_id); |
| (...skipping 11 matching lines...) Expand all Loading... |
| 189 scoped_refptr<AnimationTimeline> timeline_; | 191 scoped_refptr<AnimationTimeline> timeline_; |
| 190 scoped_refptr<AnimationPlayer> player_; | 192 scoped_refptr<AnimationPlayer> player_; |
| 191 | 193 |
| 192 scoped_refptr<AnimationTimeline> timeline_impl_; | 194 scoped_refptr<AnimationTimeline> timeline_impl_; |
| 193 scoped_refptr<AnimationPlayer> player_impl_; | 195 scoped_refptr<AnimationPlayer> player_impl_; |
| 194 }; | 196 }; |
| 195 | 197 |
| 196 } // namespace cc | 198 } // namespace cc |
| 197 | 199 |
| 198 #endif // CC_TEST_ANIMATION_TIMELINES_TEST_COMMON_H_ | 200 #endif // CC_TEST_ANIMATION_TIMELINES_TEST_COMMON_H_ |
| OLD | NEW |