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

Side by Side Diff: cc/trees/single_thread_proxy.cc

Issue 284233005: cc: CapturePostTask in SingleThreadProxy::Stop (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: review Created 6 years, 7 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2011 The Chromium Authors. All rights reserved. 1 // Copyright 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "cc/trees/single_thread_proxy.h" 5 #include "cc/trees/single_thread_proxy.h"
6 6
7 #include "base/auto_reset.h" 7 #include "base/auto_reset.h"
8 #include "base/debug/trace_event.h" 8 #include "base/debug/trace_event.h"
9 #include "cc/debug/benchmark_instrumentation.h" 9 #include "cc/debug/benchmark_instrumentation.h"
10 #include "cc/output/context_provider.h" 10 #include "cc/output/context_provider.h"
(...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after
212 return std::numeric_limits<size_t>::max(); 212 return std::numeric_limits<size_t>::max();
213 } 213 }
214 214
215 void SingleThreadProxy::Stop() { 215 void SingleThreadProxy::Stop() {
216 TRACE_EVENT0("cc", "SingleThreadProxy::stop"); 216 TRACE_EVENT0("cc", "SingleThreadProxy::stop");
217 DCHECK(Proxy::IsMainThread()); 217 DCHECK(Proxy::IsMainThread());
218 { 218 {
219 DebugScopedSetMainThreadBlocked main_thread_blocked(this); 219 DebugScopedSetMainThreadBlocked main_thread_blocked(this);
220 DebugScopedSetImplThread impl(this); 220 DebugScopedSetImplThread impl(this);
221 221
222 BlockingTaskRunner::CapturePostTasks blocked;
222 layer_tree_host_->DeleteContentsTexturesOnImplThread( 223 layer_tree_host_->DeleteContentsTexturesOnImplThread(
223 layer_tree_host_impl_->resource_provider()); 224 layer_tree_host_impl_->resource_provider());
224 layer_tree_host_impl_.reset(); 225 layer_tree_host_impl_.reset();
225 } 226 }
226 layer_tree_host_ = NULL; 227 layer_tree_host_ = NULL;
227 } 228 }
228 229
229 void SingleThreadProxy::OnCanDrawStateChanged(bool can_draw) { 230 void SingleThreadProxy::OnCanDrawStateChanged(bool can_draw) {
230 TRACE_EVENT1( 231 TRACE_EVENT1(
231 "cc", "SingleThreadProxy::OnCanDrawStateChanged", "can_draw", can_draw); 232 "cc", "SingleThreadProxy::OnCanDrawStateChanged", "can_draw", can_draw);
(...skipping 244 matching lines...) Expand 10 before | Expand all | Expand 10 after
476 void SingleThreadProxy::DidSwapFrame() { 477 void SingleThreadProxy::DidSwapFrame() {
477 if (next_frame_is_newly_committed_frame_) { 478 if (next_frame_is_newly_committed_frame_) {
478 next_frame_is_newly_committed_frame_ = false; 479 next_frame_is_newly_committed_frame_ = false;
479 layer_tree_host_->DidCommitAndDrawFrame(); 480 layer_tree_host_->DidCommitAndDrawFrame();
480 } 481 }
481 } 482 }
482 483
483 bool SingleThreadProxy::CommitPendingForTesting() { return false; } 484 bool SingleThreadProxy::CommitPendingForTesting() { return false; }
484 485
485 } // namespace cc 486 } // namespace cc
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698