OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 CONTENT_BROWSER_ANDROID_IN_PROCESS_SYNCHRONOUS_COMPOSITOR_IMPL_H_ | 5 #ifndef CONTENT_BROWSER_ANDROID_IN_PROCESS_SYNCHRONOUS_COMPOSITOR_IMPL_H_ |
6 #define CONTENT_BROWSER_ANDROID_IN_PROCESS_SYNCHRONOUS_COMPOSITOR_IMPL_H_ | 6 #define CONTENT_BROWSER_ANDROID_IN_PROCESS_SYNCHRONOUS_COMPOSITOR_IMPL_H_ |
7 | 7 |
| 8 #include <vector> |
| 9 |
8 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
9 #include "base/compiler_specific.h" | 11 #include "base/compiler_specific.h" |
10 #include "base/memory/scoped_ptr.h" | 12 #include "base/memory/scoped_ptr.h" |
11 #include "cc/input/layer_scroll_offset_delegate.h" | 13 #include "cc/input/layer_scroll_offset_delegate.h" |
12 #include "content/browser/android/in_process/synchronous_compositor_output_surfa
ce.h" | 14 #include "content/browser/android/in_process/synchronous_compositor_output_surfa
ce.h" |
13 #include "content/common/input/input_event_ack_state.h" | 15 #include "content/common/input/input_event_ack_state.h" |
14 #include "content/public/browser/android/synchronous_compositor.h" | 16 #include "content/public/browser/android/synchronous_compositor.h" |
15 #include "content/public/browser/web_contents_user_data.h" | 17 #include "content/public/browser/web_contents_user_data.h" |
| 18 #include "ipc/ipc_message.h" |
16 | 19 |
17 namespace cc { | 20 namespace cc { |
18 class InputHandler; | 21 class InputHandler; |
19 } | 22 } |
20 | 23 |
21 namespace blink { | 24 namespace blink { |
22 class WebInputEvent; | 25 class WebInputEvent; |
23 } | 26 } |
24 | 27 |
25 namespace content { | 28 namespace content { |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
86 void SetInputHandler(cc::InputHandler* input_handler); | 89 void SetInputHandler(cc::InputHandler* input_handler); |
87 void DidOverscroll(const DidOverscrollParams& params); | 90 void DidOverscroll(const DidOverscrollParams& params); |
88 void DidStopFlinging(); | 91 void DidStopFlinging(); |
89 | 92 |
90 private: | 93 private: |
91 explicit SynchronousCompositorImpl(WebContents* contents); | 94 explicit SynchronousCompositorImpl(WebContents* contents); |
92 virtual ~SynchronousCompositorImpl(); | 95 virtual ~SynchronousCompositorImpl(); |
93 friend class WebContentsUserData<SynchronousCompositorImpl>; | 96 friend class WebContentsUserData<SynchronousCompositorImpl>; |
94 | 97 |
95 void UpdateFrameMetaData(const cc::CompositorFrameMetadata& frame_info); | 98 void UpdateFrameMetaData(const cc::CompositorFrameMetadata& frame_info); |
| 99 void DeliverMessages(); |
96 bool CalledOnValidThread() const; | 100 bool CalledOnValidThread() const; |
97 | 101 |
98 SynchronousCompositorClient* compositor_client_; | 102 SynchronousCompositorClient* compositor_client_; |
99 SynchronousCompositorOutputSurface* output_surface_; | 103 SynchronousCompositorOutputSurface* output_surface_; |
100 WebContents* contents_; | 104 WebContents* contents_; |
101 cc::InputHandler* input_handler_; | 105 cc::InputHandler* input_handler_; |
102 | 106 |
103 base::WeakPtrFactory<SynchronousCompositorImpl> weak_ptr_factory_; | 107 base::WeakPtrFactory<SynchronousCompositorImpl> weak_ptr_factory_; |
104 | 108 |
105 DISALLOW_COPY_AND_ASSIGN(SynchronousCompositorImpl); | 109 DISALLOW_COPY_AND_ASSIGN(SynchronousCompositorImpl); |
106 }; | 110 }; |
107 | 111 |
108 } // namespace content | 112 } // namespace content |
109 | 113 |
110 #endif // CONTENT_BROWSER_ANDROID_IN_PROCESS_SYNCHRONOUS_COMPOSITOR_IMPL_H_ | 114 #endif // CONTENT_BROWSER_ANDROID_IN_PROCESS_SYNCHRONOUS_COMPOSITOR_IMPL_H_ |
OLD | NEW |