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

Unified Diff: cc/trees/thread_proxy.cc

Issue 246753008: cc: Unify use of DidSwapBuffers() and did_request_swap (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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 side-by-side diff with in-line comments
Download patch
« cc/scheduler/scheduler.cc ('K') | « cc/scheduler/scheduler_unittest.cc ('k') | no next file » | 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 cac9bc6f94bceb2034e60448a4415b633a496dde..a7986d47bbe4e88f9f6da69ff854f09aca8a5efa 100644
--- a/cc/trees/thread_proxy.cc
+++ b/cc/trees/thread_proxy.cc
@@ -1231,25 +1231,25 @@ DrawSwapReadbackResult ThreadProxy::DrawSwapReadbackInternal(
// Check for a pending CompositeAndReadback.
if (drawing_for_readback) {
DCHECK(!swap_requested);
- result.did_readback = false;
+ bool did_readback = false;
if (draw_frame) {
if (!impl().layer_tree_host_impl->IsContextLost()) {
impl().layer_tree_host_impl->Readback(impl().readback_request->pixels,
impl().readback_request->rect);
- result.did_readback = true;
+ did_readback = true;
} else {
result.draw_result = DrawSwapReadbackResult::DRAW_ABORTED_CONTEXT_LOST;
}
}
- impl().readback_request->success = result.did_readback;
+ impl().readback_request->success = did_readback;
impl().readback_request->completion.Signal();
impl().readback_request = NULL;
} else if (draw_frame) {
DCHECK(swap_requested);
- result.did_request_swap = impl().layer_tree_host_impl->SwapBuffers(frame);
+ bool did_request_swap = impl().layer_tree_host_impl->SwapBuffers(frame);
// We don't know if we have incomplete tiles if we didn't actually swap.
- if (result.did_request_swap) {
+ if (did_request_swap) {
DCHECK(!frame.has_no_damage);
SetSwapUsedIncompleteTileOnImplThread(frame.contains_incomplete_tile);
}
« cc/scheduler/scheduler.cc ('K') | « cc/scheduler/scheduler_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698