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

Unified Diff: mojo/shell/application_manager.h

Issue 1706063002: Eliminate ShellClientFactoryConnection & just have the ApplicationManager do it. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@factory
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_instance.cc ('k') | mojo/shell/application_manager.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/shell/application_manager.h
diff --git a/mojo/shell/application_manager.h b/mojo/shell/application_manager.h
index acbb206f0e4b9feb410a3024baac4af8fd3d3f26..7790d1029ac674cd5c2b96f8c530c27da8737e68 100644
--- a/mojo/shell/application_manager.h
+++ b/mojo/shell/application_manager.h
@@ -22,6 +22,7 @@
#include "mojo/shell/public/interfaces/interface_provider.mojom.h"
#include "mojo/shell/public/interfaces/shell.mojom.h"
#include "mojo/shell/public/interfaces/shell_client.mojom.h"
+#include "mojo/shell/public/interfaces/shell_client_factory.mojom.h"
#include "url/gurl.h"
namespace base {
@@ -104,7 +105,7 @@ class ApplicationManager {
using IdentityToInstanceMap = std::map<Identity, ApplicationInstance*>;
using URLToLoaderMap = std::map<GURL, ApplicationLoader*>;
using IdentityToShellClientFactoryMap =
- std::map<Identity, ShellClientFactoryConnection*>;
+ std::map<Identity, mojom::ShellClientFactoryPtr>;
// Takes the contents of |params| only when it returns true.
bool ConnectToRunningApplication(
@@ -123,17 +124,16 @@ class ApplicationManager {
const String& application_name,
mojom::ShellClientRequest* request);
- uint32_t StartShellClientFactory(const Identity& source,
- const Identity& shell_client_factory,
- const GURL& url,
- mojom::ShellClientRequest request);
+ void CreateShellClient(const Identity& source,
+ const Identity& shell_client_factory,
+ const GURL& url,
+ mojom::ShellClientRequest request);
// Returns a running ShellClientFactory for |shell_client_factory_identity|,
// if there is not one running one is started for |source_identity|.
- ShellClientFactoryConnection* GetShellClientFactory(
+ mojom::ShellClientFactory* GetShellClientFactory(
const Identity& shell_client_factory_identity,
const Identity& source_identity);
- void OnShellClientFactoryConnectionClosed(
- ShellClientFactoryConnection* shell_client_factory);
+ void OnShellClientFactoryLost(const Identity& which);;
// Callback when remote PackageManager resolves mojo:foo to mojo:bar.
// |params| are the params passed to Connect().
@@ -180,7 +180,7 @@ class ApplicationManager {
IdentityToInstanceMap identity_to_instance_;
- IdentityToShellClientFactoryMap identity_to_shell_client_factory_;
+ IdentityToShellClientFactoryMap shell_client_factories_;
// Counter used to assign ids to content handlers.
uint32_t shell_client_factory_id_counter_;
« no previous file with comments | « mojo/shell/application_instance.cc ('k') | mojo/shell/application_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698