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

Unified Diff: mojo/public/js/connection.js

Issue 2405093003: [WIP] Mojo native bindings interface.
Patch Set: cleanup 2 Created 4 years, 2 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: mojo/public/js/connection.js
diff --git a/mojo/public/js/connection.js b/mojo/public/js/connection.js
index 1ac88ed9e6354e8db83a37b7ec350bd947e0c445..b45e7cf3518ad019b3ec7b9ef7fff7a04316511e 100644
--- a/mojo/public/js/connection.js
+++ b/mojo/public/js/connection.js
@@ -142,7 +142,7 @@ define("mojo/public/js/connection", [
// Return a remoteInterface proxy for handle. Used by generated code
// for converting incoming interface parameters to proxies.
function bindHandleToProxy(handle, remoteInterface) {
- if (!core.isHandle(handle))
+ if (!(handle instanceof MojoHandle))
throw new Error("Not a handle " + handle);
var proxy = new remoteInterface.proxyClass;
@@ -157,7 +157,7 @@ define("mojo/public/js/connection", [
// stubs. The caller can specify the stub's implementation of localInterface
// like this: StubBindings(stub).delegate = myStubImpl.
function bindHandleToStub(handle, localInterface) {
- if (!core.isHandle(handle))
+ if (!(handle instanceof MojoHandle))
throw new Error("Not a handle " + handle);
var stub = new localInterface.stubClass;

Powered by Google App Engine
This is Rietveld 408576698