Re: [w3c/gamepad] extensions: Add vibrationActuator and dual-rumble effect (PR #163)

@nondebug commented on this pull request.



> +            <li>If this actuator can [=play effects with type=]
+            |type:GamepadHapticEffectType|, return `true`.
+            </li>
+            <li>Otherwise, return `false`.
+            </li>
+          </ol>
+        </dd>
+        <dt>
+          <dfn>playEffect()</dfn> method
+        </dt>
+        <dd>
+          <p>
+            The {{GamepadHapticActuator/playEffect()}} method steps are:
+          </p>
+          <ol>
+            <li>If |params:GamepadEffectParameters| does not describe a [=valid

This PR is intended to describe the current implementation in Chromium which resolves with "invalid-parameter":

https://source.chromium.org/chromium/chromium/src/+/main:third_party/blink/renderer/modules/gamepad/gamepad_haptic_actuator.cc;l=95;drc=db9ae7941adc1d95c943accce9e0151d265fd640

I agree it would make more sense to reject with `TypeError`. I think we can change this without breaking applications since there aren't likely to be any applications that depend on the current behavior.

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

Message ID: <w3c/gamepad/pull/163/review/1000570109@github.com>

Received on Wednesday, 8 June 2022 23:49:36 UTC