OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_RENDERER_RENDERER_WEBKITPLATFORMSUPPORT_IMPL_H_ | 5 #ifndef CONTENT_RENDERER_RENDERER_WEBKITPLATFORMSUPPORT_IMPL_H_ |
6 #define CONTENT_RENDERER_RENDERER_WEBKITPLATFORMSUPPORT_IMPL_H_ | 6 #define CONTENT_RENDERER_RENDERER_WEBKITPLATFORMSUPPORT_IMPL_H_ |
7 | 7 |
8 #include "base/compiler_specific.h" | 8 #include "base/compiler_specific.h" |
9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
10 #include "content/child/blink_platform_impl.h" | 10 #include "content/child/blink_platform_impl.h" |
(...skipping 19 matching lines...) Expand all Loading... |
30 namespace blink { | 30 namespace blink { |
31 class WebBatteryStatus; | 31 class WebBatteryStatus; |
32 class WebDeviceMotionData; | 32 class WebDeviceMotionData; |
33 class WebDeviceOrientationData; | 33 class WebDeviceOrientationData; |
34 class WebGraphicsContext3DProvider; | 34 class WebGraphicsContext3DProvider; |
35 class WebScreenOrientationListener; | 35 class WebScreenOrientationListener; |
36 } | 36 } |
37 | 37 |
38 namespace content { | 38 namespace content { |
39 class BatteryStatusDispatcher; | 39 class BatteryStatusDispatcher; |
| 40 class DeviceLightEventPump; |
40 class DeviceMotionEventPump; | 41 class DeviceMotionEventPump; |
41 class DeviceOrientationEventPump; | 42 class DeviceOrientationEventPump; |
42 class QuotaMessageFilter; | 43 class QuotaMessageFilter; |
43 class RendererClipboardClient; | 44 class RendererClipboardClient; |
44 class ScreenOrientationDispatcher; | 45 class ScreenOrientationDispatcher; |
45 class ThreadSafeSender; | 46 class ThreadSafeSender; |
46 class WebClipboardImpl; | 47 class WebClipboardImpl; |
47 class WebDatabaseObserverImpl; | 48 class WebDatabaseObserverImpl; |
48 class WebFileSystemImpl; | 49 class WebFileSystemImpl; |
49 | 50 |
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
129 virtual blink::WebGraphicsContext3D* createOffscreenGraphicsContext3D( | 130 virtual blink::WebGraphicsContext3D* createOffscreenGraphicsContext3D( |
130 const blink::WebGraphicsContext3D::Attributes& attributes); | 131 const blink::WebGraphicsContext3D::Attributes& attributes); |
131 virtual blink::WebGraphicsContext3D* createOffscreenGraphicsContext3D( | 132 virtual blink::WebGraphicsContext3D* createOffscreenGraphicsContext3D( |
132 const blink::WebGraphicsContext3D::Attributes& attributes, | 133 const blink::WebGraphicsContext3D::Attributes& attributes, |
133 blink::WebGraphicsContext3D* share_context); | 134 blink::WebGraphicsContext3D* share_context); |
134 virtual blink::WebGraphicsContext3DProvider* | 135 virtual blink::WebGraphicsContext3DProvider* |
135 createSharedOffscreenGraphicsContext3DProvider(); | 136 createSharedOffscreenGraphicsContext3DProvider(); |
136 virtual blink::WebCompositorSupport* compositorSupport(); | 137 virtual blink::WebCompositorSupport* compositorSupport(); |
137 virtual blink::WebString convertIDNToUnicode( | 138 virtual blink::WebString convertIDNToUnicode( |
138 const blink::WebString& host, const blink::WebString& languages); | 139 const blink::WebString& host, const blink::WebString& languages); |
| 140 virtual void setDeviceLightListener( |
| 141 blink::WebDeviceLightListener* listener) OVERRIDE; |
139 virtual void setDeviceMotionListener( | 142 virtual void setDeviceMotionListener( |
140 blink::WebDeviceMotionListener* listener); | 143 blink::WebDeviceMotionListener* listener); |
141 virtual void setDeviceOrientationListener( | 144 virtual void setDeviceOrientationListener( |
142 blink::WebDeviceOrientationListener* listener); | 145 blink::WebDeviceOrientationListener* listener); |
143 virtual void queryStorageUsageAndQuota( | 146 virtual void queryStorageUsageAndQuota( |
144 const blink::WebURL& storage_partition, | 147 const blink::WebURL& storage_partition, |
145 blink::WebStorageQuotaType, | 148 blink::WebStorageQuotaType, |
146 blink::WebStorageQuotaCallbacks); | 149 blink::WebStorageQuotaCallbacks); |
147 virtual void vibrate(unsigned int milliseconds); | 150 virtual void vibrate(unsigned int milliseconds); |
148 virtual void cancelVibration(); | 151 virtual void cancelVibration(); |
(...skipping 17 matching lines...) Expand all Loading... |
166 static void SetMockGamepadsForTesting(const blink::WebGamepads& pads); | 169 static void SetMockGamepadsForTesting(const blink::WebGamepads& pads); |
167 | 170 |
168 // Notifies blink::WebGamepadListener about a new gamepad if a listener | 171 // Notifies blink::WebGamepadListener about a new gamepad if a listener |
169 // has been set via setGamepadListener. | 172 // has been set via setGamepadListener. |
170 static void MockGamepadConnected(int index, const blink::WebGamepad& pad); | 173 static void MockGamepadConnected(int index, const blink::WebGamepad& pad); |
171 | 174 |
172 // Notifies blink::WebGamepadListener that a gamepad has been disconnected if | 175 // Notifies blink::WebGamepadListener that a gamepad has been disconnected if |
173 // a listener has been set via setGamepadListener. | 176 // a listener has been set via setGamepadListener. |
174 static void MockGamepadDisconnected(int index, const blink::WebGamepad& pad); | 177 static void MockGamepadDisconnected(int index, const blink::WebGamepad& pad); |
175 | 178 |
| 179 // Set a double to return when setDeviceLightListener is invoked. |
| 180 static void SetMockDeviceLightDataForTesting(double data); |
176 // Set WebDeviceMotionData to return when setDeviceMotionListener is invoked. | 181 // Set WebDeviceMotionData to return when setDeviceMotionListener is invoked. |
177 static void SetMockDeviceMotionDataForTesting( | 182 static void SetMockDeviceMotionDataForTesting( |
178 const blink::WebDeviceMotionData& data); | 183 const blink::WebDeviceMotionData& data); |
179 // Set WebDeviceOrientationData to return when setDeviceOrientationListener | 184 // Set WebDeviceOrientationData to return when setDeviceOrientationListener |
180 // is invoked. | 185 // is invoked. |
181 static void SetMockDeviceOrientationDataForTesting( | 186 static void SetMockDeviceOrientationDataForTesting( |
182 const blink::WebDeviceOrientationData& data); | 187 const blink::WebDeviceOrientationData& data); |
183 // Forces the screen orientation for testing purposes. | 188 // Forces the screen orientation for testing purposes. |
184 static void SetMockScreenOrientationForTesting( | 189 static void SetMockScreenOrientationForTesting( |
185 blink::WebScreenOrientationType); | 190 blink::WebScreenOrientationType); |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
217 | 222 |
218 // If true, then a GetPlugins call is allowed to rescan the disk. | 223 // If true, then a GetPlugins call is allowed to rescan the disk. |
219 bool plugin_refresh_allowed_; | 224 bool plugin_refresh_allowed_; |
220 | 225 |
221 scoped_ptr<blink::WebIDBFactory> web_idb_factory_; | 226 scoped_ptr<blink::WebIDBFactory> web_idb_factory_; |
222 | 227 |
223 scoped_ptr<blink::WebBlobRegistry> blob_registry_; | 228 scoped_ptr<blink::WebBlobRegistry> blob_registry_; |
224 | 229 |
225 WebPublicSuffixListImpl public_suffix_list_; | 230 WebPublicSuffixListImpl public_suffix_list_; |
226 | 231 |
| 232 scoped_ptr<DeviceLightEventPump> device_light_event_pump_; |
227 scoped_ptr<DeviceMotionEventPump> device_motion_event_pump_; | 233 scoped_ptr<DeviceMotionEventPump> device_motion_event_pump_; |
228 scoped_ptr<DeviceOrientationEventPump> device_orientation_event_pump_; | 234 scoped_ptr<DeviceOrientationEventPump> device_orientation_event_pump_; |
229 | 235 |
230 scoped_refptr<base::MessageLoopProxy> child_thread_loop_; | 236 scoped_refptr<base::MessageLoopProxy> child_thread_loop_; |
231 scoped_refptr<IPC::SyncMessageFilter> sync_message_filter_; | 237 scoped_refptr<IPC::SyncMessageFilter> sync_message_filter_; |
232 scoped_refptr<ThreadSafeSender> thread_safe_sender_; | 238 scoped_refptr<ThreadSafeSender> thread_safe_sender_; |
233 scoped_refptr<QuotaMessageFilter> quota_message_filter_; | 239 scoped_refptr<QuotaMessageFilter> quota_message_filter_; |
234 | 240 |
235 scoped_ptr<WebDatabaseObserverImpl> web_database_observer_impl_; | 241 scoped_ptr<WebDatabaseObserverImpl> web_database_observer_impl_; |
236 | 242 |
237 webkit::WebCompositorSupportImpl compositor_support_; | 243 webkit::WebCompositorSupportImpl compositor_support_; |
238 | 244 |
239 scoped_ptr<ScreenOrientationDispatcher> screen_orientation_dispatcher_; | 245 scoped_ptr<ScreenOrientationDispatcher> screen_orientation_dispatcher_; |
240 | 246 |
241 scoped_ptr<blink::WebScrollbarBehavior> web_scrollbar_behavior_; | 247 scoped_ptr<blink::WebScrollbarBehavior> web_scrollbar_behavior_; |
242 | 248 |
243 scoped_ptr<BatteryStatusDispatcher> battery_status_dispatcher_; | 249 scoped_ptr<BatteryStatusDispatcher> battery_status_dispatcher_; |
244 | 250 |
245 DISALLOW_COPY_AND_ASSIGN(RendererWebKitPlatformSupportImpl); | 251 DISALLOW_COPY_AND_ASSIGN(RendererWebKitPlatformSupportImpl); |
246 }; | 252 }; |
247 | 253 |
248 } // namespace content | 254 } // namespace content |
249 | 255 |
250 #endif // CONTENT_RENDERER_RENDERER_WEBKITPLATFORMSUPPORT_IMPL_H_ | 256 #endif // CONTENT_RENDERER_RENDERER_WEBKITPLATFORMSUPPORT_IMPL_H_ |
OLD | NEW |