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

Unified Diff: cc/trees/thread_proxy.cc

Issue 683113005: Update from chromium https://crrev.com/302282 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 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
« no previous file with comments | « cc/trees/single_thread_proxy.cc ('k') | crypto/capi_util.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/trees/thread_proxy.cc
diff --git a/cc/trees/thread_proxy.cc b/cc/trees/thread_proxy.cc
index f5496f846f50cf32d90450e0243e45943488b30d..14e218194e026d57cf300dd7a41a58ac21cb5b8b 100644
--- a/cc/trees/thread_proxy.cc
+++ b/cc/trees/thread_proxy.cc
@@ -1217,12 +1217,10 @@ void ThreadProxy::LayerTreeHostClosedOnImplThread(CompletionEvent* completion) {
impl().scheduler = nullptr;
impl().layer_tree_host_impl = nullptr;
impl().weak_factory.InvalidateWeakPtrs();
- // We need to explicitly cancel the notifier, since it isn't using weak ptrs.
- // TODO(vmpstr): We should see if we can make it use weak ptrs and still keep
- // the convention of having a weak ptr factory initialized last. Alternatively
- // we should moved the notifier (and RenewTreePriority) to LTHI. See
- // crbug.com/411972
- impl().smoothness_priority_expiration_notifier.Cancel();
+ // We need to explicitly shutdown the notifier to destroy any weakptrs it is
+ // holding while still on the compositor thread. This also ensures any
+ // callbacks holding a ThreadProxy pointer are cancelled.
+ impl().smoothness_priority_expiration_notifier.Shutdown();
impl().contents_texture_manager = NULL;
completion->Signal();
}
« no previous file with comments | « cc/trees/single_thread_proxy.cc ('k') | crypto/capi_util.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698