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

Unified Diff: cc/scheduler/scheduler_state_machine.cc

Issue 987563002: cc: Simplify SetNeedsBeginFrames code in scheduler. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@remove_retro_frame
Patch Set: Remove dependency on retro frame removal. Created 5 years, 9 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
« no previous file with comments | « cc/scheduler/scheduler_state_machine.h ('k') | cc/scheduler/scheduler_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/scheduler/scheduler_state_machine.cc
diff --git a/cc/scheduler/scheduler_state_machine.cc b/cc/scheduler/scheduler_state_machine.cc
index 189387cf12856f1fc348c605a976d1422aaf705c..5b5b386adb506c21f5761fb2bdf3252f831db92c 100644
--- a/cc/scheduler/scheduler_state_machine.cc
+++ b/cc/scheduler/scheduler_state_machine.cc
@@ -720,29 +720,6 @@ bool SchedulerStateMachine::BeginFrameNeeded() const {
return BeginFrameNeededToAnimateOrDraw();
}
-bool SchedulerStateMachine::ShouldSetNeedsBeginFrames(
- bool frame_source_needs_begin_frames) const {
- bool needs_begin_frame = BeginFrameNeeded();
-
- // Never call SetNeedsBeginFrames if the frame source has the right value.
- if (needs_begin_frame == frame_source_needs_begin_frames)
- return false;
-
- // Always request the BeginFrame immediately if it's needed.
- if (needs_begin_frame)
- return true;
-
- // Stop requesting BeginFrames after a deadline.
- if (begin_impl_frame_state_ == BEGIN_IMPL_FRAME_STATE_INSIDE_DEADLINE)
- return true;
-
- // Stop requesting BeginFrames immediately when output surface is lost.
- if (!HasInitializedOutputSurface())
brianderson 2015/03/19 01:25:54 This condition isn't taken into account in the cod
sunnyps 2015/03/19 01:31:53 Yes, the new way of calling SetNeedsBeginFrames(fa
- return true;
-
- return false;
-}
-
bool SchedulerStateMachine::ShouldPollForAnticipatedDrawTriggers() const {
// ShouldPollForAnticipatedDrawTriggers is what we use in place of
// ProactiveBeginFrameWanted when we are using the synchronous
« no previous file with comments | « cc/scheduler/scheduler_state_machine.h ('k') | cc/scheduler/scheduler_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698