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

Unified Diff: client/dart.js

Issue 10702110: Added Dartium support for JS to Dart PortSync calls (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fixed tabbing Created 8 years, 5 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
« no previous file with comments | « no previous file | lib/dom/templates/html/dartium/html_dartium.darttemplate » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: client/dart.js
diff --git a/client/dart.js b/client/dart.js
index 57637e60841a08148402113ae4e5a4140eb90a7d..67ab603abc52a320da5c9012166365d11708ea36 100644
--- a/client/dart.js
+++ b/client/dart.js
@@ -55,8 +55,8 @@ function ReceivePortSync() {
return message;
} else if (message instanceof LocalSendPortSync) {
return [ 'sendport', 'nativejs', message.receivePort.id ];
- } else if (message instanceof Dart2JsSendPortSync) {
- return [ 'sendport', 'dart2js', message.receivePort.isolateId,
+ } else if (message instanceof DartSendPortSync) {
+ return [ 'sendport', 'dart', message.receivePort.isolateId,
message.receivePort.portId ];
} else {
var id = 0;
@@ -106,10 +106,10 @@ function ReceivePortSync() {
case 'nativejs':
var id = x[2];
return new LocalSendPortSync(id);
- case 'dart2js':
+ case 'dart':
var isolateId = x[2];
var portId = x[3];
- return new Dart2JsSendPortSync(isolateId, portId);
+ return new DartSendPortSync(isolateId, portId);
default:
throw 'Illegal SendPortSync type: $tag';
}
@@ -169,21 +169,21 @@ function ReceivePortSync() {
return this.receivePort.callback(message);
}
- function Dart2JsSendPortSync(isolateId, portId) {
+ function DartSendPortSync(isolateId, portId) {
this.isolateId = isolateId;
this.portId = portId;
}
- Dart2JsSendPortSync.prototype = new SendPortSync();
+ DartSendPortSync.prototype = new SendPortSync();
function dispatchEvent(receiver, message) {
var string = JSON.stringify(message);
var event = document.createEvent('TextEvent');
event.initTextEvent(receiver, false, false, window, string);
- window.dispatchEvent(event);
+ window.dispatchEvent(event);
}
- Dart2JsSendPortSync.prototype.callSync = function(message) {
+ DartSendPortSync.prototype.callSync = function(message) {
var serialized = serialize(message);
var target = 'dart-port-' + this.isolateId + '-' + this.portId;
// TODO(vsm): Make this re-entrant.
« no previous file with comments | « no previous file | lib/dom/templates/html/dartium/html_dartium.darttemplate » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698