Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1957)

Unified Diff: content/renderer/renderer_webkitplatformsupport_impl.h

Issue 286793002: [DeviceLight] Add renderer+common parts (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/renderer/renderer_webkitplatformsupport_impl.h
diff --git a/content/renderer/renderer_webkitplatformsupport_impl.h b/content/renderer/renderer_webkitplatformsupport_impl.h
index 36416118379f12989fd1a2caa840221bfdf1c1c3..e3054378b44a215a86c985924b84789bf8631e77 100644
--- a/content/renderer/renderer_webkitplatformsupport_impl.h
+++ b/content/renderer/renderer_webkitplatformsupport_impl.h
@@ -36,6 +36,7 @@ class WebScreenOrientationListener;
namespace content {
class BatteryStatusDispatcher;
+class DeviceLightEventPump;
class DeviceMotionEventPump;
class DeviceOrientationEventPump;
class QuotaMessageFilter;
@@ -135,6 +136,8 @@ 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) OVERRIDE;
virtual void setDeviceMotionListener(
blink::WebDeviceMotionListener* listener) OVERRIDE;
virtual void setDeviceOrientationListener(
@@ -172,6 +175,9 @@ class CONTENT_EXPORT RendererWebKitPlatformSupportImpl
// a listener has been set via setGamepadListener.
static void MockGamepadDisconnected(int index, const blink::WebGamepad& pad);
+ // when setDeviceMotionListener is invoked, return a double value
+ static void SetMockDeviceLightDataForTesting(
+ double& data);
// Set WebDeviceMotionData to return when setDeviceMotionListener is invoked.
static void SetMockDeviceMotionDataForTesting(
const blink::WebDeviceMotionData& data);
@@ -219,6 +225,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_;

Powered by Google App Engine
This is Rietveld 408576698