| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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 dart.async; | 5 part of dart.async; |
| 6 | 6 |
| 7 typedef dynamic ZoneCallback(); | 7 typedef dynamic ZoneCallback(); |
| 8 typedef dynamic ZoneUnaryCallback(arg); | 8 typedef dynamic ZoneUnaryCallback(arg); |
| 9 typedef dynamic ZoneBinaryCallback(arg1, arg2); | 9 typedef dynamic ZoneBinaryCallback(arg1, arg2); |
| 10 | 10 |
| (...skipping 585 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 596 _ZoneFunction get _registerUnaryCallback; | 596 _ZoneFunction get _registerUnaryCallback; |
| 597 _ZoneFunction get _registerBinaryCallback; | 597 _ZoneFunction get _registerBinaryCallback; |
| 598 _ZoneFunction get _errorCallback; | 598 _ZoneFunction get _errorCallback; |
| 599 _ZoneFunction get _scheduleMicrotask; | 599 _ZoneFunction get _scheduleMicrotask; |
| 600 _ZoneFunction get _createTimer; | 600 _ZoneFunction get _createTimer; |
| 601 _ZoneFunction get _createPeriodicTimer; | 601 _ZoneFunction get _createPeriodicTimer; |
| 602 _ZoneFunction get _print; | 602 _ZoneFunction get _print; |
| 603 _ZoneFunction get _fork; | 603 _ZoneFunction get _fork; |
| 604 _ZoneFunction get _handleUncaughtError; | 604 _ZoneFunction get _handleUncaughtError; |
| 605 _Zone get parent; | 605 _Zone get parent; |
| 606 _ZoneDelegate get _delegate; | 606 ZoneDelegate get _delegate; |
| 607 Map get _map; | 607 Map get _map; |
| 608 | 608 |
| 609 bool inSameErrorZone(Zone otherZone) { | 609 bool inSameErrorZone(Zone otherZone) { |
| 610 return identical(this, otherZone) || | 610 return identical(this, otherZone) || |
| 611 identical(errorZone, otherZone.errorZone); | 611 identical(errorZone, otherZone.errorZone); |
| 612 } | 612 } |
| 613 } | 613 } |
| 614 | 614 |
| 615 class _CustomZone extends _Zone { | 615 class _CustomZone extends _Zone { |
| 616 // The actual zone and implementation of each of these | 616 // The actual zone and implementation of each of these |
| (...skipping 627 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1244 handleUncaughtError: errorHandler); | 1244 handleUncaughtError: errorHandler); |
| 1245 } | 1245 } |
| 1246 Zone zone = Zone.current.fork(specification: zoneSpecification, | 1246 Zone zone = Zone.current.fork(specification: zoneSpecification, |
| 1247 zoneValues: zoneValues); | 1247 zoneValues: zoneValues); |
| 1248 if (onError != null) { | 1248 if (onError != null) { |
| 1249 return zone.runGuarded(body); | 1249 return zone.runGuarded(body); |
| 1250 } else { | 1250 } else { |
| 1251 return zone.run(body); | 1251 return zone.run(body); |
| 1252 } | 1252 } |
| 1253 } | 1253 } |
| OLD | NEW |