| 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 269 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 280 test_hooks_->Animate(monotonic_time); | 280 test_hooks_->Animate(monotonic_time); |
| 281 } | 281 } |
| 282 | 282 |
| 283 virtual void Layout() OVERRIDE { test_hooks_->Layout(); } | 283 virtual void Layout() OVERRIDE { test_hooks_->Layout(); } |
| 284 | 284 |
| 285 virtual void ApplyScrollAndScale(const gfx::Vector2d& scroll_delta, | 285 virtual void ApplyScrollAndScale(const gfx::Vector2d& scroll_delta, |
| 286 float scale) OVERRIDE { | 286 float scale) OVERRIDE { |
| 287 test_hooks_->ApplyScrollAndScale(scroll_delta, scale); | 287 test_hooks_->ApplyScrollAndScale(scroll_delta, scale); |
| 288 } | 288 } |
| 289 | 289 |
| 290 virtual void RecordDrawTiming(int64_t rect_id, |
| 291 const std::vector<std::pair<int, base::TimeTicks> >& draws) OVERRIDE { |
| 292 test_hooks_->RecordDrawTiming(rect_id, draws); |
| 293 } |
| 294 |
| 290 virtual scoped_ptr<OutputSurface> CreateOutputSurface(bool fallback) | 295 virtual scoped_ptr<OutputSurface> CreateOutputSurface(bool fallback) |
| 291 OVERRIDE { | 296 OVERRIDE { |
| 292 return test_hooks_->CreateOutputSurface(fallback); | 297 return test_hooks_->CreateOutputSurface(fallback); |
| 293 } | 298 } |
| 294 | 299 |
| 295 virtual void DidInitializeOutputSurface() OVERRIDE { | 300 virtual void DidInitializeOutputSurface() OVERRIDE { |
| 296 test_hooks_->DidInitializeOutputSurface(); | 301 test_hooks_->DidInitializeOutputSurface(); |
| 297 } | 302 } |
| 298 | 303 |
| 299 virtual void DidFailToInitializeOutputSurface() OVERRIDE { | 304 virtual void DidFailToInitializeOutputSurface() OVERRIDE { |
| (...skipping 441 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 741 return -1; | 746 return -1; |
| 742 } | 747 } |
| 743 | 748 |
| 744 void LayerTreeTest::DestroyLayerTreeHost() { | 749 void LayerTreeTest::DestroyLayerTreeHost() { |
| 745 if (layer_tree_host_ && layer_tree_host_->root_layer()) | 750 if (layer_tree_host_ && layer_tree_host_->root_layer()) |
| 746 layer_tree_host_->root_layer()->SetLayerTreeHost(NULL); | 751 layer_tree_host_->root_layer()->SetLayerTreeHost(NULL); |
| 747 layer_tree_host_.reset(); | 752 layer_tree_host_.reset(); |
| 748 } | 753 } |
| 749 | 754 |
| 750 } // namespace cc | 755 } // namespace cc |
| OLD | NEW |