- From: Matt Reynolds <notifications@github.com>
 - Date: Thu, 11 Jul 2024 12:59:21 -0700
 - To: w3c/gamepad <gamepad@noreply.github.com>
 - Cc: Subscribed <subscribed@noreply.github.com>
 - Message-ID: <w3c/gamepad/pull/196/review/2172908376@github.com>
 
@nondebug commented on this pull request.
> @@ -878,8 +881,17 @@ <h3>
           <li>Initialize |buttons| to be an empty [=list=].
           </li>
           <li>[=list/For each=] |buttonIndex:long| of [=the range=] from 0 to
-          |buttonsSize| − 1, [=list/append=] a [=new=] {{GamepadButton}} to
-          |buttons|.
+          |buttonsSize| − 1:
+            <ol>
+              <li>Let |button:GamepadButton| be a [=new=] {{GamepadButton}} with its
+              {{GamepadButton/type}} attribute initialized to |type|,
+              button.value initialized to 0,
+              button.pressed initialized to false, and
+              button.touched initialized to false.
Let's use the same button.attr syntax for all four attributes and reorder them to match the order in the GamepadButton interface definition:
```
              <li>Let |button:GamepadButton| be a [=new=] {{GamepadButton}} with
              |button|.{{GamepadButton/pressed}} initialized to `false`,
              |button|.{{GamepadButton/touched}} initialized to `false`,
              |button|.{{GamepadButton/type}} initialized to |type|, and
              |button|.{{GamepadButton/value}} initialized to 0.
              </li>
```
-- 
Reply to this email directly or view it on GitHub:
https://github.com/w3c/gamepad/pull/196#pullrequestreview-2172908376
You are receiving this because you are subscribed to this thread.
Message ID: <w3c/gamepad/pull/196/review/2172908376@github.com>
Received on Thursday, 11 July 2024 19:59:24 UTC