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

Side by Side Diff: cc/scheduler/scheduler_state_machine.cc

Issue 342413005: Revert of Make SingleThreadProxy a SchedulerClient (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 5 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/scheduler/scheduler.cc ('k') | cc/test/fake_layer_tree_host_client.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/scheduler/scheduler_state_machine.h" 5 #include "cc/scheduler/scheduler_state_machine.h"
6 6
7 #include "base/debug/trace_event.h" 7 #include "base/debug/trace_event.h"
8 #include "base/format_macros.h" 8 #include "base/format_macros.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/strings/stringprintf.h" 10 #include "base/strings/stringprintf.h"
(...skipping 988 matching lines...) Expand 10 before | Expand all | Expand 10 after
999 case DRAW_ABORTED_MISSING_HIGH_RES_CONTENT: 999 case DRAW_ABORTED_MISSING_HIGH_RES_CONTENT:
1000 // It's not clear whether this missing content is because of missing 1000 // It's not clear whether this missing content is because of missing
1001 // pictures (which requires a commit) or because of memory pressure 1001 // pictures (which requires a commit) or because of memory pressure
1002 // removing textures (which might not). To be safe, request a commit 1002 // removing textures (which might not). To be safe, request a commit
1003 // anyway. 1003 // anyway.
1004 needs_commit_ = true; 1004 needs_commit_ = true;
1005 break; 1005 break;
1006 } 1006 }
1007 } 1007 }
1008 1008
1009 void SchedulerStateMachine::SetNeedsCommit() { 1009 void SchedulerStateMachine::SetNeedsCommit() { needs_commit_ = true; }
1010 needs_commit_ = true;
1011 }
1012 1010
1013 void SchedulerStateMachine::NotifyReadyToCommit() { 1011 void SchedulerStateMachine::NotifyReadyToCommit() {
1014 DCHECK(commit_state_ == COMMIT_STATE_BEGIN_MAIN_FRAME_STARTED) << *AsValue(); 1012 DCHECK(commit_state_ == COMMIT_STATE_BEGIN_MAIN_FRAME_STARTED) << *AsValue();
1015 commit_state_ = COMMIT_STATE_READY_TO_COMMIT; 1013 commit_state_ = COMMIT_STATE_READY_TO_COMMIT;
1016 } 1014 }
1017 1015
1018 void SchedulerStateMachine::BeginMainFrameAborted(bool did_handle) { 1016 void SchedulerStateMachine::BeginMainFrameAborted(bool did_handle) {
1019 DCHECK_EQ(commit_state_, COMMIT_STATE_BEGIN_MAIN_FRAME_SENT); 1017 DCHECK_EQ(commit_state_, COMMIT_STATE_BEGIN_MAIN_FRAME_SENT);
1020 if (did_handle) { 1018 if (did_handle) {
1021 bool commit_was_aborted = true; 1019 bool commit_was_aborted = true;
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
1072 case OUTPUT_SURFACE_ACTIVE: 1070 case OUTPUT_SURFACE_ACTIVE:
1073 case OUTPUT_SURFACE_WAITING_FOR_FIRST_COMMIT: 1071 case OUTPUT_SURFACE_WAITING_FOR_FIRST_COMMIT:
1074 case OUTPUT_SURFACE_WAITING_FOR_FIRST_ACTIVATION: 1072 case OUTPUT_SURFACE_WAITING_FOR_FIRST_ACTIVATION:
1075 return true; 1073 return true;
1076 } 1074 }
1077 NOTREACHED(); 1075 NOTREACHED();
1078 return false; 1076 return false;
1079 } 1077 }
1080 1078
1081 } // namespace cc 1079 } // namespace cc
OLDNEW
« no previous file with comments | « cc/scheduler/scheduler.cc ('k') | cc/test/fake_layer_tree_host_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698