OLD | NEW |
1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2011, 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 // WARNING: Do not edit - generated code. | 5 // WARNING: Do not edit - generated code. |
6 | 6 |
7 class LevelDom { | 7 class LevelDom { |
8 static AnchorElement wrapAnchorElement(raw) { | 8 static AnchorElement wrapAnchorElement(raw) { |
9 return raw === null ? null : raw.dartObjectLocalStorage !== null ? raw.dartO
bjectLocalStorage : new AnchorElementWrappingImplementation._wrap(raw); | 9 return raw === null ? null : raw.dartObjectLocalStorage !== null ? raw.dartO
bjectLocalStorage : new AnchorElementWrappingImplementation._wrap(raw); |
10 } | 10 } |
(...skipping 588 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
599 static DivElement wrapDivElement(raw) { | 599 static DivElement wrapDivElement(raw) { |
600 return raw === null ? null : raw.dartObjectLocalStorage !== null ? raw.dartO
bjectLocalStorage : new DivElementWrappingImplementation._wrap(raw); | 600 return raw === null ? null : raw.dartObjectLocalStorage !== null ? raw.dartO
bjectLocalStorage : new DivElementWrappingImplementation._wrap(raw); |
601 } | 601 } |
602 | 602 |
603 static Document wrapDocument(raw) { | 603 static Document wrapDocument(raw) { |
604 if (raw === null) { return null; } | 604 if (raw === null) { return null; } |
605 if (raw.dartObjectLocalStorage !== null) { | 605 if (raw.dartObjectLocalStorage !== null) { |
606 return raw.dartObjectLocalStorage; | 606 return raw.dartObjectLocalStorage; |
607 } | 607 } |
608 switch (raw.typeName) { | 608 switch (raw.typeName) { |
| 609 case "Document": |
| 610 case "XMLDocument": |
| 611 return new XMLDocumentWrappingImplementation._wrap(raw, raw.documentElem
ent); |
609 case "HTMLDocument": | 612 case "HTMLDocument": |
610 return new DocumentWrappingImplementation._wrap(raw, raw.documentElement
); | 613 return new DocumentWrappingImplementation._wrap(raw, raw.documentElement
); |
611 case "SVGDocument": | 614 case "SVGDocument": |
612 return new SVGDocumentWrappingImplementation._wrap(raw); | 615 return new SVGDocumentWrappingImplementation._wrap(raw); |
613 default: | 616 default: |
614 throw new UnsupportedOperationException("Unknown type:" + raw.toString()
); | 617 throw new UnsupportedOperationException("Unknown type:" + raw.toString()
); |
615 } | 618 } |
616 } | 619 } |
617 | 620 |
618 static DocumentFragment wrapDocumentFragment(raw) { | 621 static DocumentFragment wrapDocumentFragment(raw) { |
619 return raw === null ? null : raw.dartObjectLocalStorage !== null ? raw.dartO
bjectLocalStorage : new DocumentFragmentWrappingImplementation._wrap(raw); | 622 return raw === null ? null : raw.dartObjectLocalStorage !== null ? raw.dartO
bjectLocalStorage : new DocumentFragmentWrappingImplementation._wrap(raw); |
620 } | 623 } |
621 | 624 |
622 static DynamicsCompressorNode wrapDynamicsCompressorNode(raw) { | 625 static DynamicsCompressorNode wrapDynamicsCompressorNode(raw) { |
623 return raw === null ? null : raw.dartObjectLocalStorage !== null ? raw.dartO
bjectLocalStorage : new DynamicsCompressorNodeWrappingImplementation._wrap(raw); | 626 return raw === null ? null : raw.dartObjectLocalStorage !== null ? raw.dartO
bjectLocalStorage : new DynamicsCompressorNodeWrappingImplementation._wrap(raw); |
624 } | 627 } |
625 | 628 |
626 static Element wrapElement(raw) { | 629 static Element wrapElement(raw) { |
627 if (raw === null) { return null; } | 630 if (raw === null) { return null; } |
628 if (raw.dartObjectLocalStorage !== null) { | 631 if (raw.dartObjectLocalStorage !== null) { |
629 return raw.dartObjectLocalStorage; | 632 return raw.dartObjectLocalStorage; |
630 } | 633 } |
631 switch (raw.typeName) { | 634 switch (raw.typeName) { |
| 635 case "Element": |
| 636 return new XMLElementWrappingImplementation._wrap(raw); |
632 case "HTMLAnchorElement": | 637 case "HTMLAnchorElement": |
633 return new AnchorElementWrappingImplementation._wrap(raw); | 638 return new AnchorElementWrappingImplementation._wrap(raw); |
634 /* Skipping HTMLAppletElement*/ | 639 /* Skipping HTMLAppletElement*/ |
635 case "HTMLAreaElement": | 640 case "HTMLAreaElement": |
636 return new AreaElementWrappingImplementation._wrap(raw); | 641 return new AreaElementWrappingImplementation._wrap(raw); |
637 case "HTMLAudioElement": | 642 case "HTMLAudioElement": |
638 return new AudioElementWrappingImplementation._wrap(raw); | 643 return new AudioElementWrappingImplementation._wrap(raw); |
639 case "HTMLBRElement": | 644 case "HTMLBRElement": |
640 return new BRElementWrappingImplementation._wrap(raw); | 645 return new BRElementWrappingImplementation._wrap(raw); |
641 case "HTMLBaseElement": | 646 case "HTMLBaseElement": |
(...skipping 468 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1110 static EventSource wrapEventSource(raw) { | 1115 static EventSource wrapEventSource(raw) { |
1111 return raw === null ? null : raw.dartObjectLocalStorage !== null ? raw.dartO
bjectLocalStorage : new EventSourceWrappingImplementation._wrap(raw); | 1116 return raw === null ? null : raw.dartObjectLocalStorage !== null ? raw.dartO
bjectLocalStorage : new EventSourceWrappingImplementation._wrap(raw); |
1112 } | 1117 } |
1113 | 1118 |
1114 static EventTarget wrapEventTarget(raw) { | 1119 static EventTarget wrapEventTarget(raw) { |
1115 if (raw === null) { return null; } | 1120 if (raw === null) { return null; } |
1116 if (raw.dartObjectLocalStorage !== null) { | 1121 if (raw.dartObjectLocalStorage !== null) { |
1117 return raw.dartObjectLocalStorage; | 1122 return raw.dartObjectLocalStorage; |
1118 } | 1123 } |
1119 switch (raw.typeName) { | 1124 switch (raw.typeName) { |
| 1125 case "Element": |
| 1126 return new XMLElementWrappingImplementation._wrap(raw); |
1120 /* Skipping AbstractWorker*/ | 1127 /* Skipping AbstractWorker*/ |
1121 case "HTMLAnchorElement": | 1128 case "HTMLAnchorElement": |
1122 return new AnchorElementWrappingImplementation._wrap(raw); | 1129 return new AnchorElementWrappingImplementation._wrap(raw); |
1123 /* Skipping HTMLAppletElement*/ | 1130 /* Skipping HTMLAppletElement*/ |
1124 case "HTMLAreaElement": | 1131 case "HTMLAreaElement": |
1125 return new AreaElementWrappingImplementation._wrap(raw); | 1132 return new AreaElementWrappingImplementation._wrap(raw); |
1126 /* Skipping Attr*/ | 1133 /* Skipping Attr*/ |
1127 case "HTMLAudioElement": | 1134 case "HTMLAudioElement": |
1128 return new AudioElementWrappingImplementation._wrap(raw); | 1135 return new AudioElementWrappingImplementation._wrap(raw); |
1129 case "HTMLBRElement": | 1136 case "HTMLBRElement": |
(...skipping 714 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1844 static NavigatorUserMediaSuccessCallback wrapNavigatorUserMediaSuccessCallback
(raw) { | 1851 static NavigatorUserMediaSuccessCallback wrapNavigatorUserMediaSuccessCallback
(raw) { |
1845 return raw === null ? null : raw.dartObjectLocalStorage !== null ? raw.dartO
bjectLocalStorage : new NavigatorUserMediaSuccessCallbackWrappingImplementation.
_wrap(raw); | 1852 return raw === null ? null : raw.dartObjectLocalStorage !== null ? raw.dartO
bjectLocalStorage : new NavigatorUserMediaSuccessCallbackWrappingImplementation.
_wrap(raw); |
1846 } | 1853 } |
1847 | 1854 |
1848 static Node wrapNode(raw) { | 1855 static Node wrapNode(raw) { |
1849 if (raw === null) { return null; } | 1856 if (raw === null) { return null; } |
1850 if (raw.dartObjectLocalStorage !== null) { | 1857 if (raw.dartObjectLocalStorage !== null) { |
1851 return raw.dartObjectLocalStorage; | 1858 return raw.dartObjectLocalStorage; |
1852 } | 1859 } |
1853 switch (raw.typeName) { | 1860 switch (raw.typeName) { |
| 1861 case "Element": |
| 1862 return new XMLElementWrappingImplementation._wrap(raw); |
1854 case "HTMLAnchorElement": | 1863 case "HTMLAnchorElement": |
1855 return new AnchorElementWrappingImplementation._wrap(raw); | 1864 return new AnchorElementWrappingImplementation._wrap(raw); |
1856 /* Skipping HTMLAppletElement*/ | 1865 /* Skipping HTMLAppletElement*/ |
1857 case "HTMLAreaElement": | 1866 case "HTMLAreaElement": |
1858 return new AreaElementWrappingImplementation._wrap(raw); | 1867 return new AreaElementWrappingImplementation._wrap(raw); |
1859 /* Skipping Attr*/ | 1868 /* Skipping Attr*/ |
1860 case "HTMLAudioElement": | 1869 case "HTMLAudioElement": |
1861 return new AudioElementWrappingImplementation._wrap(raw); | 1870 return new AudioElementWrappingImplementation._wrap(raw); |
1862 case "HTMLBRElement": | 1871 case "HTMLBRElement": |
1863 return new BRElementWrappingImplementation._wrap(raw); | 1872 return new BRElementWrappingImplementation._wrap(raw); |
(...skipping 2265 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4129 static XMLHttpRequestUpload wrapXMLHttpRequestUpload(raw) { | 4138 static XMLHttpRequestUpload wrapXMLHttpRequestUpload(raw) { |
4130 return raw === null ? null : raw.dartObjectLocalStorage !== null ? raw.dartO
bjectLocalStorage : new XMLHttpRequestUploadWrappingImplementation._wrap(raw); | 4139 return raw === null ? null : raw.dartObjectLocalStorage !== null ? raw.dartO
bjectLocalStorage : new XMLHttpRequestUploadWrappingImplementation._wrap(raw); |
4131 } | 4140 } |
4132 | 4141 |
4133 static Object wrapObject(raw) { | 4142 static Object wrapObject(raw) { |
4134 if (raw === null || raw is String || raw is num || raw is Date) { return raw
; } | 4143 if (raw === null || raw is String || raw is num || raw is Date) { return raw
; } |
4135 if (raw.dartObjectLocalStorage !== null) { | 4144 if (raw.dartObjectLocalStorage !== null) { |
4136 return raw.dartObjectLocalStorage; | 4145 return raw.dartObjectLocalStorage; |
4137 } | 4146 } |
4138 switch (raw.typeName) { | 4147 switch (raw.typeName) { |
| 4148 case "Element": |
| 4149 return new XMLElementWrappingImplementation._wrap(raw); |
4139 /* Skipping AbstractWorker*/ | 4150 /* Skipping AbstractWorker*/ |
4140 case "HTMLAnchorElement": | 4151 case "HTMLAnchorElement": |
4141 return new AnchorElementWrappingImplementation._wrap(raw); | 4152 return new AnchorElementWrappingImplementation._wrap(raw); |
4142 case "WebKitAnimation": | 4153 case "WebKitAnimation": |
4143 return new AnimationWrappingImplementation._wrap(raw); | 4154 return new AnimationWrappingImplementation._wrap(raw); |
4144 case "WebKitAnimationEvent": | 4155 case "WebKitAnimationEvent": |
4145 return new AnimationEventWrappingImplementation._wrap(raw); | 4156 return new AnimationEventWrappingImplementation._wrap(raw); |
4146 case "WebKitAnimationList": | 4157 case "WebKitAnimationList": |
4147 return new AnimationListWrappingImplementation._wrap(raw); | 4158 return new AnimationListWrappingImplementation._wrap(raw); |
4148 /* Skipping HTMLAppletElement*/ | 4159 /* Skipping HTMLAppletElement*/ |
(...skipping 963 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5112 return raw === null ? null : raw._ptr; | 5123 return raw === null ? null : raw._ptr; |
5113 } | 5124 } |
5114 | 5125 |
5115 | 5126 |
5116 static void initialize() { | 5127 static void initialize() { |
5117 secretWindow = wrapWindow(dom.window); | 5128 secretWindow = wrapWindow(dom.window); |
5118 secretDocument = wrapDocument(dom.document); | 5129 secretDocument = wrapDocument(dom.document); |
5119 } | 5130 } |
5120 | 5131 |
5121 } | 5132 } |
OLD | NEW |