| Index: components/test_runner/gamepad_controller.cc
|
| diff --git a/components/test_runner/gamepad_controller.cc b/components/test_runner/gamepad_controller.cc
|
| index 18c2fa46aceec90c1b5fb185655a3e02c459fe49..a30e22182c97eacb363d593fe9f4adce537ad43c 100644
|
| --- a/components/test_runner/gamepad_controller.cc
|
| +++ b/components/test_runner/gamepad_controller.cc
|
| @@ -178,11 +178,6 @@ void GamepadController::Connect(int index) {
|
| if (index < 0 || index >= static_cast<int>(WebGamepads::itemsLengthCap))
|
| return;
|
| gamepads_.items[index].connected = true;
|
| - gamepads_.length = 0;
|
| - for (unsigned i = 0; i < WebGamepads::itemsLengthCap; ++i) {
|
| - if (gamepads_.items[i].connected)
|
| - gamepads_.length = i + 1;
|
| - }
|
| }
|
|
|
| void GamepadController::DispatchConnected(int index) {
|
| @@ -199,11 +194,6 @@ void GamepadController::Disconnect(int index) {
|
| return;
|
| WebGamepad& pad = gamepads_.items[index];
|
| pad.connected = false;
|
| - gamepads_.length = 0;
|
| - for (unsigned i = 0; i < WebGamepads::itemsLengthCap; ++i) {
|
| - if (gamepads_.items[i].connected)
|
| - gamepads_.length = i + 1;
|
| - }
|
| if (listener_)
|
| listener_->didDisconnectGamepad(index, pad);
|
| }
|
|
|