Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clarify if event handler attributes need definition (and if so, under what conditions) #29

Closed
wolenetz opened this issue Apr 28, 2016 · 3 comments
Assignees

Comments

@wolenetz
Copy link
Contributor

wolenetz commented Apr 28, 2016

For more context, see w3c/media-source#66 for more context, especially the chain of comments up to the reply by @domenic (w3c/media-source#66 (comment)).

Under what conditions should event handler attributes be defined in a spec? Should they be for only "declarative" objects (like <video>), or for any object that inherits from EventTarget, or some other conditions?

Note that both MSE and EME specs currently operate under the assumption that event handlers only need definition for declarative objects. For example, "MediaSource.onsourceopen" is not defined, since MediaSource objects can only be created by script. Script must explicitly listen for "sourceopen" event firing on a MediaSource to handle that event.

@ddorwin, @foolip, @jdsmith3000, @paulbrucecotton for getting updates on the status of this issue.

@domenic
Copy link
Member

domenic commented Apr 28, 2016

It should be any object that inherits from EventTarget. There's no rationale for restricting it to any class of objects, whether that restriction is "element interfaces" or "interfaces that start with the letter Q". The benefits are the same for all interfaces.

@annevk
Copy link
Member

annevk commented Apr 29, 2016

Event handlers are not magical. They're just ordinary IDL attributes and therefore need to be defined.

@wolenetz
Copy link
Contributor Author

@annevk Magic was not suspected here :).
It was more of a current vs legacy style question, since (per the original comment linked for context) there appears to not have been such clarity in the past.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants