1- [Constructor(DOMString type, optional UIEventInit eventInitDict), Exposed=Window]
1+ [Exposed=Window]
22interface UIEvent : Event {
3+ constructor(DOMString type, optional UIEventInit eventInitDict);
34 readonly attribute Window? view;
45 readonly attribute long detail;
56};
@@ -9,17 +10,19 @@ dictionary UIEventInit : EventInit {
910 long detail = 0;
1011};
1112
12- [Constructor(DOMString type, optional FocusEventInit eventInitDict), Exposed=Window]
13+ [Exposed=Window]
1314interface FocusEvent : UIEvent {
15+ constructor(DOMString type, optional FocusEventInit eventInitDict);
1416 readonly attribute EventTarget? relatedTarget;
1517};
1618
1719dictionary FocusEventInit : UIEventInit {
1820 EventTarget? relatedTarget = null;
1921};
2022
21- [Constructor(DOMString type, optional MouseEventInit eventInitDict), Exposed=Window]
23+ [Exposed=Window]
2224interface MouseEvent : UIEvent {
25+ constructor(DOMString type, optional MouseEventInit eventInitDict);
2326 readonly attribute long screenX;
2427 readonly attribute long screenY;
2528 readonly attribute long clientX;
@@ -67,8 +70,9 @@ dictionary EventModifierInit : UIEventInit {
6770 boolean modifierSymbolLock = false;
6871};
6972
70- [Constructor(DOMString type, optional WheelEventInit eventInitDict), Exposed=Window]
73+ [Exposed=Window]
7174interface WheelEvent : MouseEvent {
75+ constructor(DOMString type, optional WheelEventInit eventInitDict);
7276 // DeltaModeCode
7377 const unsigned long DOM_DELTA_PIXEL = 0x00;
7478 const unsigned long DOM_DELTA_LINE = 0x01;
@@ -87,8 +91,9 @@ dictionary WheelEventInit : MouseEventInit {
8791 unsigned long deltaMode = 0;
8892};
8993
90- [Constructor(DOMString type, optional InputEventInit eventInitDict), Exposed=Window]
94+ [Exposed=Window]
9195interface InputEvent : UIEvent {
96+ constructor(DOMString type, optional InputEventInit eventInitDict);
9297 readonly attribute DOMString? data;
9398 readonly attribute boolean isComposing;
9499 readonly attribute DOMString inputType;
@@ -100,8 +105,9 @@ dictionary InputEventInit : UIEventInit {
100105 DOMString inputType = "";
101106};
102107
103- [Constructor(DOMString type, optional KeyboardEventInit eventInitDict), Exposed=Window]
108+ [Exposed=Window]
104109interface KeyboardEvent : UIEvent {
110+ constructor(DOMString type, optional KeyboardEventInit eventInitDict);
105111 // KeyLocationCode
106112 const unsigned long DOM_KEY_LOCATION_STANDARD = 0x00;
107113 const unsigned long DOM_KEY_LOCATION_LEFT = 0x01;
@@ -131,8 +137,9 @@ dictionary KeyboardEventInit : EventModifierInit {
131137 boolean isComposing = false;
132138};
133139
134- [Constructor(DOMString type, optional CompositionEventInit eventInitDict), Exposed=Window]
140+ [Exposed=Window]
135141interface CompositionEvent : UIEvent {
142+ constructor(DOMString type, optional CompositionEventInit eventInitDict);
136143 readonly attribute DOMString data;
137144};
138145
@@ -150,3 +157,9 @@ partial interface KeyboardEvent {
150157 readonly attribute unsigned long charCode;
151158 readonly attribute unsigned long keyCode;
152159};
160+
161+ partial dictionary KeyboardEventInit {
162+ // The following support legacy user agents
163+ unsigned long charCode = 0;
164+ unsigned long keyCode = 0;
165+ };
0 commit comments