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

Unified Diff: sdk/lib/isolate/isolate_stream.dart

Issue 12049013: Change singleSubscription/multiSubscription to normal/broadcast. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Addressed comments, renamed .multiSubscription to .broadcast. Created 7 years, 11 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: sdk/lib/isolate/isolate_stream.dart
diff --git a/sdk/lib/isolate/isolate_stream.dart b/sdk/lib/isolate/isolate_stream.dart
index a0a30b0095007adf77542dc67752e0504bae1d4c..d72389faa355903e40ff38162f2c4bdeb9fda831 100644
--- a/sdk/lib/isolate/isolate_stream.dart
+++ b/sdk/lib/isolate/isolate_stream.dart
@@ -52,7 +52,7 @@ class _CloseToken {
class IsolateStream extends Stream<dynamic> {
bool _isClosed = false;
final ReceivePort _port;
- StreamController _controller = new StreamController.multiSubscription();
+ StreamController _controller = new StreamController.broadcast();
IsolateStream._fromOriginalReceivePort(this._port) {
_port.receive((message, replyTo) {
@@ -95,10 +95,10 @@ class IsolateStream extends Stream<dynamic> {
{ void onError(AsyncError error),
void onDone(),
bool unsubscribeOnError}) {
- return _controller.listen(onData,
- onError: onError,
- onDone: onDone,
- unsubscribeOnError: unsubscribeOnError);
+ return _controller.stream.listen(onData,
+ onError: onError,
+ onDone: onDone,
+ unsubscribeOnError: unsubscribeOnError);
}
dynamic _unmangleMessage(var message) {

Powered by Google App Engine
This is Rietveld 408576698