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

Unified Diff: mojo/shell/application_manager.cc

Issue 1738663002: Hook embedded shell up to MojoShellConnection (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 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 | « mojo/shell/application_manager.h ('k') | mojo/shell/runner/child/runner_connection.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/shell/application_manager.cc
diff --git a/mojo/shell/application_manager.cc b/mojo/shell/application_manager.cc
index 314f4ea61b10261d01fd9bb40db07d0480d7d502..3267d5c67639d72616e56b650786212fbf41e41d 100644
--- a/mojo/shell/application_manager.cc
+++ b/mojo/shell/application_manager.cc
@@ -99,6 +99,21 @@ void ApplicationManager::Connect(scoped_ptr<ConnectParams> params) {
weak_ptr_factory_.GetWeakPtr(), base::Passed(&params)));
}
+mojom::ShellClientRequest ApplicationManager::InitInstanceForEmbedder(
+ const GURL& url) {
+ DCHECK(!embedder_instance_);
+
+ mojo::shell::Identity target(url, std::string(), mojom::Connector::kUserRoot);
+ target.SetFilter(GetPermissiveCapabilityFilter());
+ DCHECK(!GetApplicationInstance(target));
+
+ mojom::ShellClientRequest request;
+ embedder_instance_ = CreateInstance(target, &request);
+ DCHECK(embedder_instance_);
+
+ return request;
+}
+
void ApplicationManager::SetLoaderForURL(scoped_ptr<ApplicationLoader> loader,
const GURL& url) {
URLToLoaderMap::iterator it = url_to_loader_.find(url);
« no previous file with comments | « mojo/shell/application_manager.h ('k') | mojo/shell/runner/child/runner_connection.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698