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

Side by Side Diff: samples/isolate_html/isolate_sample.dart

Issue 11364134: Merge libv1. (Closed) Base URL: https://dart.googlecode.com/svn/experimental/lib_v2/dart
Patch Set: Reupload due to error Created 8 years, 1 month 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « samples/dartcombat/dartcombatlib.dart ('k') | samples/markdown/lib.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #library('isolate_sample'); 5 library isolate_sample;
6 6
7 #import('dart:html'); 7 import 'dart:html';
8 #import('dart:isolate'); 8 import 'dart:isolate';
9 #import('dart:math'); 9 import 'dart:math';
10 10
11 /* 11 /*
12 * This is a simple sample application showing how to create two isolates 12 * This is a simple sample application showing how to create two isolates
13 * and send messages to them, and receive replies back. 13 * and send messages to them, and receive replies back.
14 */ 14 */
15 15
16 /** 16 /**
17 * These are the messages we are going to send to the isolates that we create. 17 * These are the messages we are going to send to the isolates that we create.
18 */ 18 */
19 class MessageId { 19 class MessageId {
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
120 ports[isolateName].call(message).then((var msg) { 120 ports[isolateName].call(message).then((var msg) {
121 replyElement.text = msg; 121 replyElement.text = msg;
122 }); 122 });
123 }); 123 });
124 } 124 }
125 125
126 port.receive((var message, SendPort replyTo) { 126 port.receive((var message, SendPort replyTo) {
127 replyElement.text = message; 127 replyElement.text = message;
128 }); 128 });
129 } 129 }
OLDNEW
« no previous file with comments | « samples/dartcombat/dartcombatlib.dart ('k') | samples/markdown/lib.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698