OLD | NEW |
1 library html; | 1 library html; |
2 | 2 |
3 import 'dart:async'; | 3 import 'dart:async'; |
4 import 'dart:collection'; | 4 import 'dart:collection'; |
5 import 'dart:html_common'; | 5 import 'dart:html_common'; |
6 import 'dart:indexed_db'; | 6 import 'dart:indexed_db'; |
7 import 'dart:isolate'; | 7 import 'dart:isolate'; |
8 import 'dart:json' as json; | 8 import 'dart:json' as json; |
9 import 'dart:math'; | 9 import 'dart:math'; |
10 import 'dart:svg' as svg; | 10 import 'dart:svg' as svg; |
(...skipping 30 matching lines...) Expand all Loading... |
41 JS('void', r'window.$dart$isolate$counter = 1'); | 41 JS('void', r'window.$dart$isolate$counter = 1'); |
42 } | 42 } |
43 return JS('int', r'window.$dart$isolate$counter++'); | 43 return JS('int', r'window.$dart$isolate$counter++'); |
44 } | 44 } |
45 | 45 |
46 // Fast path to invoke JS send port. | 46 // Fast path to invoke JS send port. |
47 _callPortSync(int id, message) { | 47 _callPortSync(int id, message) { |
48 return JS('var', r'ReceivePortSync.dispatchCall(#, #)', id, message); | 48 return JS('var', r'ReceivePortSync.dispatchCall(#, #)', id, message); |
49 } | 49 } |
50 | 50 |
51 // TODO(vsm): Plumb this properly. | 51 spawnDomFunction(f) => IsolateNatives.spawnDomFunction(f); |
52 spawnDomFunction(f) => spawnFunction(f); | |
53 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 52 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
54 // for details. All rights reserved. Use of this source code is governed by a | 53 // for details. All rights reserved. Use of this source code is governed by a |
55 // BSD-style license that can be found in the LICENSE file. | 54 // BSD-style license that can be found in the LICENSE file. |
56 | 55 |
57 | 56 |
58 /// @domName AbstractWorker; @docsEditable true | 57 /// @domName AbstractWorker; @docsEditable true |
59 class AbstractWorker extends EventTarget native "*AbstractWorker" { | 58 class AbstractWorker extends EventTarget native "*AbstractWorker" { |
60 | 59 |
61 /// @domName EventTarget.addEventListener, EventTarget.removeEventListener, Ev
entTarget.dispatchEvent; @docsEditable true | 60 /// @domName EventTarget.addEventListener, EventTarget.removeEventListener, Ev
entTarget.dispatchEvent; @docsEditable true |
62 AbstractWorkerEvents get on => | 61 AbstractWorkerEvents get on => |
(...skipping 26874 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
26937 _position = nextPosition; | 26936 _position = nextPosition; |
26938 return true; | 26937 return true; |
26939 } | 26938 } |
26940 _current = null; | 26939 _current = null; |
26941 _position = _array.length; | 26940 _position = _array.length; |
26942 return false; | 26941 return false; |
26943 } | 26942 } |
26944 | 26943 |
26945 T get current => _current; | 26944 T get current => _current; |
26946 } | 26945 } |
OLD | NEW |