Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(568)

Unified Diff: lib/isolate/frog/messages.dart

Issue 9562048: isolate in frog: hiding internal implementation classes, couple minor fixes. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: lib/isolate/frog/messages.dart
diff --git a/lib/isolate/frog/messages.dart b/lib/isolate/frog/messages.dart
index 9d0f12db4e37636f495b3be5198d52bbdb7b5123..e5d36b26b46d3f27e6f368dbea5ee2b69b741a1d 100644
--- a/lib/isolate/frog/messages.dart
+++ b/lib/isolate/frog/messages.dart
@@ -6,7 +6,7 @@
/** Serialize [message] (or simulate serialization). */
_serializeMessage(message) {
- if (globalState.needSerialization) {
+ if (_globalState.needSerialization) {
return new _Serializer().traverse(message);
} else {
return new _Copier().traverse(message);
@@ -15,7 +15,7 @@ _serializeMessage(message) {
/** Deserialize [message] (or simulate deserialization). */
_deserializeMessage(message) {
- if (globalState.needSerialization) {
+ if (_globalState.needSerialization) {
return new _Deserializer().deserialize(message);
} else {
// Nothing more to do.
@@ -200,7 +200,7 @@ class _Serializer extends _MessageTraverser {
}
visitNativeJsSendPort(_NativeJsSendPort port) {
- return ['sendport', globalState.currentWorkerId,
+ return ['sendport', _globalState.currentWorkerId,
port._isolateId, port._receivePort._id];
}
@@ -307,8 +307,8 @@ class _Deserializer {
int receivePortId = x[3];
// If two isolates are in the same worker, we use NativeJsSendPorts to
// deliver messages directly without using postMessage.
- if (workerId == globalState.currentWorkerId) {
- var isolate = globalState.isolates[isolateId];
+ if (workerId == _globalState.currentWorkerId) {
+ var isolate = _globalState.isolates[isolateId];
if (isolate == null) return null; // Isolate has been closed.
var receivePort = isolate.lookup(receivePortId);
return new _NativeJsSendPort(receivePort, isolateId);

Powered by Google App Engine
This is Rietveld 408576698