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

Side by Side Diff: mojo/public/js/connector.js

Issue 795593004: Update mojo sdk to rev cc531b32182099a5a034a99daff35ed5d38a61c8 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: More workarounds for MSVC Created 5 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 unified diff | Download patch
« no previous file with comments | « mojo/public/js/connection.js ('k') | mojo/public/js/core.js » ('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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 define("mojo/public/js/connector", [ 5 define("mojo/public/js/connector", [
6 "mojo/public/js/buffer", 6 "mojo/public/js/buffer",
7 "mojo/public/js/codec", 7 "mojo/public/js/codec",
8 "mojo/public/js/core", 8 "mojo/public/js/core",
9 "mojo/public/js/support", 9 "mojo/public/js/support",
10 ], function(buffer, codec, core, support) { 10 ], function(buffer, codec, core, support) {
11 11
12 function Connector(handle) { 12 function Connector(handle) {
13 if (!core.isHandle(handle))
14 throw new Error("Connector: not a handle " + handle);
13 this.handle_ = handle; 15 this.handle_ = handle;
14 this.dropWrites_ = false; 16 this.dropWrites_ = false;
15 this.error_ = false; 17 this.error_ = false;
16 this.incomingReceiver_ = null; 18 this.incomingReceiver_ = null;
17 this.readWaitCookie_ = null; 19 this.readWaitCookie_ = null;
18 this.errorHandler_ = null; 20 this.errorHandler_ = null;
19 21
20 this.waitToReadMore_(); 22 this.waitToReadMore_();
21 } 23 }
22 24
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after
120 122
121 TestConnector.prototype.deliverMessage = function() { 123 TestConnector.prototype.deliverMessage = function() {
122 this.readMore_(core.RESULT_OK); 124 this.readMore_(core.RESULT_OK);
123 } 125 }
124 126
125 var exports = {}; 127 var exports = {};
126 exports.Connector = Connector; 128 exports.Connector = Connector;
127 exports.TestConnector = TestConnector; 129 exports.TestConnector = TestConnector;
128 return exports; 130 return exports;
129 }); 131 });
OLDNEW
« no previous file with comments | « mojo/public/js/connection.js ('k') | mojo/public/js/core.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698