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

Side by Side Diff: cc/CCSchedulerStateMachine.h

Issue 10907075: Roll cc snapshot up to 127605 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 3 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/CCScheduler.cpp ('k') | cc/CCSchedulerStateMachine.cpp » ('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 #ifndef CCSchedulerStateMachine_h 5 #ifndef CCSchedulerStateMachine_h
6 #define CCSchedulerStateMachine_h 6 #define CCSchedulerStateMachine_h
7 7
8 #include <wtf/Noncopyable.h> 8 #include <wtf/Noncopyable.h>
9 #include <wtf/text/WTFString.h>
9 10
10 namespace WebCore { 11 namespace WebCore {
11 12
12 // The CCSchedulerStateMachine decides how to coordinate main thread activites 13 // The CCSchedulerStateMachine decides how to coordinate main thread activites
13 // like painting/running javascript with rendering and input activities on the 14 // like painting/running javascript with rendering and input activities on the
14 // impl thread. 15 // impl thread.
15 // 16 //
16 // The state machine tracks internal state but is also influenced by external st ate. 17 // The state machine tracks internal state but is also influenced by external st ate.
17 // Internal state includes things like whether a frame has been requested, while 18 // Internal state includes things like whether a frame has been requested, while
18 // external state includes things like the current time being near to the vblank time. 19 // external state includes things like the current time being near to the vblank time.
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
121 // canDraw can be used to supress flashes or checkerboarding 122 // canDraw can be used to supress flashes or checkerboarding
122 // when such behavior would be undesirable. 123 // when such behavior would be undesirable.
123 void setCanDraw(bool can) { m_canDraw = can; } 124 void setCanDraw(bool can) { m_canDraw = can; }
124 125
125 void didLoseContext(); 126 void didLoseContext();
126 void didRecreateContext(); 127 void didRecreateContext();
127 128
128 // Exposed for testing purposes. 129 // Exposed for testing purposes.
129 void setMaximumNumberOfFailedDrawsBeforeDrawIsForced(int); 130 void setMaximumNumberOfFailedDrawsBeforeDrawIsForced(int);
130 131
132 String toString();
133
131 protected: 134 protected:
132 bool shouldDrawForced() const; 135 bool shouldDrawForced() const;
133 bool drawSuspendedUntilCommit() const; 136 bool drawSuspendedUntilCommit() const;
134 bool scheduledToDraw() const; 137 bool scheduledToDraw() const;
135 bool shouldDraw() const; 138 bool shouldDraw() const;
136 bool shouldAcquireLayerTexturesForMainThread() const; 139 bool shouldAcquireLayerTexturesForMainThread() const;
137 bool hasDrawnThisFrame() const; 140 bool hasDrawnThisFrame() const;
138 141
139 CommitState m_commitState; 142 CommitState m_commitState;
140 143
(...skipping 13 matching lines...) Expand all
154 bool m_canBeginFrame; 157 bool m_canBeginFrame;
155 bool m_canDraw; 158 bool m_canDraw;
156 bool m_drawIfPossibleFailed; 159 bool m_drawIfPossibleFailed;
157 TextureState m_textureState; 160 TextureState m_textureState;
158 ContextState m_contextState; 161 ContextState m_contextState;
159 }; 162 };
160 163
161 } 164 }
162 165
163 #endif // CCSchedulerStateMachine_h 166 #endif // CCSchedulerStateMachine_h
OLDNEW
« no previous file with comments | « cc/CCScheduler.cpp ('k') | cc/CCSchedulerStateMachine.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698