- From: Boris Zbarsky <notifications@github.com>
- Date: Mon, 01 Aug 2016 09:24:47 -0700
- To: w3c/gamepad <gamepad@noreply.github.com>
Received on Monday, 1 August 2016 16:28:23 UTC
Well, the array stuff was all up in the air for a while. `T[]` was never implemented by any browser and is slated to be nixed from the spec. What Gecko _actually_ uses here is: [Pure, Cached, Frozen] readonly attribute sequence<GamepadButton> buttons; the `[Frozen]` bit gives this the same semantics as `FrozenArray`. See https://developer.mozilla.org/en-US/docs/Mozilla/WebIDL_bindings#Frozen and compare to http://heycam.github.io/webidl/#dfn-create-frozen-array In terms of how you would use a `FrozenArray` in the spec, I believe you would have the object store the `FrozenArray` and recreate it from a sequence as needed (e.g. whenever the list changes). The storing of the value is handled automatically in Gecko's bindings due to the `Cached` thing, but would need to be explicitly spelled out in prose in the spec.... --- 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/issues/28#issuecomment-236631405
Received on Monday, 1 August 2016 16:28:23 UTC