| Index: tools/dom/templates/html/impl/impl_UIEvent.darttemplate
|
| diff --git a/tools/dom/templates/html/impl/impl_UIEvent.darttemplate b/tools/dom/templates/html/impl/impl_UIEvent.darttemplate
|
| index 504671a0f639971feafe493271a5a4a9637e153b..939ce85cf614b69cdcaa38d498a02aef3f9f4767 100644
|
| --- a/tools/dom/templates/html/impl/impl_UIEvent.darttemplate
|
| +++ b/tools/dom/templates/html/impl/impl_UIEvent.darttemplate
|
| @@ -13,8 +13,12 @@ $(ANNOTATIONS)class $CLASSNAME$EXTENDS$IMPLEMENTS$NATIVESPEC {
|
| //
|
| // Contrary to JS, we default canBubble and cancelable to true, since that's
|
| // what people want most of the time anyway.
|
| - factory $CLASSNAME(String type, Window view, int detail,
|
| - [bool canBubble = true, bool cancelable = true]) {
|
| + factory $CLASSNAME(String type,
|
| + {Window view, int detail: 0, bool canBubble: true,
|
| + bool cancelable: true}) {
|
| + if (view == null) {
|
| + view = window;
|
| + }
|
| final e = document.$dom_createEvent("UIEvent");
|
| e.$dom_initUIEvent(type, canBubble, cancelable, view, detail);
|
| return e;
|
|
|