[whatwg/dom] bubbles and cancelable are not always initialized (#416)

As usually, I'm probably just missing it, but...

The only [definition](https://dom.spec.whatwg.org/#dom-event-bubbles) of `bubbles` and `cancelable` is:

> The `bubbles` and `cancelable` attributes must return the values they were initialized to.

Going through e.g. [fire an event](https://dom.spec.whatwg.org/#concept-event-fire) it has only:

> Initialize any other IDL attributes of event as described in the invocation of this algorithm.

Nothing (other than common sense, which we left at the door...) seems to initialize them to false.

The example shows how to override defaults:

>  "fire an event named `submit` at _target_ with its `cancelable` attribute initialized to true"

In contrast, `isTrusted` is handled [explicitly](https://dom.spec.whatwg.org/#dom-event-istrusted):

> The `isTrusted` attribute must return the value it was initialized to. When an event is created the attribute must be initialized to false.

And later the note in [fire an event](https://dom.spec.whatwg.org/#concept-event-fire):

> This also allows for the `isTrusted` attribute to be set to false.

All of the other attributes on `Event` I could see appear to be initialized or are getters for internal slots/flags that are initialized.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/dom/issues/416

Received on Friday, 3 March 2017 23:24:40 UTC