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 264 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
275 virtual void DidBeginMainFrame() OVERRIDE { | 275 virtual void DidBeginMainFrame() OVERRIDE { |
276 test_hooks_->DidBeginMainFrame(); | 276 test_hooks_->DidBeginMainFrame(); |
277 } | 277 } |
278 | 278 |
279 virtual void BeginMainFrame(const BeginFrameArgs& args) OVERRIDE { | 279 virtual void BeginMainFrame(const BeginFrameArgs& args) OVERRIDE { |
280 test_hooks_->BeginMainFrame(args); | 280 test_hooks_->BeginMainFrame(args); |
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 ApplyViewportDeltas(const gfx::Vector2d& scroll_delta, |
286 float scale) OVERRIDE { | 286 float scale, |
287 test_hooks_->ApplyScrollAndScale(scroll_delta, scale); | 287 float top_controls_delta) OVERRIDE { |
| 288 test_hooks_->ApplyViewportDeltas(scroll_delta, |
| 289 scale, |
| 290 top_controls_delta); |
288 } | 291 } |
289 | 292 |
290 virtual scoped_ptr<OutputSurface> CreateOutputSurface(bool fallback) | 293 virtual scoped_ptr<OutputSurface> CreateOutputSurface(bool fallback) |
291 OVERRIDE { | 294 OVERRIDE { |
292 return test_hooks_->CreateOutputSurface(fallback); | 295 return test_hooks_->CreateOutputSurface(fallback); |
293 } | 296 } |
294 | 297 |
295 virtual void DidInitializeOutputSurface() OVERRIDE { | 298 virtual void DidInitializeOutputSurface() OVERRIDE { |
296 test_hooks_->DidInitializeOutputSurface(); | 299 test_hooks_->DidInitializeOutputSurface(); |
297 } | 300 } |
(...skipping 400 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
698 return -1; | 701 return -1; |
699 } | 702 } |
700 | 703 |
701 void LayerTreeTest::DestroyLayerTreeHost() { | 704 void LayerTreeTest::DestroyLayerTreeHost() { |
702 if (layer_tree_host_ && layer_tree_host_->root_layer()) | 705 if (layer_tree_host_ && layer_tree_host_->root_layer()) |
703 layer_tree_host_->root_layer()->SetLayerTreeHost(NULL); | 706 layer_tree_host_->root_layer()->SetLayerTreeHost(NULL); |
704 layer_tree_host_.reset(); | 707 layer_tree_host_.reset(); |
705 } | 708 } |
706 | 709 |
707 } // namespace cc | 710 } // namespace cc |
OLD | NEW |