diff options
-rw-r--r-- | dom/webidl/CommandEvent.webidl | 6 | ||||
-rw-r--r-- | dom/webidl/CompositionEvent.webidl | 10 | ||||
-rw-r--r-- | dom/webidl/CustomEvent.webidl | 6 | ||||
-rw-r--r-- | dom/webidl/DeviceMotionEvent.webidl | 12 | ||||
-rw-r--r-- | dom/webidl/DeviceOrientationEvent.webidl | 12 | ||||
-rw-r--r-- | dom/webidl/DragEvent.webidl | 30 | ||||
-rw-r--r-- | dom/webidl/Event.webidl | 4 | ||||
-rw-r--r-- | dom/webidl/HashChangeEvent.webidl | 8 | ||||
-rw-r--r-- | dom/webidl/KeyEvent.webidl | 18 | ||||
-rw-r--r-- | dom/webidl/MessageEvent.webidl | 12 | ||||
-rw-r--r-- | dom/webidl/MouseEvent.webidl | 64 | ||||
-rw-r--r-- | dom/webidl/MouseScrollEvent.webidl | 30 | ||||
-rw-r--r-- | dom/webidl/MutationEvent.webidl | 14 | ||||
-rw-r--r-- | dom/webidl/ScrollAreaEvent.webidl | 16 | ||||
-rw-r--r-- | dom/webidl/SimpleGestureEvent.webidl | 36 | ||||
-rw-r--r-- | dom/webidl/StorageEvent.webidl | 14 | ||||
-rw-r--r-- | dom/webidl/TimeEvent.webidl | 4 | ||||
-rw-r--r-- | dom/webidl/TouchEvent.webidl | 22 | ||||
-rw-r--r-- | dom/webidl/UIEvent.webidl | 8 | ||||
-rw-r--r-- | dom/webidl/XULCommandEvent.webidl | 18 |
20 files changed, 175 insertions, 169 deletions
diff --git a/dom/webidl/CommandEvent.webidl b/dom/webidl/CommandEvent.webidl index 8c16e856c..9856c77c3 100644 --- a/dom/webidl/CommandEvent.webidl +++ b/dom/webidl/CommandEvent.webidl @@ -8,7 +8,7 @@ interface CommandEvent : Event { readonly attribute DOMString? command; void initCommandEvent(DOMString type, - boolean canBubble, - boolean cancelable, - DOMString? command); + optional boolean canBubble = false, + optional boolean cancelable = false, + optional DOMString? command = null); }; diff --git a/dom/webidl/CompositionEvent.webidl b/dom/webidl/CompositionEvent.webidl index c293683ce..e4a54d678 100644 --- a/dom/webidl/CompositionEvent.webidl +++ b/dom/webidl/CompositionEvent.webidl @@ -25,9 +25,9 @@ interface CompositionEvent : UIEvent partial interface CompositionEvent { void initCompositionEvent(DOMString typeArg, - boolean canBubbleArg, - boolean cancelableArg, - Window? viewArg, - DOMString? dataArg, - DOMString localeArg); + optional boolean canBubbleArg = false, + optional boolean cancelableArg = false, + optional Window? viewArg = null, + optional DOMString? dataArg = null, + optional DOMString localeArg = ""); }; diff --git a/dom/webidl/CustomEvent.webidl b/dom/webidl/CustomEvent.webidl index 299a41ec0..1ea5572b7 100644 --- a/dom/webidl/CustomEvent.webidl +++ b/dom/webidl/CustomEvent.webidl @@ -19,9 +19,9 @@ interface CustomEvent : Event // initCustomEvent is a Gecko specific deprecated method. [Throws] void initCustomEvent(DOMString type, - boolean canBubble, - boolean cancelable, - any detail); + optional boolean canBubble = false, + optional boolean cancelable = false, + optional any detail = null); }; dictionary CustomEventInit : EventInit diff --git a/dom/webidl/DeviceMotionEvent.webidl b/dom/webidl/DeviceMotionEvent.webidl index fa4ecf3ca..c26ab080c 100644 --- a/dom/webidl/DeviceMotionEvent.webidl +++ b/dom/webidl/DeviceMotionEvent.webidl @@ -48,10 +48,10 @@ dictionary DeviceMotionEventInit : EventInit { // Mozilla extensions. partial interface DeviceMotionEvent { void initDeviceMotionEvent(DOMString type, - boolean canBubble, - boolean cancelable, - DeviceAccelerationInit acceleration, - DeviceAccelerationInit accelerationIncludingGravity, - DeviceRotationRateInit rotationRate, - double? interval); + optional boolean canBubble = false, + optional boolean cancelable = false, + optional DeviceAccelerationInit acceleration, + optional DeviceAccelerationInit accelerationIncludingGravity, + optional DeviceRotationRateInit rotationRate, + optional double? interval = null); }; diff --git a/dom/webidl/DeviceOrientationEvent.webidl b/dom/webidl/DeviceOrientationEvent.webidl index 46194453e..9802b3681 100644 --- a/dom/webidl/DeviceOrientationEvent.webidl +++ b/dom/webidl/DeviceOrientationEvent.webidl @@ -14,12 +14,12 @@ interface DeviceOrientationEvent : Event // initDeviceOrientationEvent is a Gecko specific deprecated method. void initDeviceOrientationEvent(DOMString type, - boolean canBubble, - boolean cancelable, - double? alpha, - double? beta, - double? gamma, - boolean absolute); + optional boolean canBubble = false, + optional boolean cancelable = false, + optional double? alpha = null, + optional double? beta = null, + optional double? gamma = null, + optional boolean absolute = false); }; dictionary DeviceOrientationEventInit : EventInit diff --git a/dom/webidl/DragEvent.webidl b/dom/webidl/DragEvent.webidl index 2cc173d5c..806177790 100644 --- a/dom/webidl/DragEvent.webidl +++ b/dom/webidl/DragEvent.webidl @@ -10,21 +10,21 @@ interface DragEvent : MouseEvent readonly attribute DataTransfer? dataTransfer; void initDragEvent(DOMString type, - boolean canBubble, - boolean cancelable, - Window? aView, - long aDetail, - long aScreenX, - long aScreenY, - long aClientX, - long aClientY, - boolean aCtrlKey, - boolean aAltKey, - boolean aShiftKey, - boolean aMetaKey, - unsigned short aButton, - EventTarget? aRelatedTarget, - DataTransfer? aDataTransfer); + optional boolean canBubble = false, + optional boolean cancelable = false, + optional Window? aView = null, + optional long aDetail = 0, + optional long aScreenX = 0, + optional long aScreenY = 0, + optional long aClientX = 0, + optional long aClientY = 0, + optional boolean aCtrlKey = false, + optional boolean aAltKey = false, + optional boolean aShiftKey = false, + optional boolean aMetaKey = false, + optional unsigned short aButton = 0, + optional EventTarget? aRelatedTarget = null, + optional DataTransfer? aDataTransfer = null); }; dictionary DragEventInit : MouseEventInit diff --git a/dom/webidl/Event.webidl b/dom/webidl/Event.webidl index 70a0ef513..a5d7da7d4 100644 --- a/dom/webidl/Event.webidl +++ b/dom/webidl/Event.webidl @@ -51,7 +51,9 @@ interface Event { [Pure] readonly attribute DOMHighResTimeStamp timeStamp; - void initEvent(DOMString type, boolean bubbles, boolean cancelable); + void initEvent(DOMString type, + optional boolean bubbles = false, + optional boolean cancelable = false); attribute boolean cancelBubble; }; diff --git a/dom/webidl/HashChangeEvent.webidl b/dom/webidl/HashChangeEvent.webidl index 735e8eb28..6e8be455c 100644 --- a/dom/webidl/HashChangeEvent.webidl +++ b/dom/webidl/HashChangeEvent.webidl @@ -11,10 +11,10 @@ interface HashChangeEvent : Event readonly attribute DOMString newURL; void initHashChangeEvent(DOMString typeArg, - boolean canBubbleArg, - boolean cancelableArg, - DOMString oldURLArg, - DOMString newURLArg); + optional boolean canBubbleArg = false, + optional boolean cancelableArg = false, + optional DOMString oldURLArg = "", + optional DOMString newURLArg = ""); }; dictionary HashChangeEventInit : EventInit diff --git a/dom/webidl/KeyEvent.webidl b/dom/webidl/KeyEvent.webidl index 516632854..abb4b6a34 100644 --- a/dom/webidl/KeyEvent.webidl +++ b/dom/webidl/KeyEvent.webidl @@ -225,13 +225,13 @@ interface KeyEvent const unsigned long DOM_VK_WIN_OEM_CLEAR = 0xFE; void initKeyEvent(DOMString type, - boolean canBubble, - boolean cancelable, - Window? view, - boolean ctrlKey, - boolean altKey, - boolean shiftKey, - boolean metaKey, - unsigned long keyCode, - unsigned long charCode); + optional boolean canBubble = false, + optional boolean cancelable = false, + optional Window? view = null, + optional boolean ctrlKey = false, + optional boolean altKey = false, + optional boolean shiftKey = false, + optional boolean metaKey = false, + optional unsigned long keyCode = 0, + optional unsigned long charCode = 0); }; diff --git a/dom/webidl/MessageEvent.webidl b/dom/webidl/MessageEvent.webidl index 548f14520..be5022d67 100644 --- a/dom/webidl/MessageEvent.webidl +++ b/dom/webidl/MessageEvent.webidl @@ -43,10 +43,14 @@ interface MessageEvent : Event { [Pure, Cached, Frozen] readonly attribute sequence<MessagePort> ports; - void initMessageEvent(DOMString type, boolean bubbles, boolean cancelable, - any data, DOMString origin, DOMString lastEventId, - (WindowProxy or MessagePort)? source, - sequence<MessagePort> ports); + void initMessageEvent(DOMString type, + optional boolean bubbles = false, + optional boolean cancelable = false, + optional any data = null, + optional DOMString origin = "", + optional DOMString lastEventId = "", + optional (WindowProxy or MessagePort)? source = null, + optional sequence<MessagePort> ports = []); }; dictionary MessageEventInit : EventInit { diff --git a/dom/webidl/MouseEvent.webidl b/dom/webidl/MouseEvent.webidl index d21354801..192519d57 100644 --- a/dom/webidl/MouseEvent.webidl +++ b/dom/webidl/MouseEvent.webidl @@ -32,21 +32,21 @@ interface MouseEvent : UIEvent { readonly attribute long movementY; // Deprecated in DOM Level 3: - void initMouseEvent(DOMString typeArg, - boolean canBubbleArg, - boolean cancelableArg, - Window? viewArg, - long detailArg, - long screenXArg, - long screenYArg, - long clientXArg, - long clientYArg, - boolean ctrlKeyArg, - boolean altKeyArg, - boolean shiftKeyArg, - boolean metaKeyArg, - short buttonArg, - EventTarget? relatedTargetArg); +void initMouseEvent(DOMString typeArg, + optional boolean canBubbleArg = false, + optional boolean cancelableArg = false, + optional Window? viewArg = null, + optional long detailArg = 0, + optional long screenXArg = 0, + optional long screenYArg = 0, + optional long clientXArg = 0, + optional long clientYArg = 0, + optional boolean ctrlKeyArg = false, + optional boolean altKeyArg = false, + optional boolean shiftKeyArg = false, + optional boolean metaKeyArg = false, + optional short buttonArg = 0, + optional EventTarget? relatedTargetArg = null); // Introduced in DOM Level 3: boolean getModifierState(DOMString keyArg); }; @@ -90,23 +90,23 @@ partial interface MouseEvent readonly attribute unsigned short mozInputSource; - void initNSMouseEvent(DOMString typeArg, - boolean canBubbleArg, - boolean cancelableArg, - Window? viewArg, - long detailArg, - long screenXArg, - long screenYArg, - long clientXArg, - long clientYArg, - boolean ctrlKeyArg, - boolean altKeyArg, - boolean shiftKeyArg, - boolean metaKeyArg, - short buttonArg, - EventTarget? relatedTargetArg, - float pressure, - unsigned short inputSourceArg); + void initNSMouseEvent(DOMString typeArg, + optional boolean canBubbleArg = false, + optional boolean cancelableArg = false, + optional Window? viewArg = null, + optional long detailArg = 0, + optional long screenXArg = 0, + optional long screenYArg = 0, + optional long clientXArg = 0, + optional long clientYArg = 0, + optional boolean ctrlKeyArg = false, + optional boolean altKeyArg = false, + optional boolean shiftKeyArg = false, + optional boolean metaKeyArg = false, + optional short buttonArg = 0, + optional EventTarget? relatedTargetArg = null, + optional float pressure = 0, + optional unsigned short inputSourceArg = 0); [ChromeOnly] readonly attribute boolean hitCluster; // True when touch occurs in a cluster of links diff --git a/dom/webidl/MouseScrollEvent.webidl b/dom/webidl/MouseScrollEvent.webidl index aa9e30fd2..c1e52bd8c 100644 --- a/dom/webidl/MouseScrollEvent.webidl +++ b/dom/webidl/MouseScrollEvent.webidl @@ -12,19 +12,19 @@ interface MouseScrollEvent : MouseEvent readonly attribute long axis; void initMouseScrollEvent(DOMString type, - boolean canBubble, - boolean cancelable, - Window? view, - long detail, - long screenX, - long screenY, - long clientX, - long clientY, - boolean ctrlKey, - boolean altKey, - boolean shiftKey, - boolean metaKey, - unsigned short button, - EventTarget? relatedTarget, - long axis); + optional boolean canBubble = false, + optional boolean cancelable = false, + optional Window? view = null, + optional long detail = 0, + optional long screenX = 0, + optional long screenY = 0, + optional long clientX = 0, + optional long clientY = 0, + optional boolean ctrlKey = false, + optional boolean altKey = false, + optional boolean shiftKey = false, + optional boolean metaKey = false, + optional short button = 0, + optional EventTarget? relatedTarget = null, + optional long axis = 0); }; diff --git a/dom/webidl/MutationEvent.webidl b/dom/webidl/MutationEvent.webidl index 43c7b1cd0..53625b4f9 100644 --- a/dom/webidl/MutationEvent.webidl +++ b/dom/webidl/MutationEvent.webidl @@ -23,11 +23,11 @@ interface MutationEvent : Event [Throws] void initMutationEvent(DOMString type, - boolean canBubble, - boolean cancelable, - Node? relatedNode, - DOMString prevValue, - DOMString newValue, - DOMString attrName, - unsigned short attrChange); + optional boolean canBubble = false, + optional boolean cancelable = false, + optional Node? relatedNode = null, + optional DOMString prevValue = "", + optional DOMString newValue = "", + optional DOMString attrName = "", + optional unsigned short attrChange = 0); }; diff --git a/dom/webidl/ScrollAreaEvent.webidl b/dom/webidl/ScrollAreaEvent.webidl index 0f48b4bc8..f24b7c0ad 100644 --- a/dom/webidl/ScrollAreaEvent.webidl +++ b/dom/webidl/ScrollAreaEvent.webidl @@ -12,12 +12,12 @@ interface ScrollAreaEvent : UIEvent readonly attribute float height; void initScrollAreaEvent(DOMString type, - boolean canBubble, - boolean cancelable, - Window? view, - long detail, - float x, - float y, - float width, - float height); + optional boolean canBubble = false, + optional boolean cancelable = false, + optional Window? view = null, + optional long detail = 0, + optional float x = 0, + optional float y = 0, + optional float width = 0, + optional float height = 0); }; diff --git a/dom/webidl/SimpleGestureEvent.webidl b/dom/webidl/SimpleGestureEvent.webidl index 0829076dd..76d0d20f6 100644 --- a/dom/webidl/SimpleGestureEvent.webidl +++ b/dom/webidl/SimpleGestureEvent.webidl @@ -25,22 +25,22 @@ interface SimpleGestureEvent : MouseEvent readonly attribute unsigned long clickCount; void initSimpleGestureEvent(DOMString typeArg, - boolean canBubbleArg, - boolean cancelableArg, - Window? viewArg, - long detailArg, - long screenXArg, - long screenYArg, - long clientXArg, - long clientYArg, - boolean ctrlKeyArg, - boolean altKeyArg, - boolean shiftKeyArg, - boolean metaKeyArg, - unsigned short buttonArg, - EventTarget? relatedTargetArg, - unsigned long allowedDirectionsArg, - unsigned long directionArg, - double deltaArg, - unsigned long clickCount); + optional boolean canBubbleArg = false, + optional boolean cancelableArg = false, + optional Window? viewArg = null, + optional long detailArg = 0, + optional long screenXArg = 0, + optional long screenYArg = 0, + optional long clientXArg = 0, + optional long clientYArg = 0, + optional boolean ctrlKeyArg = false, + optional boolean altKeyArg = false, + optional boolean shiftKeyArg = false, + optional boolean metaKeyArg = false, + optional short buttonArg = 0, + optional EventTarget? relatedTargetArg = null, + optional unsigned long allowedDirectionsArg = 0, + optional unsigned long directionArg = 0, + optional double deltaArg = 0, + optional unsigned long clickCount = 0); }; diff --git a/dom/webidl/StorageEvent.webidl b/dom/webidl/StorageEvent.webidl index c3e9605eb..e03f8232c 100644 --- a/dom/webidl/StorageEvent.webidl +++ b/dom/webidl/StorageEvent.webidl @@ -21,13 +21,13 @@ interface StorageEvent : Event // Bug 1016053 - This is not spec compliant. void initStorageEvent(DOMString type, - boolean canBubble, - boolean cancelable, - DOMString? key, - DOMString? oldValue, - DOMString? newValue, - DOMString? url, - Storage? storageArea); + optional boolean canBubble = false, + optional boolean cancelable = false, + optional DOMString? key = null, + optional DOMString? oldValue = null, + optional DOMString? newValue = null, + optional DOMString? url = null, + optional Storage? storageArea = null); }; dictionary StorageEventInit : EventInit diff --git a/dom/webidl/TimeEvent.webidl b/dom/webidl/TimeEvent.webidl index 40e7a0beb..8bbe4db53 100644 --- a/dom/webidl/TimeEvent.webidl +++ b/dom/webidl/TimeEvent.webidl @@ -15,6 +15,6 @@ interface TimeEvent : Event readonly attribute long detail; readonly attribute WindowProxy? view; void initTimeEvent(DOMString aType, - Window? aView, - long aDetail); + optional Window? aView = null, + optional long aDetail = 0); }; diff --git a/dom/webidl/TouchEvent.webidl b/dom/webidl/TouchEvent.webidl index d206fe0fb..fd677787a 100644 --- a/dom/webidl/TouchEvent.webidl +++ b/dom/webidl/TouchEvent.webidl @@ -23,15 +23,15 @@ interface TouchEvent : UIEvent { readonly attribute boolean shiftKey; void initTouchEvent(DOMString type, - boolean canBubble, - boolean cancelable, - Window? view, - long detail, - boolean ctrlKey, - boolean altKey, - boolean shiftKey, - boolean metaKey, - TouchList? touches, - TouchList? targetTouches, - TouchList? changedTouches); + optional boolean canBubble = false, + optional boolean cancelable = false, + optional Window? view = null, + optional long detail = 0, + optional boolean ctrlKey = false, + optional boolean altKey = false, + optional boolean shiftKey = false, + optional boolean metaKey = false, + optional TouchList? touches = null, + optional TouchList? targetTouches = null, + optional TouchList? changedTouches = null); }; diff --git a/dom/webidl/UIEvent.webidl b/dom/webidl/UIEvent.webidl index 9cc1d0cdf..5be6a443a 100644 --- a/dom/webidl/UIEvent.webidl +++ b/dom/webidl/UIEvent.webidl @@ -16,10 +16,10 @@ interface UIEvent : Event readonly attribute WindowProxy? view; readonly attribute long detail; void initUIEvent(DOMString aType, - boolean aCanBubble, - boolean aCancelable, - Window? aView, - long aDetail); + optional boolean aCanBubble = false, + optional boolean aCancelable = false, + optional Window? aView = null, + optional long aDetail = 0); }; // Additional DOM0 properties. diff --git a/dom/webidl/XULCommandEvent.webidl b/dom/webidl/XULCommandEvent.webidl index 9c024edc1..72dc3802e 100644 --- a/dom/webidl/XULCommandEvent.webidl +++ b/dom/webidl/XULCommandEvent.webidl @@ -15,13 +15,13 @@ interface XULCommandEvent : UIEvent readonly attribute Event? sourceEvent; void initCommandEvent(DOMString type, - boolean canBubble, - boolean cancelable, - Window? view, - long detail, - boolean ctrlKey, - boolean altKey, - boolean shiftKey, - boolean metaKey, - Event? sourceEvent); + optional boolean canBubble = false, + optional boolean cancelable = false, + optional Window? view = null, + optional long detail = 0, + optional boolean ctrlKey = false, + optional boolean altKey = false, + optional boolean shiftKey = false, + optional boolean metaKey = false, + optional Event? sourceEvent = null); }; |