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_TREES_THREAD_PROXY_H_ | 5 #ifndef CC_TREES_THREAD_PROXY_H_ |
6 #define CC_TREES_THREAD_PROXY_H_ | 6 #define CC_TREES_THREAD_PROXY_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
80 virtual void NotifyReadyToActivate() OVERRIDE; | 80 virtual void NotifyReadyToActivate() OVERRIDE; |
81 // Please call these 2 functions through | 81 // Please call these 2 functions through |
82 // LayerTreeHostImpl's SetNeedsRedraw() and SetNeedsRedrawRect(). | 82 // LayerTreeHostImpl's SetNeedsRedraw() and SetNeedsRedrawRect(). |
83 virtual void SetNeedsRedrawOnImplThread() OVERRIDE; | 83 virtual void SetNeedsRedrawOnImplThread() OVERRIDE; |
84 virtual void SetNeedsRedrawRectOnImplThread(const gfx::Rect& dirty_rect) | 84 virtual void SetNeedsRedrawRectOnImplThread(const gfx::Rect& dirty_rect) |
85 OVERRIDE; | 85 OVERRIDE; |
86 virtual void SetNeedsManageTilesOnImplThread() OVERRIDE; | 86 virtual void SetNeedsManageTilesOnImplThread() OVERRIDE; |
87 virtual void DidInitializeVisibleTileOnImplThread() OVERRIDE; | 87 virtual void DidInitializeVisibleTileOnImplThread() OVERRIDE; |
88 virtual void SetNeedsCommitOnImplThread() OVERRIDE; | 88 virtual void SetNeedsCommitOnImplThread() OVERRIDE; |
89 virtual void PostAnimationEventsToMainThreadOnImplThread( | 89 virtual void PostAnimationEventsToMainThreadOnImplThread( |
90 scoped_ptr<AnimationEventsVector> queue, | 90 scoped_ptr<AnimationEventsVector> queue) OVERRIDE; |
91 base::Time wall_clock_time) OVERRIDE; | |
92 virtual bool ReduceContentsTextureMemoryOnImplThread(size_t limit_bytes, | 91 virtual bool ReduceContentsTextureMemoryOnImplThread(size_t limit_bytes, |
93 int priority_cutoff) | 92 int priority_cutoff) |
94 OVERRIDE; | 93 OVERRIDE; |
95 virtual void SendManagedMemoryStats() OVERRIDE; | 94 virtual void SendManagedMemoryStats() OVERRIDE; |
96 virtual bool IsInsideDraw() OVERRIDE; | 95 virtual bool IsInsideDraw() OVERRIDE; |
97 virtual void RenewTreePriority() OVERRIDE; | 96 virtual void RenewTreePriority() OVERRIDE; |
98 virtual void RequestScrollbarAnimationOnImplThread(base::TimeDelta delay) | 97 virtual void RequestScrollbarAnimationOnImplThread(base::TimeDelta delay) |
99 OVERRIDE; | 98 OVERRIDE; |
100 virtual void DidActivatePendingTree() OVERRIDE; | 99 virtual void DidActivatePendingTree() OVERRIDE; |
101 virtual void DidManageTiles() OVERRIDE; | 100 virtual void DidManageTiles() OVERRIDE; |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
139 bool evicted_ui_resources; | 138 bool evicted_ui_resources; |
140 }; | 139 }; |
141 | 140 |
142 // Called on main thread. | 141 // Called on main thread. |
143 void SetRendererCapabilitiesMainThreadCopy( | 142 void SetRendererCapabilitiesMainThreadCopy( |
144 const RendererCapabilities& capabilities); | 143 const RendererCapabilities& capabilities); |
145 void BeginMainFrame( | 144 void BeginMainFrame( |
146 scoped_ptr<BeginMainFrameAndCommitState> begin_main_frame_state); | 145 scoped_ptr<BeginMainFrameAndCommitState> begin_main_frame_state); |
147 void DidCommitAndDrawFrame(); | 146 void DidCommitAndDrawFrame(); |
148 void DidCompleteSwapBuffers(); | 147 void DidCompleteSwapBuffers(); |
149 void SetAnimationEvents(scoped_ptr<AnimationEventsVector> queue, | 148 void SetAnimationEvents(scoped_ptr<AnimationEventsVector> queue); |
150 base::Time wall_clock_time); | |
151 void DoCreateAndInitializeOutputSurface(); | 149 void DoCreateAndInitializeOutputSurface(); |
152 // |capabilities| is set only when |success| is true. | 150 // |capabilities| is set only when |success| is true. |
153 void OnOutputSurfaceInitializeAttempted( | 151 void OnOutputSurfaceInitializeAttempted( |
154 bool success, | 152 bool success, |
155 const RendererCapabilities& capabilities); | 153 const RendererCapabilities& capabilities); |
156 void SendCommitRequestToImplThreadIfNeeded(); | 154 void SendCommitRequestToImplThreadIfNeeded(); |
157 | 155 |
158 // Called on impl thread. | 156 // Called on impl thread. |
159 struct ReadbackRequest; | 157 struct ReadbackRequest; |
160 struct CommitPendingRequest; | 158 struct CommitPendingRequest; |
(...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
313 | 311 |
314 base::WeakPtr<ThreadProxy> main_thread_weak_ptr_; | 312 base::WeakPtr<ThreadProxy> main_thread_weak_ptr_; |
315 base::WeakPtr<ThreadProxy> impl_thread_weak_ptr_; | 313 base::WeakPtr<ThreadProxy> impl_thread_weak_ptr_; |
316 | 314 |
317 DISALLOW_COPY_AND_ASSIGN(ThreadProxy); | 315 DISALLOW_COPY_AND_ASSIGN(ThreadProxy); |
318 }; | 316 }; |
319 | 317 |
320 } // namespace cc | 318 } // namespace cc |
321 | 319 |
322 #endif // CC_TREES_THREAD_PROXY_H_ | 320 #endif // CC_TREES_THREAD_PROXY_H_ |
OLD | NEW |