Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(98)

Side by Side Diff: cc/test/layer_tree_test.cc

Issue 14061028: cc: Set tile manager memory policy in initializeRenderer. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Remove DCHECK Created 7 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | cc/trees/layer_tree_host_impl.h » ('j') | cc/trees/thread_proxy.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 115 matching lines...) Expand 10 before | Expand all | Expand 10 after
126 return false; 126 return false;
127 127
128 bool activated = LayerTreeHostImpl::ActivatePendingTreeIfNeeded(); 128 bool activated = LayerTreeHostImpl::ActivatePendingTreeIfNeeded();
129 if (activated) 129 if (activated)
130 test_hooks_->TreeActivatedOnThread(this); 130 test_hooks_->TreeActivatedOnThread(this);
131 return activated; 131 return activated;
132 } 132 }
133 133
134 virtual bool InitializeRenderer(scoped_ptr<OutputSurface> output_surface) 134 virtual bool InitializeRenderer(scoped_ptr<OutputSurface> output_surface)
135 OVERRIDE { 135 OVERRIDE {
136 // By default, suppress tile management scheduling unless we're explicitly
137 // testing that.
138 LayerTreeHostImpl::SetManagedMemoryPolicy(ManagedMemoryPolicy(0));
139
136 bool success = LayerTreeHostImpl::InitializeRenderer(output_surface.Pass()); 140 bool success = LayerTreeHostImpl::InitializeRenderer(output_surface.Pass());
137 test_hooks_->InitializedRendererOnThread(this, success); 141 test_hooks_->InitializedRendererOnThread(this, success);
138 return success; 142 return success;
139 } 143 }
140 144
141 virtual void SetVisible(bool visible) OVERRIDE { 145 virtual void SetVisible(bool visible) OVERRIDE {
142 LayerTreeHostImpl::SetVisible(visible); 146 LayerTreeHostImpl::SetVisible(visible);
143 test_hooks_->DidSetVisibleOnImplTree(this, visible); 147 test_hooks_->DidSetVisibleOnImplTree(this, visible);
144 } 148 }
145 149
(...skipping 429 matching lines...) Expand 10 before | Expand all | Expand 10 after
575 ASSERT_FALSE(layer_tree_host_.get()); 579 ASSERT_FALSE(layer_tree_host_.get());
576 client_.reset(); 580 client_.reset();
577 if (timed_out_) { 581 if (timed_out_) {
578 FAIL() << "Test timed out"; 582 FAIL() << "Test timed out";
579 return; 583 return;
580 } 584 }
581 AfterTest(); 585 AfterTest();
582 } 586 }
583 587
584 } // namespace cc 588 } // namespace cc
OLDNEW
« no previous file with comments | « no previous file | cc/trees/layer_tree_host_impl.h » ('j') | cc/trees/thread_proxy.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698