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

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

Issue 23530003: cc: Block commit on activate by setting a flag on LayerTreeHost. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: blockcommit: fix flake Created 7 years, 3 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 | « cc/trees/single_thread_proxy.h ('k') | cc/trees/thread_proxy.h » ('j') | 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/output/context_provider.h" 9 #include "cc/output/context_provider.h"
10 #include "cc/output/output_surface.h" 10 #include "cc/output/output_surface.h"
(...skipping 226 matching lines...) Expand 10 before | Expand all | Expand 10 after
237 237
238 void SingleThreadProxy::SetNeedsCommit() { 238 void SingleThreadProxy::SetNeedsCommit() {
239 DCHECK(Proxy::IsMainThread()); 239 DCHECK(Proxy::IsMainThread());
240 layer_tree_host_->ScheduleComposite(); 240 layer_tree_host_->ScheduleComposite();
241 } 241 }
242 242
243 void SingleThreadProxy::SetNeedsRedraw(gfx::Rect damage_rect) { 243 void SingleThreadProxy::SetNeedsRedraw(gfx::Rect damage_rect) {
244 SetNeedsRedrawRectOnImplThread(damage_rect); 244 SetNeedsRedrawRectOnImplThread(damage_rect);
245 } 245 }
246 246
247 void SingleThreadProxy::SetNextCommitWaitsForActivation() {
248 // There is no activation here other than commit. So do nothing.
249 }
250
247 void SingleThreadProxy::SetDeferCommits(bool defer_commits) { 251 void SingleThreadProxy::SetDeferCommits(bool defer_commits) {
248 // Thread-only feature. 252 // Thread-only feature.
249 NOTREACHED(); 253 NOTREACHED();
250 } 254 }
251 255
252 bool SingleThreadProxy::CommitRequested() const { return false; } 256 bool SingleThreadProxy::CommitRequested() const { return false; }
253 257
254 size_t SingleThreadProxy::MaxPartialTextureUpdates() const { 258 size_t SingleThreadProxy::MaxPartialTextureUpdates() const {
255 return std::numeric_limits<size_t>::max(); 259 return std::numeric_limits<size_t>::max();
256 } 260 }
(...skipping 240 matching lines...) Expand 10 before | Expand all | Expand 10 after
497 void SingleThreadProxy::DidSwapFrame() { 501 void SingleThreadProxy::DidSwapFrame() {
498 if (next_frame_is_newly_committed_frame_) { 502 if (next_frame_is_newly_committed_frame_) {
499 next_frame_is_newly_committed_frame_ = false; 503 next_frame_is_newly_committed_frame_ = false;
500 layer_tree_host_->DidCommitAndDrawFrame(); 504 layer_tree_host_->DidCommitAndDrawFrame();
501 } 505 }
502 } 506 }
503 507
504 bool SingleThreadProxy::CommitPendingForTesting() { return false; } 508 bool SingleThreadProxy::CommitPendingForTesting() { return false; }
505 509
506 } // namespace cc 510 } // namespace cc
OLDNEW
« no previous file with comments | « cc/trees/single_thread_proxy.h ('k') | cc/trees/thread_proxy.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698