mirror of
https://github.com/fluencelabs/wasm-bindgen
synced 2025-06-24 02:01:35 +00:00
web-sys: Use mixins instead of [NoInterfaceObject]
interfaces and implements
I think these might all be from before WebIDL mixins existed. Either way, multiple inheritance of interfaces that don't have exposed interface objects is equivalent to mixins.
This commit is contained in:
@ -22,8 +22,7 @@ typedef OnBeforeUnloadEventHandlerNonNull? OnBeforeUnloadEventHandler;
|
||||
callback OnErrorEventHandlerNonNull = any ((Event or DOMString) event, optional DOMString source, optional unsigned long lineno, optional unsigned long column, optional any error);
|
||||
typedef OnErrorEventHandlerNonNull? OnErrorEventHandler;
|
||||
|
||||
[NoInterfaceObject]
|
||||
interface GlobalEventHandlers {
|
||||
interface mixin GlobalEventHandlers {
|
||||
attribute EventHandler onabort;
|
||||
attribute EventHandler onblur;
|
||||
// We think the spec is wrong here. See OnErrorEventHandlerForNodes/Window
|
||||
@ -134,8 +133,7 @@ interface GlobalEventHandlers {
|
||||
attribute EventHandler onwebkittransitionend;
|
||||
};
|
||||
|
||||
[NoInterfaceObject]
|
||||
interface WindowEventHandlers {
|
||||
interface mixin WindowEventHandlers {
|
||||
attribute EventHandler onafterprint;
|
||||
attribute EventHandler onbeforeprint;
|
||||
attribute OnBeforeUnloadEventHandler onbeforeunload;
|
||||
@ -152,8 +150,7 @@ interface WindowEventHandlers {
|
||||
attribute EventHandler onunload;
|
||||
};
|
||||
|
||||
[NoInterfaceObject]
|
||||
interface DocumentAndElementEventHandlers {
|
||||
interface mixin DocumentAndElementEventHandlers {
|
||||
attribute EventHandler oncopy;
|
||||
attribute EventHandler oncut;
|
||||
attribute EventHandler onpaste;
|
||||
@ -164,12 +161,10 @@ interface DocumentAndElementEventHandlers {
|
||||
// whether an ErrorEvent was fired. We don't do that, and until we do we'll
|
||||
// need to distinguish between onerror on Window or on nodes.
|
||||
|
||||
[NoInterfaceObject]
|
||||
interface OnErrorEventHandlerForNodes {
|
||||
interface mixin OnErrorEventHandlerForNodes {
|
||||
attribute EventHandler onerror;
|
||||
};
|
||||
|
||||
[NoInterfaceObject]
|
||||
interface OnErrorEventHandlerForWindow {
|
||||
interface mixin OnErrorEventHandlerForWindow {
|
||||
attribute OnErrorEventHandler onerror;
|
||||
};
|
||||
|
Reference in New Issue
Block a user