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

Unified Diff: sky/framework/shell.sky

Issue 690803002: Add a basic XMLHttpRequest implementation (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Propagate error Created 6 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
« no previous file with comments | « no previous file | sky/framework/xmlhttprequest.sky » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/framework/shell.sky
diff --git a/sky/framework/shell.sky b/sky/framework/shell.sky
new file mode 100644
index 0000000000000000000000000000000000000000..de45b7e35f41a0e9388ffc885839a9746a4301b3
--- /dev/null
+++ b/sky/framework/shell.sky
@@ -0,0 +1,23 @@
+<link rel="import" href="/mojo/public/html/core.html" as="core" />
+<link rel="import" href="/mojo/public/html/connection.html" as="connection" />
+<script>
+function wrapHandle(handle, service, client) {
+ var clientClass = client && service.client.delegatingStubClass;
+ var serviceConnection = new connection.Connection(
+ handle, clientClass, service.proxyClass);
+ if (serviceConnection.local)
+ serviceConnection.local.delegate$ = client;
+ serviceConnection.remote.connection$ = serviceConnection;
+ return serviceConnection.remote;
+}
+
+function connectToService(url, service, client) {
+ var handle = internals.connectToService(url, service.name);
+ return wrapHandle(handle, service, client);
+}
+
+this.exports = {
+ connectToService: connectToService,
+ wrapHandle: wrapHandle,
+};
+</script>
« no previous file with comments | « no previous file | sky/framework/xmlhttprequest.sky » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698