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

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

Issue 14301021: cc: Don't pass simple well-defined classes by reference. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 8 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/base/thread.h" 9 #include "cc/base/thread.h"
10 #include "cc/output/context_provider.h" 10 #include "cc/output/context_provider.h"
(...skipping 210 matching lines...) Expand 10 before | Expand all | Expand 10 after
221 } 221 }
222 layer_tree_host_->CommitComplete(); 222 layer_tree_host_->CommitComplete();
223 next_frame_is_newly_committed_frame_ = true; 223 next_frame_is_newly_committed_frame_ = true;
224 } 224 }
225 225
226 void SingleThreadProxy::SetNeedsCommit() { 226 void SingleThreadProxy::SetNeedsCommit() {
227 DCHECK(Proxy::IsMainThread()); 227 DCHECK(Proxy::IsMainThread());
228 layer_tree_host_->ScheduleComposite(); 228 layer_tree_host_->ScheduleComposite();
229 } 229 }
230 230
231 void SingleThreadProxy::SetNeedsRedraw(const gfx::Rect& damage_rect) { 231 void SingleThreadProxy::SetNeedsRedraw(gfx::Rect damage_rect) {
232 // FIXME: Once we move render_widget scheduling into this class, we can 232 // FIXME: Once we move render_widget scheduling into this class, we can
233 // treat redraw requests more efficiently than CommitAndRedraw requests. 233 // treat redraw requests more efficiently than CommitAndRedraw requests.
234 layer_tree_host_impl_->SetViewportDamage(damage_rect); 234 layer_tree_host_impl_->SetViewportDamage(damage_rect);
235 SetNeedsCommit(); 235 SetNeedsCommit();
236 } 236 }
237 237
238 void SingleThreadProxy::OnHasPendingTreeStateChanged(bool have_pending_tree) { 238 void SingleThreadProxy::OnHasPendingTreeStateChanged(bool have_pending_tree) {
239 // Thread-only feature. 239 // Thread-only feature.
240 NOTREACHED(); 240 NOTREACHED();
241 } 241 }
(...skipping 227 matching lines...) Expand 10 before | Expand all | Expand 10 after
469 469
470 bool SingleThreadProxy::CommitPendingForTesting() { return false; } 470 bool SingleThreadProxy::CommitPendingForTesting() { return false; }
471 471
472 skia::RefPtr<SkPicture> SingleThreadProxy::CapturePicture() { 472 skia::RefPtr<SkPicture> SingleThreadProxy::CapturePicture() {
473 // Impl-side painting only. 473 // Impl-side painting only.
474 NOTREACHED(); 474 NOTREACHED();
475 return skia::RefPtr<SkPicture>(); 475 return skia::RefPtr<SkPicture>();
476 } 476 }
477 477
478 } // namespace cc 478 } // 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