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

Side by Side Diff: cc/surfaces/display_scheduler.cc

Issue 2403373002: cc: Clean up OutputSurfaceClient. (Closed)
Patch Set: osclient: rebase Created 4 years, 2 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
« no previous file with comments | « cc/surfaces/display_scheduler.h ('k') | cc/surfaces/display_scheduler_unittest.cc » ('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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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/surfaces/display_scheduler.h" 5 #include "cc/surfaces/display_scheduler.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/auto_reset.h" 9 #include "base/auto_reset.h"
10 #include "base/stl_util.h" 10 #include "base/stl_util.h"
(...skipping 342 matching lines...) Expand 10 before | Expand all | Expand 10 after
353 AttemptDrawAndSwap(); 353 AttemptDrawAndSwap();
354 begin_frame_source_->DidFinishFrame(this, 0); 354 begin_frame_source_->DidFinishFrame(this, 0);
355 } 355 }
356 356
357 void DisplayScheduler::DidSwapBuffers() { 357 void DisplayScheduler::DidSwapBuffers() {
358 pending_swaps_++; 358 pending_swaps_++;
359 TRACE_EVENT_ASYNC_BEGIN1("cc", "DisplayScheduler:pending_swaps", this, 359 TRACE_EVENT_ASYNC_BEGIN1("cc", "DisplayScheduler:pending_swaps", this,
360 "pending_frames", pending_swaps_); 360 "pending_frames", pending_swaps_);
361 } 361 }
362 362
363 void DisplayScheduler::DidSwapBuffersComplete() { 363 void DisplayScheduler::DidReceiveSwapBuffersAck() {
364 pending_swaps_--; 364 pending_swaps_--;
365 TRACE_EVENT_ASYNC_END1("cc", "DisplayScheduler:pending_swaps", this, 365 TRACE_EVENT_ASYNC_END1("cc", "DisplayScheduler:pending_swaps", this,
366 "pending_frames", pending_swaps_); 366 "pending_frames", pending_swaps_);
367 ScheduleBeginFrameDeadline(); 367 ScheduleBeginFrameDeadline();
368 } 368 }
369 369
370 } // namespace cc 370 } // namespace cc
OLDNEW
« no previous file with comments | « cc/surfaces/display_scheduler.h ('k') | cc/surfaces/display_scheduler_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698