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

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

Issue 1385043002: cc: Remove SetLayerTreeHostClientReady() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@startcomp
Patch Set: sky's offline comment Created 5 years, 2 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
« no previous file with comments | « cc/test/layer_test_common.cc ('k') | cc/test/scheduler_test_common.h » ('j') | no next file with comments »
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 "base/location.h" 8 #include "base/location.h"
9 #include "base/single_thread_task_runner.h" 9 #include "base/single_thread_task_runner.h"
10 #include "base/thread_task_runner_handle.h" 10 #include "base/thread_task_runner_handle.h"
(...skipping 737 matching lines...) Expand 10 before | Expand all | Expand 10 after
748 } 748 }
749 749
750 void LayerTreeTest::PostCompositeImmediatelyToMainThread() { 750 void LayerTreeTest::PostCompositeImmediatelyToMainThread() {
751 main_task_runner_->PostTask( 751 main_task_runner_->PostTask(
752 FROM_HERE, 752 FROM_HERE,
753 base::Bind(&LayerTreeTest::DispatchCompositeImmediately, 753 base::Bind(&LayerTreeTest::DispatchCompositeImmediately,
754 main_thread_weak_ptr_)); 754 main_thread_weak_ptr_));
755 } 755 }
756 756
757 void LayerTreeTest::WillBeginTest() { 757 void LayerTreeTest::WillBeginTest() {
758 layer_tree_host_->SetLayerTreeHostClientReady(); 758 layer_tree_host_->SetVisible(true);
759 } 759 }
760 760
761 void LayerTreeTest::DoBeginTest() { 761 void LayerTreeTest::DoBeginTest() {
762 client_ = LayerTreeHostClientForTesting::Create(this); 762 client_ = LayerTreeHostClientForTesting::Create(this);
763 763
764 scoped_ptr<FakeExternalBeginFrameSource> external_begin_frame_source; 764 scoped_ptr<FakeExternalBeginFrameSource> external_begin_frame_source;
765 if (settings_.use_external_begin_frame_source) { 765 if (settings_.use_external_begin_frame_source) {
766 external_begin_frame_source.reset(new FakeExternalBeginFrameSource( 766 external_begin_frame_source.reset(new FakeExternalBeginFrameSource(
767 settings_.renderer_settings.refresh_rate)); 767 settings_.renderer_settings.refresh_rate));
768 external_begin_frame_source_ = external_begin_frame_source.get(); 768 external_begin_frame_source_ = external_begin_frame_source.get();
(...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after
997 LayerTreeHost* LayerTreeTest::layer_tree_host() { 997 LayerTreeHost* LayerTreeTest::layer_tree_host() {
998 // We check for a null proxy here as we sometimes ask for the layer tree host 998 // We check for a null proxy here as we sometimes ask for the layer tree host
999 // when the proxy does not exist, often for checking settings after a test has 999 // when the proxy does not exist, often for checking settings after a test has
1000 // completed. For example, LTHPixelResourceTest::RunPixelResourceTest. See 1000 // completed. For example, LTHPixelResourceTest::RunPixelResourceTest. See
1001 // elsewhere in this file for other examples. 1001 // elsewhere in this file for other examples.
1002 DCHECK(!proxy() || proxy()->IsMainThread() || proxy()->IsMainThreadBlocked()); 1002 DCHECK(!proxy() || proxy()->IsMainThread() || proxy()->IsMainThreadBlocked());
1003 return layer_tree_host_.get(); 1003 return layer_tree_host_.get();
1004 } 1004 }
1005 1005
1006 } // namespace cc 1006 } // namespace cc
OLDNEW
« no previous file with comments | « cc/test/layer_test_common.cc ('k') | cc/test/scheduler_test_common.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698