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

Unified Diff: cc/test/fake_layer_tree_host.cc

Issue 606113003: Revert of Make cc output surface creation async (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/test/fake_layer_tree_host.h ('k') | cc/test/fake_layer_tree_host_client.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/test/fake_layer_tree_host.cc
diff --git a/cc/test/fake_layer_tree_host.cc b/cc/test/fake_layer_tree_host.cc
index 32767c824aba590615be64a177ed110fca96b400..28a7a527c8181f244499a6f9ab08ac06808232eb 100644
--- a/cc/test/fake_layer_tree_host.cc
+++ b/cc/test/fake_layer_tree_host.cc
@@ -5,29 +5,22 @@
#include "cc/test/fake_layer_tree_host.h"
namespace cc {
-FakeLayerTreeHost::FakeLayerTreeHost(FakeLayerTreeHostClient* client,
+FakeLayerTreeHost::FakeLayerTreeHost(LayerTreeHostClient* client,
const LayerTreeSettings& settings)
: LayerTreeHost(client, NULL, settings),
- client_(client),
host_impl_(settings, &proxy_, &manager_),
- needs_commit_(false) {
- client_->SetLayerTreeHost(this);
+ needs_commit_(false) {}
+
+scoped_ptr<FakeLayerTreeHost> FakeLayerTreeHost::Create() {
+ static FakeLayerTreeHostClient client(FakeLayerTreeHostClient::DIRECT_3D);
+ static LayerTreeSettings settings;
+ return make_scoped_ptr(new FakeLayerTreeHost(&client, settings));
}
scoped_ptr<FakeLayerTreeHost> FakeLayerTreeHost::Create(
- FakeLayerTreeHostClient* client) {
- LayerTreeSettings settings;
- return make_scoped_ptr(new FakeLayerTreeHost(client, settings));
-}
-
-scoped_ptr<FakeLayerTreeHost> FakeLayerTreeHost::Create(
- FakeLayerTreeHostClient* client,
const LayerTreeSettings& settings) {
- return make_scoped_ptr(new FakeLayerTreeHost(client, settings));
-}
-
-FakeLayerTreeHost::~FakeLayerTreeHost() {
- client_->SetLayerTreeHost(NULL);
+ static FakeLayerTreeHostClient client(FakeLayerTreeHostClient::DIRECT_3D);
+ return make_scoped_ptr(new FakeLayerTreeHost(&client, settings));
}
void FakeLayerTreeHost::SetNeedsCommit() { needs_commit_ = true; }
« no previous file with comments | « cc/test/fake_layer_tree_host.h ('k') | cc/test/fake_layer_tree_host_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698