| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 class _CustomEventFactoryProvider { |
| 6 static CustomEvent createCustomEvent(String type, [bool canBubble = true, |
| 7 bool cancelable = true, Object detail = null]) { |
| 8 final _CustomEventImpl e = _document.$dom_createEvent("CustomEvent"); |
| 9 e.$dom_initCustomEvent(type, canBubble, cancelable, detail); |
| 10 return e; |
| 11 } |
| 12 } |
| 13 |
| 5 class _EventFactoryProvider { | 14 class _EventFactoryProvider { |
| 6 static Event createEvent(String type, [bool canBubble = true, | 15 static Event createEvent(String type, [bool canBubble = true, |
| 7 bool cancelable = true]) { | 16 bool cancelable = true]) { |
| 8 final _EventImpl e = _document.$dom_createEvent("Event"); | 17 final _EventImpl e = _document.$dom_createEvent("Event"); |
| 9 e.$dom_initEvent(type, canBubble, cancelable); | 18 e.$dom_initEvent(type, canBubble, cancelable); |
| 10 return e; | 19 return e; |
| 11 } | 20 } |
| 12 } | 21 } |
| 13 | 22 |
| 14 class _MouseEventFactoryProvider { | 23 class _MouseEventFactoryProvider { |
| (...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 98 } | 107 } |
| 99 | 108 |
| 100 class _SVGSVGElementFactoryProvider { | 109 class _SVGSVGElementFactoryProvider { |
| 101 static SVGSVGElement createSVGSVGElement() { | 110 static SVGSVGElement createSVGSVGElement() { |
| 102 final el = new SVGElement.tag("svg"); | 111 final el = new SVGElement.tag("svg"); |
| 103 // The SVG spec requires the version attribute to match the spec version | 112 // The SVG spec requires the version attribute to match the spec version |
| 104 el.attributes['version'] = "1.1"; | 113 el.attributes['version'] = "1.1"; |
| 105 return el; | 114 return el; |
| 106 } | 115 } |
| 107 } | 116 } |
| OLD | NEW |