[webkit-dev] On IDL files, events and writing DOM bindings

Darin Adler darin at apple.com
Tue Aug 10 22:51:40 PDT 2010


The bindings do not expose events directly, thus the IDL files don’t show the events. The IDL files only show functions and attributes on the various objects. Events are neither functions nor attributes. For the bindings I am familiar with, there is no list of events and so nothing to be generated from the IDL. The event names, as with tag names, are string constants.

You mentioned the ended attribute in HTMLMediaElement. This is a boolean attribute, and not an event. It happens to have the same name as an event, but there is no direct connection between the event and the attribute.

You asked:

> is it possible to know which Events are defined for each class just from the IDL files

Events are not defined for classes. The engine can send events to any EventTarget, and the IDL files and the bindings have nothing to say about which events the engine will send to which objects.

    -- Darin



More information about the webkit-dev mailing list