Removed deprecated navigator.webkitGetGamepads.

Feature has been deprecated since M35. Use navigator.getGamepads instead.

BUG=442556

Review URL: https://codereview.chromium.org/806993002

git-svn-id: svn://svn.chromium.org/blink/trunk@187406 bbb929c8-8fbe-4397-9dbb-9b2b20218538
diff --git a/third_party/WebKit/LayoutTests/fast/dom/navigator-with-content-detached-no-crash-expected.txt b/third_party/WebKit/LayoutTests/fast/dom/navigator-with-content-detached-no-crash-expected.txt
index 1869675f..2d0fbf7 100644
--- a/third_party/WebKit/LayoutTests/fast/dom/navigator-with-content-detached-no-crash-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/dom/navigator-with-content-detached-no-crash-expected.txt
@@ -1,4 +1,3 @@
-CONSOLE WARNING: 'navigator.webkitGetGamepads' is deprecated. Please use 'navigator.getGamepads' instead.
 Check if calling detached navigator's APIs is safe.
 
 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
diff --git a/third_party/WebKit/LayoutTests/gamepad/gamepad-api-expected.txt b/third_party/WebKit/LayoutTests/gamepad/gamepad-api-expected.txt
index 386781ff..c0c01c1 100644
--- a/third_party/WebKit/LayoutTests/gamepad/gamepad-api-expected.txt
+++ b/third_party/WebKit/LayoutTests/gamepad/gamepad-api-expected.txt
@@ -1,33 +1,16 @@
-CONSOLE WARNING: 'navigator.webkitGetGamepads' is deprecated. Please use 'navigator.getGamepads' instead.
 Validates the exposed Gamepad API.
 
 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
 
 
-PASS navigator.webkitGetGamepads is defined.
 PASS navigator.getGamepads is defined.
 PASS GamepadEvent is defined.
-PASS webkitGamepads.length is 4
-PASS webkitGamepads[0] is undefined.
-PASS webkitGamepads.item.__proto__ is Function.prototype
-PASS webkitGamepads.item(0) is null
 PASS gamepads.length is 4
 PASS gamepads[0] is undefined.
 PASS gamepads.item.__proto__ is Function.prototype
 PASS gamepads.item(0) is null
 PASS gamepad is non-null.
 PASS gamepad.connected is true
-PASS gamepad.__proto__ is WebKitGamepad.prototype
-PASS gamepad.id.__proto__ is String.prototype
-PASS gamepad.connected.__proto__ is Boolean.prototype
-PASS gamepad.index.__proto__ is Number.prototype
-PASS gamepad.timestamp.__proto__ is Number.prototype
-PASS gamepad.axes.__proto__ is Array.prototype
-PASS gamepad.axes[0].__proto__ is Number.prototype
-PASS gamepad.buttons.__proto__ is Array.prototype
-PASS gamepad.buttons[0].__proto__ is Number.prototype
-PASS gamepad is non-null.
-PASS gamepad.connected is true
 PASS gamepad.__proto__ is Gamepad.prototype
 PASS gamepad.id.__proto__ is String.prototype
 PASS gamepad.connected.__proto__ is Boolean.prototype
diff --git a/third_party/WebKit/LayoutTests/gamepad/gamepad-api.html b/third_party/WebKit/LayoutTests/gamepad/gamepad-api.html
index 30a082d..5eb0343 100644
--- a/third_party/WebKit/LayoutTests/gamepad/gamepad-api.html
+++ b/third_party/WebKit/LayoutTests/gamepad/gamepad-api.html
@@ -4,16 +4,9 @@
 <script>
     description("Validates the exposed Gamepad API.")
 
-    shouldBeDefined("navigator.webkitGetGamepads");
     shouldBeDefined("navigator.getGamepads");
     shouldBeDefined("GamepadEvent");
 
-    webkitGamepads = navigator.webkitGetGamepads();
-    shouldBe("webkitGamepads.length", "4");
-    shouldBeUndefined("webkitGamepads[0]");
-    shouldBe("webkitGamepads.item.__proto__", "Function.prototype")
-    shouldBeNull("webkitGamepads.item(0)");
-
     gamepads = navigator.getGamepads();
     shouldBe("gamepads.length", "4");
     shouldBeUndefined("gamepads[0]");
@@ -27,37 +20,20 @@
         gamepadController.setButtonCount(0, 1);
         gamepadController.setAxisCount(0, 1);
 
-        function checkProperties(isPrefixed) {
-            shouldBe("gamepad.id.__proto__", "String.prototype");
-            shouldBe("gamepad.connected.__proto__", "Boolean.prototype");
-            shouldBe("gamepad.index.__proto__", "Number.prototype");
-            shouldBe("gamepad.timestamp.__proto__", "Number.prototype");
-            shouldBe("gamepad.axes.__proto__", "Array.prototype");
-            shouldBe("gamepad.axes[0].__proto__", "Number.prototype");
-
-            shouldBe("gamepad.buttons.__proto__", "Array.prototype");
-            if (isPrefixed) {
-                shouldBe("gamepad.buttons[0].__proto__", "Number.prototype");
-            } else {
-                shouldBe("gamepad.buttons[0].pressed.__proto__", "Boolean.prototype");
-                shouldBe("gamepad.buttons[0].value.__proto__", "Number.prototype");
-            }
-
-            if (!isPrefixed)
-                shouldBe("gamepad.mapping.__proto__", "String.prototype");
-        }
-
-        gamepad = navigator.webkitGetGamepads()[0];
-        shouldBeNonNull("gamepad");
-        shouldBeTrue("gamepad.connected");
-        shouldBe("gamepad.__proto__", "WebKitGamepad.prototype");
-        checkProperties(true);
-
         gamepad = navigator.getGamepads()[0];
         shouldBeNonNull("gamepad");
         shouldBeTrue("gamepad.connected");
         shouldBe("gamepad.__proto__", "Gamepad.prototype");
-        checkProperties(false);
+        shouldBe("gamepad.id.__proto__", "String.prototype");
+        shouldBe("gamepad.connected.__proto__", "Boolean.prototype");
+        shouldBe("gamepad.index.__proto__", "Number.prototype");
+        shouldBe("gamepad.timestamp.__proto__", "Number.prototype");
+        shouldBe("gamepad.axes.__proto__", "Array.prototype");
+        shouldBe("gamepad.axes[0].__proto__", "Number.prototype");
+        shouldBe("gamepad.buttons.__proto__", "Array.prototype");
+        shouldBe("gamepad.buttons[0].pressed.__proto__", "Boolean.prototype");
+        shouldBe("gamepad.buttons[0].value.__proto__", "Number.prototype");
+        shouldBe("gamepad.mapping.__proto__", "String.prototype");
     }
     else
     {
diff --git a/third_party/WebKit/LayoutTests/gamepad/gamepad-polling-access-expected.txt b/third_party/WebKit/LayoutTests/gamepad/gamepad-polling-access-expected.txt
index 9d34251..15d54ce 100644
--- a/third_party/WebKit/LayoutTests/gamepad/gamepad-polling-access-expected.txt
+++ b/third_party/WebKit/LayoutTests/gamepad/gamepad-polling-access-expected.txt
@@ -1,13 +1,3 @@
-CONSOLE WARNING: 'navigator.webkitGetGamepads' is deprecated. Please use 'navigator.getGamepads' instead.
-PASS navigator.webkitGetGamepads().length is 4
-PASS navigator.webkitGetGamepads().item(0) is null
-PASS navigator.webkitGetGamepads().item(1) is null
-PASS navigator.webkitGetGamepads().item(2) is null
-PASS navigator.webkitGetGamepads().item(3) is null
-PASS navigator.webkitGetGamepads()[0] is undefined.
-PASS navigator.webkitGetGamepads()[1] is undefined.
-PASS navigator.webkitGetGamepads()[2] is undefined.
-PASS navigator.webkitGetGamepads()[3] is undefined.
 PASS navigator.getGamepads().length is 4
 PASS navigator.getGamepads().item(0) is null
 PASS navigator.getGamepads().item(1) is null
@@ -17,20 +7,9 @@
 PASS navigator.getGamepads()[1] is undefined.
 PASS navigator.getGamepads()[2] is undefined.
 PASS navigator.getGamepads()[3] is undefined.
-PASS navigator.webkitGetGamepads()[0] is non-null.
 PASS navigator.getGamepads()[0] is non-null.
-PASS navigator.webkitGetGamepads().item(0) is null
-PASS navigator.webkitGetGamepads()[0] is undefined.
 PASS navigator.getGamepads().item(0) is null
 PASS navigator.getGamepads()[0] is undefined.
-PASS navigator.webkitGetGamepads()[0].id is 'MockStick 3000'
-PASS navigator.webkitGetGamepads()[0].buttons.length is 2
-PASS navigator.webkitGetGamepads()[0].axes.length is 2
-PASS navigator.webkitGetGamepads()[0].buttons[0] is 1.0
-PASS navigator.webkitGetGamepads()[0].buttons[1] is 0.0
-PASS navigator.webkitGetGamepads()[0].axes.length is 2
-PASS navigator.webkitGetGamepads()[0].axes[0] is 0.5
-PASS navigator.webkitGetGamepads()[0].axes[1] is -1.0
 PASS navigator.getGamepads()[0].id is 'MockStick 3000'
 PASS navigator.getGamepads()[0].buttons.length is 2
 PASS navigator.getGamepads()[0].axes.length is 2
diff --git a/third_party/WebKit/LayoutTests/gamepad/gamepad-polling-access.html b/third_party/WebKit/LayoutTests/gamepad/gamepad-polling-access.html
index 00e4471..9bc59a50 100644
--- a/third_party/WebKit/LayoutTests/gamepad/gamepad-polling-access.html
+++ b/third_party/WebKit/LayoutTests/gamepad/gamepad-polling-access.html
@@ -9,16 +9,6 @@
         gamepadController.disconnect(1);
         gamepadController.disconnect(2);
         gamepadController.disconnect(3);
-        shouldBe("navigator.webkitGetGamepads().length", "4");
-        shouldBeNull("navigator.webkitGetGamepads().item(0)");
-        shouldBeNull("navigator.webkitGetGamepads().item(1)");
-        shouldBeNull("navigator.webkitGetGamepads().item(2)");
-        shouldBeNull("navigator.webkitGetGamepads().item(3)");
-        shouldBeUndefined("navigator.webkitGetGamepads()[0]");
-        shouldBeUndefined("navigator.webkitGetGamepads()[1]");
-        shouldBeUndefined("navigator.webkitGetGamepads()[2]");
-        shouldBeUndefined("navigator.webkitGetGamepads()[3]");
-
         shouldBe("navigator.getGamepads().length", "4");
         shouldBeNull("navigator.getGamepads().item(0)");
         shouldBeNull("navigator.getGamepads().item(1)");
@@ -31,11 +21,8 @@
 
         // connect and disconnect
         gamepadController.connect(0);
-        shouldBeNonNull("navigator.webkitGetGamepads()[0]");
         shouldBeNonNull("navigator.getGamepads()[0]");
         gamepadController.disconnect(0);
-        shouldBeNull("navigator.webkitGetGamepads().item(0)");
-        shouldBeUndefined("navigator.webkitGetGamepads()[0]");
         shouldBeNull("navigator.getGamepads().item(0)");
         shouldBeUndefined("navigator.getGamepads()[0]");
 
@@ -48,15 +35,6 @@
         gamepadController.setButtonData(0, 1, 0);
         gamepadController.setAxisData(0, 0, .5);
         gamepadController.setAxisData(0, 1, -1.0);
-        shouldBe("navigator.webkitGetGamepads()[0].id", "'MockStick 3000'");
-        shouldBe("navigator.webkitGetGamepads()[0].buttons.length", "2");
-        shouldBe("navigator.webkitGetGamepads()[0].axes.length", "2");
-        shouldBe("navigator.webkitGetGamepads()[0].buttons[0]", "1.0");
-        shouldBe("navigator.webkitGetGamepads()[0].buttons[1]", "0.0");
-        shouldBe("navigator.webkitGetGamepads()[0].axes.length", "2");
-        shouldBe("navigator.webkitGetGamepads()[0].axes[0]", "0.5");
-        shouldBe("navigator.webkitGetGamepads()[0].axes[1]", "-1.0");
-
         shouldBe("navigator.getGamepads()[0].id", "'MockStick 3000'");
         shouldBe("navigator.getGamepads()[0].buttons.length", "2");
         shouldBe("navigator.getGamepads()[0].axes.length", "2");
diff --git a/third_party/WebKit/LayoutTests/virtual/stable/webexposed/global-interface-listing-expected.txt b/third_party/WebKit/LayoutTests/virtual/stable/webexposed/global-interface-listing-expected.txt
index 99a85d6..6b7e810e 100644
--- a/third_party/WebKit/LayoutTests/virtual/stable/webexposed/global-interface-listing-expected.txt
+++ b/third_party/WebKit/LayoutTests/virtual/stable/webexposed/global-interface-listing-expected.txt
@@ -1121,7 +1121,6 @@
     method sendBeacon
     method unregisterProtocolHandler
     method vibrate
-    method webkitGetGamepads
     method webkitGetUserMedia
 interface Node
     attribute ATTRIBUTE_NODE
diff --git a/third_party/WebKit/LayoutTests/webexposed/global-interface-listing-expected.txt b/third_party/WebKit/LayoutTests/webexposed/global-interface-listing-expected.txt
index 565f975..3f9d4a0 100644
--- a/third_party/WebKit/LayoutTests/webexposed/global-interface-listing-expected.txt
+++ b/third_party/WebKit/LayoutTests/webexposed/global-interface-listing-expected.txt
@@ -1242,7 +1242,6 @@
     method sendBeacon
     method unregisterProtocolHandler
     method vibrate
-    method webkitGetGamepads
     method webkitGetUserMedia
 interface NetworkInformation
     method constructor
diff --git a/third_party/WebKit/Source/core/frame/UseCounter.cpp b/third_party/WebKit/Source/core/frame/UseCounter.cpp
index 48f7453f0..f9f078a 100644
--- a/third_party/WebKit/Source/core/frame/UseCounter.cpp
+++ b/third_party/WebKit/Source/core/frame/UseCounter.cpp
@@ -716,9 +716,6 @@
     case PrefixedVideoExitFullScreen:
         return "'HTMLVideoElement.webkitExitFullScreen()' is deprecated. Please use 'Document.exitFullscreen()' and 'Document.webkitExitFullscreen()' instead.";
 
-    case PrefixedGamepad:
-        return replacedBy("navigator.webkitGetGamepads", "navigator.getGamepads");
-
     case PrefixedIndexedDB:
         return replacedBy("webkitIndexedDB", "indexedDB");
 
diff --git a/third_party/WebKit/Source/core/frame/UseCounter.h b/third_party/WebKit/Source/core/frame/UseCounter.h
index 18a7ea51..26c21c68 100644
--- a/third_party/WebKit/Source/core/frame/UseCounter.h
+++ b/third_party/WebKit/Source/core/frame/UseCounter.h
@@ -270,7 +270,6 @@
         DocumentReleaseEvents = 288,
         WindowCaptureEvents = 289,
         WindowReleaseEvents = 290,
-        PrefixedGamepad = 291,
         ElementAnimateKeyframeListEffectObjectTiming = 292,
         ElementAnimateKeyframeListEffectDoubleTiming = 293,
         ElementAnimateKeyframeListEffectNoTiming = 294,
diff --git a/third_party/WebKit/Source/modules/gamepad/Gamepad.cpp b/third_party/WebKit/Source/modules/gamepad/Gamepad.cpp
index 05c65dc..7f85cbb7 100644
--- a/third_party/WebKit/Source/modules/gamepad/Gamepad.cpp
+++ b/third_party/WebKit/Source/modules/gamepad/Gamepad.cpp
@@ -29,6 +29,8 @@
 namespace blink {
 
 Gamepad::Gamepad()
+    : m_index(0)
+    , m_timestamp(0)
 {
 }
 
@@ -36,6 +38,13 @@
 {
 }
 
+void Gamepad::setAxes(unsigned count, const double* data)
+{
+    m_axes.resize(count);
+    if (count)
+        std::copy(data, data + count, m_axes.begin());
+}
+
 void Gamepad::setButtons(unsigned count, const WebGamepadButton* data)
 {
     if (m_buttons.size() != count) {
diff --git a/third_party/WebKit/Source/modules/gamepad/Gamepad.h b/third_party/WebKit/Source/modules/gamepad/Gamepad.h
index 74882a8..9ba5da26 100644
--- a/third_party/WebKit/Source/modules/gamepad/Gamepad.h
+++ b/third_party/WebKit/Source/modules/gamepad/Gamepad.h
@@ -28,13 +28,14 @@
 
 #include "bindings/core/v8/ScriptWrappable.h"
 #include "modules/gamepad/GamepadButton.h"
-#include "modules/gamepad/GamepadCommon.h"
 #include "platform/heap/Handle.h"
 #include "public/platform/WebGamepad.h"
+#include "wtf/Vector.h"
+#include "wtf/text/WTFString.h"
 
 namespace blink {
 
-class Gamepad final : public GarbageCollectedFinalized<Gamepad>, public GamepadCommon, public ScriptWrappable {
+class Gamepad final : public GarbageCollectedFinalized<Gamepad>, public ScriptWrappable {
     DEFINE_WRAPPERTYPEINFO();
 public:
     static Gamepad* create()
@@ -43,6 +44,26 @@
     }
     ~Gamepad();
 
+    typedef Vector<double> DoubleVector;
+
+    const String& id() const { return m_id; }
+    void setId(const String& id) { m_id = id; }
+
+    unsigned index() const { return m_index; }
+    void setIndex(unsigned val) { m_index = val; }
+
+    bool connected() const { return m_connected; }
+    void setConnected(bool val) { m_connected = val; }
+
+    unsigned long long timestamp() const { return m_timestamp; }
+    void setTimestamp(unsigned long long val) { m_timestamp = val; }
+
+    const String& mapping() const { return m_mapping; }
+    void setMapping(const String& val) { m_mapping = val; }
+
+    const DoubleVector& axes() const { return m_axes; }
+    void setAxes(unsigned count, const double* data);
+
     const GamepadButtonVector& buttons() const { return m_buttons; }
     void setButtons(unsigned count, const WebGamepadButton* data);
 
@@ -50,6 +71,13 @@
 
 private:
     Gamepad();
+
+    String m_id;
+    unsigned m_index;
+    bool m_connected;
+    unsigned long long m_timestamp;
+    String m_mapping;
+    DoubleVector m_axes;
     GamepadButtonVector m_buttons;
 };
 
diff --git a/third_party/WebKit/Source/modules/gamepad/GamepadCommon.cpp b/third_party/WebKit/Source/modules/gamepad/GamepadCommon.cpp
deleted file mode 100644
index cf0e7bc8..0000000
--- a/third_party/WebKit/Source/modules/gamepad/GamepadCommon.cpp
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Copyright (C) 2011, Google Inc. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
- * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
- * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
- * DAMAGE.
- */
-
-#include "config.h"
-#include "modules/gamepad/GamepadCommon.h"
-
-namespace blink {
-
-GamepadCommon::GamepadCommon()
-    : m_index(0)
-    , m_timestamp(0)
-{
-}
-
-GamepadCommon::~GamepadCommon()
-{
-}
-
-void GamepadCommon::setAxes(unsigned count, const double* data)
-{
-    m_axes.resize(count);
-    if (count)
-        std::copy(data, data + count, m_axes.begin());
-}
-
-} // namespace blink
diff --git a/third_party/WebKit/Source/modules/gamepad/GamepadCommon.h b/third_party/WebKit/Source/modules/gamepad/GamepadCommon.h
deleted file mode 100644
index 63ed176b..0000000
--- a/third_party/WebKit/Source/modules/gamepad/GamepadCommon.h
+++ /dev/null
@@ -1,70 +0,0 @@
-/*
- * Copyright (C) 2011, Google Inc. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
- * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
- * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
- * DAMAGE.
- */
-
-#ifndef GamepadCommon_h
-#define GamepadCommon_h
-
-#include "public/platform/WebGamepad.h"
-#include "wtf/Vector.h"
-#include "wtf/text/WTFString.h"
-
-namespace blink {
-
-class GamepadCommon {
-public:
-    GamepadCommon();
-    ~GamepadCommon();
-    typedef Vector<double> DoubleVector;
-
-    const String& id() const { return m_id; }
-    void setId(const String& id) { m_id = id; }
-
-    unsigned index() const { return m_index; }
-    void setIndex(unsigned val) { m_index = val; }
-
-    bool connected() const { return m_connected; }
-    void setConnected(bool val) { m_connected = val; }
-
-    unsigned long long timestamp() const { return m_timestamp; }
-    void setTimestamp(unsigned long long val) { m_timestamp = val; }
-
-    const String& mapping() const { return m_mapping; }
-    void setMapping(const String& val) { m_mapping = val; }
-
-    const DoubleVector& axes() const { return m_axes; }
-    void setAxes(unsigned count, const double* data);
-
-protected:
-    String m_id;
-    unsigned m_index;
-    bool m_connected;
-    unsigned long long m_timestamp;
-    String m_mapping;
-    DoubleVector m_axes;
-};
-
-} // namespace blink
-
-#endif // GamepadCommon_h
diff --git a/third_party/WebKit/Source/modules/gamepad/NavigatorGamepad.cpp b/third_party/WebKit/Source/modules/gamepad/NavigatorGamepad.cpp
index f0c8409..ed3ce6c 100644
--- a/third_party/WebKit/Source/modules/gamepad/NavigatorGamepad.cpp
+++ b/third_party/WebKit/Source/modules/gamepad/NavigatorGamepad.cpp
@@ -34,7 +34,6 @@
 #include "modules/gamepad/GamepadDispatcher.h"
 #include "modules/gamepad/GamepadEvent.h"
 #include "modules/gamepad/GamepadList.h"
-#include "modules/gamepad/WebKitGamepadList.h"
 
 namespace blink {
 
@@ -89,27 +88,11 @@
     return *supplement;
 }
 
-WebKitGamepadList* NavigatorGamepad::webkitGetGamepads(Navigator& navigator)
-{
-    return NavigatorGamepad::from(navigator).webkitGamepads();
-}
-
 GamepadList* NavigatorGamepad::getGamepads(Navigator& navigator)
 {
     return NavigatorGamepad::from(navigator).gamepads();
 }
 
-WebKitGamepadList* NavigatorGamepad::webkitGamepads()
-{
-    if (!m_webkitGamepads)
-        m_webkitGamepads = WebKitGamepadList::create();
-    if (window()) {
-        startUpdating();
-        sampleGamepads<WebKitGamepad>(m_webkitGamepads.get());
-    }
-    return m_webkitGamepads.get();
-}
-
 GamepadList* NavigatorGamepad::gamepads()
 {
     if (!m_gamepads)
@@ -124,7 +107,6 @@
 void NavigatorGamepad::trace(Visitor* visitor)
 {
     visitor->trace(m_gamepads);
-    visitor->trace(m_webkitGamepads);
     visitor->trace(m_pendingEvents);
     WillBeHeapSupplement<Navigator>::trace(visitor);
     DOMWindowProperty::trace(visitor);
@@ -257,7 +239,7 @@
 {
     // Inform the embedder whether it needs to provide gamepad data for us.
     bool visible = page()->visibilityState() == PageVisibilityStateVisible;
-    if (visible && (m_hasEventListener || m_gamepads || m_webkitGamepads))
+    if (visible && (m_hasEventListener || m_gamepads))
         startUpdating();
     else
         stopUpdating();
diff --git a/third_party/WebKit/Source/modules/gamepad/NavigatorGamepad.h b/third_party/WebKit/Source/modules/gamepad/NavigatorGamepad.h
index 666ca6a..80d7663 100644
--- a/third_party/WebKit/Source/modules/gamepad/NavigatorGamepad.h
+++ b/third_party/WebKit/Source/modules/gamepad/NavigatorGamepad.h
@@ -40,7 +40,6 @@
 class Gamepad;
 class GamepadList;
 class Navigator;
-class WebKitGamepadList;
 
 class NavigatorGamepad final : public NoBaseWillBeGarbageCollectedFinalized<NavigatorGamepad>, public WillBeHeapSupplement<Navigator>, public DOMWindowProperty, public PlatformEventController, public DOMWindowLifecycleObserver {
     WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(NavigatorGamepad);
@@ -49,10 +48,7 @@
     static NavigatorGamepad& from(Navigator&);
     virtual ~NavigatorGamepad();
 
-    static WebKitGamepadList* webkitGetGamepads(Navigator&);
     static GamepadList* getGamepads(Navigator&);
-
-    WebKitGamepadList* webkitGamepads();
     GamepadList* gamepads();
 
     virtual void trace(Visitor*);
@@ -84,7 +80,6 @@
     virtual void didRemoveAllEventListeners(LocalDOMWindow*) override;
 
     PersistentWillBeMember<GamepadList> m_gamepads;
-    PersistentWillBeMember<WebKitGamepadList> m_webkitGamepads;
     PersistentHeapDequeWillBeHeapDeque<Member<Gamepad> > m_pendingEvents;
     AsyncMethodRunner<NavigatorGamepad> m_dispatchOneEventRunner;
 };
diff --git a/third_party/WebKit/Source/modules/gamepad/NavigatorGamepad.idl b/third_party/WebKit/Source/modules/gamepad/NavigatorGamepad.idl
index 74fc98d..a854d793 100644
--- a/third_party/WebKit/Source/modules/gamepad/NavigatorGamepad.idl
+++ b/third_party/WebKit/Source/modules/gamepad/NavigatorGamepad.idl
@@ -18,6 +18,5 @@
  */
 
 partial interface Navigator {
-    [DeprecateAs=PrefixedGamepad] WebKitGamepadList webkitGetGamepads();
     GamepadList getGamepads();
 };
diff --git a/third_party/WebKit/Source/modules/gamepad/WebKitGamepad.cpp b/third_party/WebKit/Source/modules/gamepad/WebKitGamepad.cpp
deleted file mode 100644
index a59e976..0000000
--- a/third_party/WebKit/Source/modules/gamepad/WebKitGamepad.cpp
+++ /dev/null
@@ -1,25 +0,0 @@
-// Copyright 2014 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "config.h"
-#include "modules/gamepad/WebKitGamepad.h"
-
-namespace blink {
-
-WebKitGamepad::WebKitGamepad()
-{
-}
-
-WebKitGamepad::~WebKitGamepad()
-{
-}
-
-void WebKitGamepad::setButtons(unsigned count, const WebGamepadButton* data)
-{
-    m_buttons.resize(count);
-    for (unsigned i = 0; i < count; ++i)
-        m_buttons[i] = data[i].value;
-}
-
-} // namespace blink
diff --git a/third_party/WebKit/Source/modules/gamepad/WebKitGamepad.h b/third_party/WebKit/Source/modules/gamepad/WebKitGamepad.h
deleted file mode 100644
index 1bf7333f..0000000
--- a/third_party/WebKit/Source/modules/gamepad/WebKitGamepad.h
+++ /dev/null
@@ -1,38 +0,0 @@
-// Copyright 2014 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef WebKitGamepad_h
-#define WebKitGamepad_h
-
-#include "bindings/core/v8/ScriptWrappable.h"
-#include "modules/gamepad/GamepadCommon.h"
-#include "platform/heap/Handle.h"
-#include "wtf/Vector.h"
-
-namespace blink {
-
-class WebKitGamepad final : public GarbageCollectedFinalized<WebKitGamepad>, public GamepadCommon, public ScriptWrappable {
-    DEFINE_WRAPPERTYPEINFO();
-public:
-    static WebKitGamepad* create()
-    {
-        return new WebKitGamepad();
-    }
-    ~WebKitGamepad();
-
-    typedef Vector<float> FloatVector;
-
-    const FloatVector& buttons() const { return m_buttons; }
-    void setButtons(unsigned count, const WebGamepadButton* data);
-
-    void trace(Visitor*) { }
-
-private:
-    WebKitGamepad();
-    FloatVector m_buttons;
-};
-
-} // namespace blink
-
-#endif // WebKitGamepad_h
diff --git a/third_party/WebKit/Source/modules/gamepad/WebKitGamepad.idl b/third_party/WebKit/Source/modules/gamepad/WebKitGamepad.idl
deleted file mode 100644
index d8d2cb2..0000000
--- a/third_party/WebKit/Source/modules/gamepad/WebKitGamepad.idl
+++ /dev/null
@@ -1,15 +0,0 @@
-// Copyright 2014 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-[
-    GarbageCollected,
-] interface WebKitGamepad {
-    readonly attribute DOMString id;
-    readonly attribute unsigned long index;
-    readonly attribute boolean connected;
-    readonly attribute unsigned long long timestamp;
-    readonly attribute DOMString mapping;
-    readonly attribute float[] axes;
-    readonly attribute float[] buttons;
-};
diff --git a/third_party/WebKit/Source/modules/gamepad/WebKitGamepadList.cpp b/third_party/WebKit/Source/modules/gamepad/WebKitGamepadList.cpp
deleted file mode 100644
index dfe4d7b..0000000
--- a/third_party/WebKit/Source/modules/gamepad/WebKitGamepadList.cpp
+++ /dev/null
@@ -1,33 +0,0 @@
-// Copyright 2014 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "config.h"
-#include "modules/gamepad/WebKitGamepadList.h"
-
-namespace blink {
-
-WebKitGamepadList::WebKitGamepadList()
-{
-}
-
-void WebKitGamepadList::set(unsigned index, WebKitGamepad* gamepad)
-{
-    if (index >= WebGamepads::itemsLengthCap)
-        return;
-    m_items[index] = gamepad;
-}
-
-WebKitGamepad* WebKitGamepadList::item(unsigned index)
-{
-    return index < length() ? m_items[index].get() : 0;
-}
-
-void WebKitGamepadList::trace(Visitor* visitor)
-{
-    for (unsigned index = 0; index < WebGamepads::itemsLengthCap; index++) {
-        visitor->trace(m_items[index]);
-    }
-}
-
-} // namespace blink
diff --git a/third_party/WebKit/Source/modules/gamepad/WebKitGamepadList.h b/third_party/WebKit/Source/modules/gamepad/WebKitGamepadList.h
deleted file mode 100644
index 5a5a024..0000000
--- a/third_party/WebKit/Source/modules/gamepad/WebKitGamepadList.h
+++ /dev/null
@@ -1,36 +0,0 @@
-// Copyright 2014 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef WebKitGamepadList_h
-#define WebKitGamepadList_h
-
-#include "bindings/core/v8/ScriptWrappable.h"
-#include "modules/gamepad/WebKitGamepad.h"
-#include "platform/heap/Handle.h"
-#include "public/platform/WebGamepads.h"
-
-namespace blink {
-
-class WebKitGamepadList final : public GarbageCollected<WebKitGamepadList>, public ScriptWrappable {
-    DEFINE_WRAPPERTYPEINFO();
-public:
-    static WebKitGamepadList* create()
-    {
-        return new WebKitGamepadList;
-    }
-
-    void set(unsigned index, WebKitGamepad*);
-    WebKitGamepad* item(unsigned index);
-    unsigned length() const { return WebGamepads::itemsLengthCap; }
-
-    void trace(Visitor*);
-
-private:
-    WebKitGamepadList();
-    Member<WebKitGamepad> m_items[WebGamepads::itemsLengthCap];
-};
-
-} // namespace blink
-
-#endif // WebKitGamepadList_h
diff --git a/third_party/WebKit/Source/modules/gamepad/WebKitGamepadList.idl b/third_party/WebKit/Source/modules/gamepad/WebKitGamepadList.idl
deleted file mode 100644
index 2b35c565c..0000000
--- a/third_party/WebKit/Source/modules/gamepad/WebKitGamepadList.idl
+++ /dev/null
@@ -1,11 +0,0 @@
-// Copyright 2014 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-[
-    NoInterfaceObject,
-    GarbageCollected,
-] interface WebKitGamepadList {
-    readonly attribute unsigned long length;
-    getter WebKitGamepad item([Default=Undefined] optional unsigned long index);
-};
diff --git a/third_party/WebKit/Source/modules/modules.gypi b/third_party/WebKit/Source/modules/modules.gypi
index b81e78cf..92a2fd7e 100644
--- a/third_party/WebKit/Source/modules/modules.gypi
+++ b/third_party/WebKit/Source/modules/modules.gypi
@@ -65,8 +65,6 @@
       'gamepad/GamepadButton.idl',
       'gamepad/GamepadEvent.idl',
       'gamepad/GamepadList.idl',
-      'gamepad/WebKitGamepad.idl',
-      'gamepad/WebKitGamepadList.idl',
       'geofencing/CircularGeofencingRegion.idl',
       'geofencing/Geofencing.idl',
       'geofencing/GeofencingEvent.idl',
@@ -659,8 +657,6 @@
       'gamepad/Gamepad.h',
       'gamepad/GamepadButton.cpp',
       'gamepad/GamepadButton.h',
-      'gamepad/GamepadCommon.cpp',
-      'gamepad/GamepadCommon.h',
       'gamepad/GamepadDispatcher.cpp',
       'gamepad/GamepadDispatcher.h',
       'gamepad/GamepadEvent.cpp',
@@ -669,10 +665,6 @@
       'gamepad/GamepadList.h',
       'gamepad/NavigatorGamepad.cpp',
       'gamepad/NavigatorGamepad.h',
-      'gamepad/WebKitGamepad.cpp',
-      'gamepad/WebKitGamepad.h',
-      'gamepad/WebKitGamepadList.cpp',
-      'gamepad/WebKitGamepadList.h',
       'geofencing/CircularGeofencingRegion.cpp',
       'geofencing/CircularGeofencingRegion.h',
       'geofencing/Geofencing.cpp',