Re: [w3c/gamepad] Spec liveness of Gamepad and GamepadButton objects (#8) (#123)

nondebug commented on this pull request.



> +          Zero-based index of the gamepad in the {{Navigator}}. The index
+          MUST NOT change once the Gamepad object has been returned to script.
+          </p>
+          <p>
+          When the system is notified that a gamepad has been connected,
+          its index attribute MUST be assigned to the lowest index that is not
+          assigned to any currently connected gamepad, starting at zero.
+          </p>
+          <p>
+          When the system is notified that a previously connected gamepad has
+          become unavailable, the `index` attribute of other gamepads MUST NOT
+          be reassigned. However, if a gamepad is disconnected, and
+          subsequently the same or a different gamepad is connected, the
+          lowest previously used index MUST be assigned to the newly connected
+          gamepad.
+          </p>

I added the example but renamed pad1,pad2,pad3 -> padA,padB,padC for clarity

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/gamepad/pull/123#discussion_r348859229

Received on Thursday, 21 November 2019 01:35:53 UTC