| OLD | NEW |
| 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 #ifndef CC_SCHEDULER_SCHEDULER_STATE_MACHINE_H_ | 5 #ifndef CC_SCHEDULER_SCHEDULER_STATE_MACHINE_H_ |
| 6 #define CC_SCHEDULER_SCHEDULER_STATE_MACHINE_H_ | 6 #define CC_SCHEDULER_SCHEDULER_STATE_MACHINE_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 251 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 262 // True if we need to abort draws to make forward progress. | 262 // True if we need to abort draws to make forward progress. |
| 263 bool PendingDrawsShouldBeAborted() const; | 263 bool PendingDrawsShouldBeAborted() const; |
| 264 | 264 |
| 265 bool CouldSendBeginMainFrame() const; | 265 bool CouldSendBeginMainFrame() const; |
| 266 | 266 |
| 267 void SetDeferCommits(bool defer_commits); | 267 void SetDeferCommits(bool defer_commits); |
| 268 | 268 |
| 269 void SetVideoNeedsBeginFrames(bool video_needs_begin_frames); | 269 void SetVideoNeedsBeginFrames(bool video_needs_begin_frames); |
| 270 bool video_needs_begin_frames() const { return video_needs_begin_frames_; } | 270 bool video_needs_begin_frames() const { return video_needs_begin_frames_; } |
| 271 | 271 |
| 272 bool did_submit_in_last_frame() const { return did_submit_in_last_frame_; } |
| 273 |
| 272 protected: | 274 protected: |
| 273 bool BeginFrameRequiredForAction() const; | 275 bool BeginFrameRequiredForAction() const; |
| 274 bool BeginFrameNeededForVideo() const; | 276 bool BeginFrameNeededForVideo() const; |
| 275 bool ProactiveBeginFrameWanted() const; | 277 bool ProactiveBeginFrameWanted() const; |
| 276 | 278 |
| 277 bool ShouldTriggerBeginImplFrameDeadlineImmediately() const; | 279 bool ShouldTriggerBeginImplFrameDeadlineImmediately() const; |
| 278 | 280 |
| 279 // True if we need to force activations to make forward progress. | 281 // True if we need to force activations to make forward progress. |
| 280 // TODO(sunnyps): Rename this to ShouldAbortCurrentFrame or similar. | 282 // TODO(sunnyps): Rename this to ShouldAbortCurrentFrame or similar. |
| 281 bool PendingActivationsShouldBeForced() const; | 283 bool PendingActivationsShouldBeForced() const; |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 344 bool did_draw_in_last_frame_; | 346 bool did_draw_in_last_frame_; |
| 345 bool did_submit_in_last_frame_; | 347 bool did_submit_in_last_frame_; |
| 346 | 348 |
| 347 private: | 349 private: |
| 348 DISALLOW_COPY_AND_ASSIGN(SchedulerStateMachine); | 350 DISALLOW_COPY_AND_ASSIGN(SchedulerStateMachine); |
| 349 }; | 351 }; |
| 350 | 352 |
| 351 } // namespace cc | 353 } // namespace cc |
| 352 | 354 |
| 353 #endif // CC_SCHEDULER_SCHEDULER_STATE_MACHINE_H_ | 355 #endif // CC_SCHEDULER_SCHEDULER_STATE_MACHINE_H_ |
| OLD | NEW |