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

Unified Diff: cc/test/layer_tree_test_common.h

Issue 11232051: Remove static thread pointers from CC (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Address code review comments and fix all cc_unittests Created 8 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 side-by-side diff with in-line comments
Download patch
Index: cc/test/layer_tree_test_common.h
diff --git a/cc/test/layer_tree_test_common.h b/cc/test/layer_tree_test_common.h
index 91f95252c1bc912902b4eea8cace8df99e073650..864a11d51d19d1f5098a3805935550089d4bd902 100644
--- a/cc/test/layer_tree_test_common.h
+++ b/cc/test/layer_tree_test_common.h
@@ -112,7 +112,8 @@ protected:
void dispatchDidAddAnimation();
virtual void runTest(bool threaded);
- WebKit::WebThread* webThread() const { return m_webThread.get(); }
+ WebKit::WebThread* webThread() const { return m_webImplThread.get(); }
+ cc::Proxy* proxy() const { return m_layerTreeHost->proxy(); }
cc::LayerTreeSettings m_settings;
scoped_ptr<MockLayerImplTreeHostClient> m_client;
@@ -129,7 +130,8 @@ private:
bool m_scheduled;
bool m_started;
- scoped_ptr<WebKit::WebThread> m_webThread;
+ scoped_ptr<WebKit::WebThread> m_webImplThread;
+ cc::Thread* m_implThread;
TimeoutTask* m_timeoutTask;
BeginTask* m_beginTask;
};
@@ -145,7 +147,7 @@ public:
// Adapts LayerTreeHostImpl for test. Runs real code, then invokes test hooks.
class MockLayerTreeHostImpl : public cc::LayerTreeHostImpl {
public:
- static scoped_ptr<MockLayerTreeHostImpl> create(TestHooks*, const cc::LayerTreeSettings&, cc::LayerTreeHostImplClient*);
+ static scoped_ptr<MockLayerTreeHostImpl> create(TestHooks*, const cc::LayerTreeSettings&, cc::LayerTreeHostImplClient*, cc::Proxy*);
virtual void beginCommit() OVERRIDE;
virtual void commitComplete() OVERRIDE;
@@ -161,7 +163,7 @@ protected:
virtual base::TimeDelta lowFrequencyAnimationInterval() const OVERRIDE;
private:
- MockLayerTreeHostImpl(TestHooks*, const cc::LayerTreeSettings&, cc::LayerTreeHostImplClient*);
+ MockLayerTreeHostImpl(TestHooks*, const cc::LayerTreeSettings&, cc::LayerTreeHostImplClient*, cc::Proxy*);
TestHooks* m_testHooks;
};

Powered by Google App Engine
This is Rietveld 408576698