OLD | NEW |
---|---|
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 ANDROID_WEBVIEW_BROWSER_SHARED_RENDERER_STATE_H_ | 5 #ifndef ANDROID_WEBVIEW_BROWSER_SHARED_RENDERER_STATE_H_ |
6 #define ANDROID_WEBVIEW_BROWSER_SHARED_RENDERER_STATE_H_ | 6 #define ANDROID_WEBVIEW_BROWSER_SHARED_RENDERER_STATE_H_ |
7 | 7 |
8 #include "android_webview/browser/gl_view_renderer_manager.h" | 8 #include "android_webview/browser/gl_view_renderer_manager.h" |
9 #include "android_webview/browser/parent_compositor_draw_constraints.h" | 9 #include "android_webview/browser/parent_compositor_draw_constraints.h" |
10 #include "base/cancelable_callback.h" | 10 #include "base/cancelable_callback.h" |
(...skipping 30 matching lines...) Expand all Loading... | |
41 | 41 |
42 // UI thread methods. | 42 // UI thread methods. |
43 void SetScrollOffsetOnUI(gfx::Vector2d scroll_offset); | 43 void SetScrollOffsetOnUI(gfx::Vector2d scroll_offset); |
44 void SetCompositorFrameOnUI(scoped_ptr<ChildFrame> frame); | 44 void SetCompositorFrameOnUI(scoped_ptr<ChildFrame> frame); |
45 void InitializeHardwareDrawIfNeededOnUI(); | 45 void InitializeHardwareDrawIfNeededOnUI(); |
46 void ReleaseHardwareDrawIfNeededOnUI(); | 46 void ReleaseHardwareDrawIfNeededOnUI(); |
47 ParentCompositorDrawConstraints GetParentDrawConstraintsOnUI() const; | 47 ParentCompositorDrawConstraints GetParentDrawConstraintsOnUI() const; |
48 void SwapReturnedResourcesOnUI(cc::ReturnedResourceArray* resources); | 48 void SwapReturnedResourcesOnUI(cc::ReturnedResourceArray* resources); |
49 bool ReturnedResourcesEmptyOnUI() const; | 49 bool ReturnedResourcesEmptyOnUI() const; |
50 scoped_ptr<ChildFrame> PassUncommittedFrameOnUI(); | 50 scoped_ptr<ChildFrame> PassUncommittedFrameOnUI(); |
51 void DeleteHardwareRendererOnUI(); | |
52 void ReleaseCompositorResourcesIfNeededOnUI(bool keep_child_compositor_tiles); | |
boliu
2015/04/16 01:58:40
private
hush (inactive)
2015/04/16 04:06:25
Done.
| |
51 | 53 |
52 // RT thread methods. | 54 // RT thread methods. |
53 gfx::Vector2d GetScrollOffsetOnRT(); | 55 gfx::Vector2d GetScrollOffsetOnRT(); |
54 scoped_ptr<ChildFrame> PassCompositorFrameOnRT(); | 56 scoped_ptr<ChildFrame> PassCompositorFrameOnRT(); |
55 void DrawGL(AwDrawGLInfo* draw_info); | 57 void DrawGL(AwDrawGLInfo* draw_info); |
56 void PostExternalDrawConstraintsToChildCompositorOnRT( | 58 void PostExternalDrawConstraintsToChildCompositorOnRT( |
57 const ParentCompositorDrawConstraints& parent_draw_constraints); | 59 const ParentCompositorDrawConstraints& parent_draw_constraints); |
58 void InsertReturnedResourcesOnRT(const cc::ReturnedResourceArray& resources); | 60 void InsertReturnedResourcesOnRT(const cc::ReturnedResourceArray& resources); |
59 | 61 |
60 private: | 62 private: |
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
101 base::Closure request_draw_gl_closure_; | 103 base::Closure request_draw_gl_closure_; |
102 | 104 |
103 base::WeakPtrFactory<SharedRendererState> weak_factory_on_ui_thread_; | 105 base::WeakPtrFactory<SharedRendererState> weak_factory_on_ui_thread_; |
104 | 106 |
105 DISALLOW_COPY_AND_ASSIGN(SharedRendererState); | 107 DISALLOW_COPY_AND_ASSIGN(SharedRendererState); |
106 }; | 108 }; |
107 | 109 |
108 } // namespace android_webview | 110 } // namespace android_webview |
109 | 111 |
110 #endif // ANDROID_WEBVIEW_BROWSER_SHARED_RENDERER_STATE_H_ | 112 #endif // ANDROID_WEBVIEW_BROWSER_SHARED_RENDERER_STATE_H_ |
OLD | NEW |