| 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/trees/layer_tree_host_impl.h" | 5 #include "cc/trees/layer_tree_host_impl.h" |
| 6 | 6 |
| 7 #include <cmath> | 7 #include <cmath> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 85 reduce_memory_result_(true), | 85 reduce_memory_result_(true), |
| 86 current_limit_bytes_(0), | 86 current_limit_bytes_(0), |
| 87 current_priority_cutoff_value_(0) { | 87 current_priority_cutoff_value_(0) { |
| 88 media::InitializeMediaLibraryForTesting(); | 88 media::InitializeMediaLibraryForTesting(); |
| 89 } | 89 } |
| 90 | 90 |
| 91 virtual void SetUp() OVERRIDE { | 91 virtual void SetUp() OVERRIDE { |
| 92 LayerTreeSettings settings; | 92 LayerTreeSettings settings; |
| 93 settings.minimum_occlusion_tracking_size = gfx::Size(); | 93 settings.minimum_occlusion_tracking_size = gfx::Size(); |
| 94 settings.impl_side_painting = true; | 94 settings.impl_side_painting = true; |
| 95 settings.texture_id_allocation_chunk_size = 1; |
| 95 | 96 |
| 96 host_impl_ = LayerTreeHostImpl::Create( | 97 host_impl_ = LayerTreeHostImpl::Create( |
| 97 settings, this, &proxy_, &stats_instrumentation_, NULL); | 98 settings, this, &proxy_, &stats_instrumentation_, NULL); |
| 98 host_impl_->InitializeRenderer(CreateOutputSurface()); | 99 host_impl_->InitializeRenderer(CreateOutputSurface()); |
| 99 host_impl_->SetViewportSize(gfx::Size(10, 10)); | 100 host_impl_->SetViewportSize(gfx::Size(10, 10)); |
| 100 } | 101 } |
| 101 | 102 |
| 102 virtual void TearDown() OVERRIDE {} | 103 virtual void TearDown() OVERRIDE {} |
| 103 | 104 |
| 104 virtual void DidLoseOutputSurfaceOnImplThread() OVERRIDE { | 105 virtual void DidLoseOutputSurfaceOnImplThread() OVERRIDE { |
| (...skipping 5360 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5465 // The root should have scrolled. | 5466 // The root should have scrolled. |
| 5466 ASSERT_EQ(2u, scroll_info->scrolls.size()); | 5467 ASSERT_EQ(2u, scroll_info->scrolls.size()); |
| 5467 ExpectContains(*scroll_info.get(), | 5468 ExpectContains(*scroll_info.get(), |
| 5468 host_impl_->active_tree()->root_layer()->id(), | 5469 host_impl_->active_tree()->root_layer()->id(), |
| 5469 gfx::Vector2d(0, 10)); | 5470 gfx::Vector2d(0, 10)); |
| 5470 } | 5471 } |
| 5471 } | 5472 } |
| 5472 | 5473 |
| 5473 } // namespace | 5474 } // namespace |
| 5474 } // namespace cc | 5475 } // namespace cc |
| OLD | NEW |