| 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 part of html; | 5 part of html; |
| 6 | 6 |
| 7 class _ConsoleVariables { | 7 class _ConsoleVariables { |
| 8 Map<String, Object> _data = new Map<String, Object>(); | 8 Map<String, Object> _data = new Map<String, Object>(); |
| 9 | 9 |
| 10 /** | 10 /** |
| (...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 100 static Element getAndValidateNativeType(Type type, String tagName) { | 100 static Element getAndValidateNativeType(Type type, String tagName) { |
| 101 var element = new Element.tag(tagName); | 101 var element = new Element.tag(tagName); |
| 102 if (!isTypeSubclassOf(type, element.runtimeType)) { | 102 if (!isTypeSubclassOf(type, element.runtimeType)) { |
| 103 return null; | 103 return null; |
| 104 } | 104 } |
| 105 return element; | 105 return element; |
| 106 } | 106 } |
| 107 | 107 |
| 108 static window() native "Utils_window"; | 108 static window() native "Utils_window"; |
| 109 static forwardingPrint(String message) native "Utils_forwardingPrint"; | 109 static forwardingPrint(String message) native "Utils_forwardingPrint"; |
| 110 // TODO(vsm): Make this API compatible with spawnUri. It should also |
| 111 // return a Future<Isolate>. |
| 112 static spawnDomUri(String uri) native "Utils_spawnDomUri"; |
| 110 | 113 |
| 111 // The following methods were added for debugger integration to make working | 114 // The following methods were added for debugger integration to make working |
| 112 // with the Dart C mirrors API simpler. | 115 // with the Dart C mirrors API simpler. |
| 113 // TODO(jacobr): consider moving them to a separate library. | 116 // TODO(jacobr): consider moving them to a separate library. |
| 114 // If Dart supported dynamic code injection, we would only inject this code | 117 // If Dart supported dynamic code injection, we would only inject this code |
| 115 // when the debugger is invoked. | 118 // when the debugger is invoked. |
| 116 | 119 |
| 117 /** | 120 /** |
| 118 * Strips the private secret prefix from member names of the form | 121 * Strips the private secret prefix from member names of the form |
| 119 * someName@hash. | 122 * someName@hash. |
| (...skipping 509 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 629 _scheduleImmediateHelper._schedule(callback); | 632 _scheduleImmediateHelper._schedule(callback); |
| 630 }; | 633 }; |
| 631 | 634 |
| 632 get _pureIsolateScheduleImmediateClosure => ((void callback()) => | 635 get _pureIsolateScheduleImmediateClosure => ((void callback()) => |
| 633 throw new UnimplementedError("scheduleMicrotask in background isolates " | 636 throw new UnimplementedError("scheduleMicrotask in background isolates " |
| 634 "are not supported in the browser")); | 637 "are not supported in the browser")); |
| 635 | 638 |
| 636 void _initializeCustomElement(Element e) { | 639 void _initializeCustomElement(Element e) { |
| 637 _Utils.initializeCustomElement(e); | 640 _Utils.initializeCustomElement(e); |
| 638 } | 641 } |
| OLD | NEW |