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

Unified Diff: cc/trees/threaded_channel.cc

Issue 1418953002: cc: Send shared variables between main and impl side using the channel (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Created 5 years, 1 month 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/trees/threaded_channel.h ('k') | cc/trees/threaded_channel_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/trees/threaded_channel.cc
diff --git a/cc/trees/threaded_channel.cc b/cc/trees/threaded_channel.cc
index 40c5ef2fb7fdcef33aae0df67219fa43c4a1016b..b723f8c612a93f880182836b0887bc76bed6d66c 100644
--- a/cc/trees/threaded_channel.cc
+++ b/cc/trees/threaded_channel.cc
@@ -92,10 +92,28 @@ void ThreadedChannel::SetNeedsRedrawOnImpl(const gfx::Rect& damage_rect) {
proxy_impl_->GetImplWeakPtr(), damage_rect));
}
-void ThreadedChannel::StartCommitOnImpl(CompletionEvent* completion) {
+void ThreadedChannel::StartCommitOnImpl(CompletionEvent* completion,
+ LayerTreeHost* layer_tree_host,
+ bool hold_commit_for_activation) {
ImplThreadTaskRunner()->PostTask(
- FROM_HERE, base::Bind(&ProxyImpl::StartCommitOnImpl,
+ FROM_HERE,
+ base::Bind(&ProxyImpl::StartCommitOnImpl, proxy_impl_->GetImplWeakPtr(),
+ completion, layer_tree_host, hold_commit_for_activation));
+}
+
+void ThreadedChannel::InitializeImplOnImpl(CompletionEvent* completion,
+ LayerTreeHost* layer_tree_host) {
+ ImplThreadTaskRunner()->PostTask(
+ FROM_HERE,
+ base::Bind(&ProxyImpl::InitializeImplOnImpl,
+ base::Unretained(proxy_impl_), completion, layer_tree_host));
+}
+
+void ThreadedChannel::LayerTreeHostClosedOnImpl(CompletionEvent* completion) {
+ ImplThreadTaskRunner()->PostTask(
+ FROM_HERE, base::Bind(&ProxyImpl::LayerTreeHostClosedOnImpl,
proxy_impl_->GetImplWeakPtr(), completion));
+ proxy_impl_ = nullptr;
}
void ThreadedChannel::SetVisibleOnImpl(bool visible) {
« no previous file with comments | « cc/trees/threaded_channel.h ('k') | cc/trees/threaded_channel_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698