Skip to content

Commit

Permalink
Add GamepadSurface
Browse files Browse the repository at this point in the history
  • Loading branch information
bradleyneedham committed Jul 10, 2024
1 parent 349a9e4 commit 926ef0f
Showing 1 changed file with 28 additions and 8 deletions.
36 changes: 28 additions & 8 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -1182,9 +1182,7 @@ <h2>
[Exposed=Window, SecureContext]
dictionary GamepadTouch {
unsigned long touchId;
octet surfaceId;
Float32Array position;
Uint32Array surfaceDimensions;
};
</pre>
<dl>
Expand All @@ -1206,12 +1204,6 @@ <h2>
</ul>{{GamepadTouch/touchId}} SHOULD be set to a default value of 0
when a new {{Gamepad}} object is created.
</dd>
<dt>
<dfn>surfaceId</dfn>
</dt>
<dd>
Unique id of the surface that generated the touch event.
</dd>
<dt>
<dfn>position</dfn>
</dt>
Expand All @@ -1222,6 +1214,34 @@ <h2>
Along the y-axis, -1.0 references the topmost coordinate and 1.0
references the bottommost coordinate. MUST be a two-element array.
</dd>
</dl>
</section>
<section data-dfn-for="GamepadSurface">
<h2>
<dfn>GamepadSurface</dfn> dictionary
</h2>
<p>
This dictionary defines a single surface on a gamepad device that
supports input. The event consists of a touch id that uniquely
identifies the touch point from the time the input medium (e.g. finger,
stylus, etc) makes contact with the touch device, up to the time the
input medium is no longer making contact with the touch device.
</p>
<pre class="idl">
[Exposed=Window, SecureContext]
dictionary GamepadSurface {
octet surfaceId;
FrozenArray&lt;GamepadTouch&gt;? touches;
Uint32Array surfaceDimensions;
};
</pre>
<dl>
<dt>
<dfn>surfaceId</dfn>
</dt>
<dd>
Unique id of the surface that generated the touch event.
</dd>
<dt>
<dfn>surfaceDimensions</dfn>
</dt>
Expand Down

0 comments on commit 926ef0f

Please sign in to comment.