Index: content/renderer/renderer_webkitplatformsupport_impl.h |
diff --git a/content/renderer/renderer_webkitplatformsupport_impl.h b/content/renderer/renderer_webkitplatformsupport_impl.h |
index 66b269a57b84faad37263d4a6e0f3c060c2ad632..b711f1ba0ab143293322b2c85e4b83a15726d818 100644 |
--- a/content/renderer/renderer_webkitplatformsupport_impl.h |
+++ b/content/renderer/renderer_webkitplatformsupport_impl.h |
@@ -36,6 +36,7 @@ class WebGraphicsContext3DProvider; |
namespace content { |
class BatteryStatusDispatcher; |
+class DeviceLightEventPump; |
class DeviceMotionEventPump; |
class DeviceOrientationEventPump; |
class QuotaMessageFilter; |
@@ -136,6 +137,7 @@ class CONTENT_EXPORT RendererWebKitPlatformSupportImpl |
virtual blink::WebCompositorSupport* compositorSupport(); |
virtual blink::WebString convertIDNToUnicode( |
const blink::WebString& host, const blink::WebString& languages); |
+ virtual void setDeviceLightListener(blink::WebDeviceLightListener* listener); |
virtual void setDeviceMotionListener( |
blink::WebDeviceMotionListener* listener); |
virtual void setDeviceOrientationListener( |
@@ -162,6 +164,19 @@ class CONTENT_EXPORT RendererWebKitPlatformSupportImpl |
// Returns the previous |enable| value. |
static bool SetSandboxEnabledForTesting(bool enable); |
+ // Set WebGamepads to return when sampleGamepads() is invoked. |
+ static void SetMockGamepadsForTesting(const blink::WebGamepads& pads); |
jochen (gone - plz use gerrit)
2014/06/25 13:16:11
not related to this CL?
riju_
2014/06/25 15:53:11
Sorry, my mistake in rebasing. Done.
|
+ |
+ // Notifies blink::WebGamepadListener about a new gamepad if a listener |
+ // has been set via setGamepadListener. |
+ static void MockGamepadConnected(int index, const blink::WebGamepad& pad); |
+ |
+ // Notifies blink::WebGamepadListener that a gamepad has been disconnected if |
+ // a listener has been set via setGamepadListener. |
+ static void MockGamepadDisconnected(int index, const blink::WebGamepad& pad); |
+ |
+ // Set a double to return when setDeviceLightListener is invoked. |
+ static void SetMockDeviceLightDataForTesting(double data); |
jochen (gone - plz use gerrit)
2014/06/25 13:16:11
can you hook this API up to content_shell / test_r
riju_
2014/06/25 15:53:11
I have the layout support patch here.
https://code
|
// Set WebDeviceMotionData to return when setDeviceMotionListener is invoked. |
static void SetMockDeviceMotionDataForTesting( |
const blink::WebDeviceMotionData& data); |
@@ -214,6 +229,7 @@ class CONTENT_EXPORT RendererWebKitPlatformSupportImpl |
WebPublicSuffixListImpl public_suffix_list_; |
+ scoped_ptr<DeviceLightEventPump> device_light_event_pump_; |
scoped_ptr<DeviceMotionEventPump> device_motion_event_pump_; |
scoped_ptr<DeviceOrientationEventPump> device_orientation_event_pump_; |