OLD | NEW |
1 // Copyright 2011 The Chromium Authors. All rights reserved. | 1 // Copyright 2011 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/test/layer_tree_test.h" | 5 #include "cc/test/layer_tree_test.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "cc/animation/animation.h" | 8 #include "cc/animation/animation.h" |
9 #include "cc/animation/animation_registrar.h" | 9 #include "cc/animation/animation_registrar.h" |
10 #include "cc/animation/layer_animation_controller.h" | 10 #include "cc/animation/layer_animation_controller.h" |
(...skipping 238 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
249 break; | 249 break; |
250 } | 250 } |
251 } | 251 } |
252 test_hooks_->UpdateAnimationState(this, has_unfinished_animation); | 252 test_hooks_->UpdateAnimationState(this, has_unfinished_animation); |
253 } | 253 } |
254 | 254 |
255 base::TimeDelta LowFrequencyAnimationInterval() const override { | 255 base::TimeDelta LowFrequencyAnimationInterval() const override { |
256 return test_hooks_->LowFrequencyAnimationInterval(); | 256 return test_hooks_->LowFrequencyAnimationInterval(); |
257 } | 257 } |
258 | 258 |
| 259 void NotifyTileStateChanged(const Tile* tile) override { |
| 260 LayerTreeHostImpl::NotifyTileStateChanged(tile); |
| 261 test_hooks_->NotifyTileStateChangedOnThread(this, tile); |
| 262 } |
| 263 |
259 private: | 264 private: |
260 TestHooks* test_hooks_; | 265 TestHooks* test_hooks_; |
261 bool block_notify_ready_to_activate_for_testing_; | 266 bool block_notify_ready_to_activate_for_testing_; |
262 bool notify_ready_to_activate_was_blocked_; | 267 bool notify_ready_to_activate_was_blocked_; |
263 }; | 268 }; |
264 | 269 |
265 // Implementation of LayerTreeHost callback interface. | 270 // Implementation of LayerTreeHost callback interface. |
266 class LayerTreeHostClientForTesting : public LayerTreeHostClient, | 271 class LayerTreeHostClientForTesting : public LayerTreeHostClient, |
267 public LayerTreeHostSingleThreadClient { | 272 public LayerTreeHostSingleThreadClient { |
268 public: | 273 public: |
(...skipping 446 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
715 return -1; | 720 return -1; |
716 } | 721 } |
717 | 722 |
718 void LayerTreeTest::DestroyLayerTreeHost() { | 723 void LayerTreeTest::DestroyLayerTreeHost() { |
719 if (layer_tree_host_ && layer_tree_host_->root_layer()) | 724 if (layer_tree_host_ && layer_tree_host_->root_layer()) |
720 layer_tree_host_->root_layer()->SetLayerTreeHost(NULL); | 725 layer_tree_host_->root_layer()->SetLayerTreeHost(NULL); |
721 layer_tree_host_ = nullptr; | 726 layer_tree_host_ = nullptr; |
722 } | 727 } |
723 | 728 |
724 } // namespace cc | 729 } // namespace cc |
OLD | NEW |