2022-02-19 22:02:32 +00:00
|
|
|
#import <DOM/AbortSignal.idl>
|
|
|
|
|
|
2022-10-07 16:45:09 -06:00
|
|
|
// https://dom.spec.whatwg.org/#eventtarget
|
2023-09-03 02:00:01 +12:00
|
|
|
[Exposed=*]
|
2020-06-21 12:27:41 +02:00
|
|
|
interface EventTarget {
|
2023-05-03 21:10:26 +01:00
|
|
|
constructor();
|
|
|
|
|
|
2022-02-19 22:02:32 +00:00
|
|
|
undefined addEventListener(DOMString type, EventListener? callback, optional (AddEventListenerOptions or boolean) options = {});
|
|
|
|
|
undefined removeEventListener(DOMString type, EventListener? callback, optional (EventListenerOptions or boolean) options = {});
|
2021-05-04 22:38:36 +01:00
|
|
|
[ImplementedAs=dispatch_event_binding] boolean dispatchEvent(Event event);
|
2020-12-09 21:26:42 +00:00
|
|
|
};
|
2022-02-19 22:02:32 +00:00
|
|
|
|
2024-10-14 11:55:51 +02:00
|
|
|
// FIXME: support callback interface
|
|
|
|
|
//callback interface EventListener {
|
|
|
|
|
// undefined handleEvent(Event event);
|
|
|
|
|
//};
|
|
|
|
|
|
2022-02-19 22:02:32 +00:00
|
|
|
dictionary EventListenerOptions {
|
|
|
|
|
boolean capture = false;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
dictionary AddEventListenerOptions : EventListenerOptions {
|
2024-12-24 17:52:52 +01:00
|
|
|
boolean passive;
|
2022-02-19 22:02:32 +00:00
|
|
|
boolean once = false;
|
|
|
|
|
AbortSignal signal;
|
|
|
|
|
};
|