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 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
84 void SetInputHandler(cc::InputHandler* input_handler); | 87 void SetInputHandler(cc::InputHandler* input_handler); |
85 void DidOverscroll(const DidOverscrollParams& params); | 88 void DidOverscroll(const DidOverscrollParams& params); |
86 void DidStopFlinging(); | 89 void DidStopFlinging(); |
87 | 90 |
88 private: | 91 private: |
89 explicit SynchronousCompositorImpl(WebContents* contents); | 92 explicit SynchronousCompositorImpl(WebContents* contents); |
90 virtual ~SynchronousCompositorImpl(); | 93 virtual ~SynchronousCompositorImpl(); |
91 friend class WebContentsUserData<SynchronousCompositorImpl>; | 94 friend class WebContentsUserData<SynchronousCompositorImpl>; |
92 | 95 |
93 void UpdateFrameMetaData(const cc::CompositorFrameMetadata& frame_info); | 96 void UpdateFrameMetaData(const cc::CompositorFrameMetadata& frame_info); |
| 97 void DeliverMessages(); |
94 bool CalledOnValidThread() const; | 98 bool CalledOnValidThread() const; |
95 | 99 |
96 SynchronousCompositorClient* compositor_client_; | 100 SynchronousCompositorClient* compositor_client_; |
97 SynchronousCompositorOutputSurface* output_surface_; | 101 SynchronousCompositorOutputSurface* output_surface_; |
98 WebContents* contents_; | 102 WebContents* contents_; |
99 cc::InputHandler* input_handler_; | 103 cc::InputHandler* input_handler_; |
100 | 104 |
101 base::WeakPtrFactory<SynchronousCompositorImpl> weak_ptr_factory_; | 105 base::WeakPtrFactory<SynchronousCompositorImpl> weak_ptr_factory_; |
102 | 106 |
103 DISALLOW_COPY_AND_ASSIGN(SynchronousCompositorImpl); | 107 DISALLOW_COPY_AND_ASSIGN(SynchronousCompositorImpl); |
104 }; | 108 }; |
105 | 109 |
106 } // namespace content | 110 } // namespace content |
107 | 111 |
108 #endif // CONTENT_BROWSER_ANDROID_IN_PROCESS_SYNCHRONOUS_COMPOSITOR_IMPL_H_ | 112 #endif // CONTENT_BROWSER_ANDROID_IN_PROCESS_SYNCHRONOUS_COMPOSITOR_IMPL_H_ |
OLD | NEW |