Index: cc/trees/thread_proxy.cc |
diff --git a/cc/trees/thread_proxy.cc b/cc/trees/thread_proxy.cc |
index f72e479e9b7074b3b81f7dd679052174a3bb3a5a..09a5b22ace652e12f05f8cf4bbe6bb696d3ebaed 100644 |
--- a/cc/trees/thread_proxy.cc |
+++ b/cc/trees/thread_proxy.cc |
@@ -1085,11 +1085,8 @@ void ThreadProxy::InitializeImplOnImplThread(CompletionEvent* completion) { |
SchedulerSettings scheduler_settings( |
layer_tree_host()->settings().ToSchedulerSettings()); |
impl().scheduler = Scheduler::Create( |
- this, |
- scheduler_settings, |
- impl().layer_tree_host_id, |
- ImplThreadTaskRunner(), |
- impl().external_begin_frame_source.Pass()); |
+ this, scheduler_settings, impl().layer_tree_host_id, |
+ ImplThreadTaskRunner(), impl().external_begin_frame_source.get()); |
impl().scheduler->SetVisible(impl().layer_tree_host_impl->visible()); |
impl_thread_weak_ptr_ = impl().weak_factory.GetWeakPtr(); |
completion->Signal(); |
@@ -1136,6 +1133,7 @@ void ThreadProxy::LayerTreeHostClosedOnImplThread(CompletionEvent* completion) { |
DCHECK(IsImplThread()); |
DCHECK(IsMainThreadBlocked()); |
impl().scheduler = nullptr; |
+ impl().external_begin_frame_source = nullptr; |
impl().layer_tree_host_impl = nullptr; |
impl().weak_factory.InvalidateWeakPtrs(); |
// We need to explicitly shutdown the notifier to destroy any weakptrs it is |