Index: Source/modules/gamepad/NavigatorGamepad.h |
diff --git a/Source/modules/gamepad/NavigatorGamepad.h b/Source/modules/gamepad/NavigatorGamepad.h |
index 0de60e243802ca9260f0b41096ec7b8a3896e46a..07509508fd3a1755198eafe64060fbea7b46b45e 100644 |
--- a/Source/modules/gamepad/NavigatorGamepad.h |
+++ b/Source/modules/gamepad/NavigatorGamepad.h |
@@ -26,17 +26,24 @@ |
#ifndef NavigatorGamepad_h |
#define NavigatorGamepad_h |
+#include "core/frame/DOMWindowLifecycleObserver.h" |
+#include "core/frame/DOMWindowProperty.h" |
abarth-chromium
2014/03/19 18:00:33
Looks like you don't need this include.
|
#include "heap/Handle.h" |
#include "platform/Supplementable.h" |
#include "public/platform/WebGamepads.h" |
+namespace blink { |
+class WebGamepad; |
+class WebGamepads; |
+} |
+ |
namespace WebCore { |
class GamepadList; |
class Navigator; |
class WebKitGamepadList; |
-class NavigatorGamepad FINAL : public Supplement<Navigator> { |
+class NavigatorGamepad FINAL : public Supplement<Navigator>, public DOMWindowLifecycleObserver { |
public: |
virtual ~NavigatorGamepad(); |
static NavigatorGamepad& from(Navigator&); |
@@ -47,8 +54,13 @@ public: |
WebKitGamepadList* webkitGamepads(); |
GamepadList* gamepads(); |
+ void didConnectGamepad(unsigned index, const blink::WebGamepad&); |
+ void didDisconnectGamepad(unsigned index, const blink::WebGamepad&); |
+ |
+ virtual void didAddEventListener(DOMWindow*, const AtomicString&) OVERRIDE; |
+ |
private: |
- NavigatorGamepad(); |
+ explicit NavigatorGamepad(LocalFrame*); |
static const char* supplementName(); |
RefPtrWillBePersistent<GamepadList> m_gamepads; |