Index: content/public/browser/content_browser_client.h |
diff --git a/content/public/browser/content_browser_client.h b/content/public/browser/content_browser_client.h |
index 34ff478dd0e8fcbd585372014f3dca41ffd99086..e6db426a3487ec2248fc05777598baba15ac650a 100644 |
--- a/content/public/browser/content_browser_client.h |
+++ b/content/public/browser/content_browser_client.h |
@@ -22,6 +22,7 @@ |
#include "content/public/browser/navigation_throttle.h" |
#include "content/public/common/content_client.h" |
#include "content/public/common/media_stream_request.h" |
+#include "content/public/common/process_type.h" |
#include "content/public/common/resource_type.h" |
#include "content/public/common/socket_permission_request.h" |
#include "content/public/common/window_container_type.h" |
@@ -653,6 +654,36 @@ class CONTENT_EXPORT ContentBrowserClient { |
BrowserContext* browser_context, |
const GURL& url); |
+ // Returns the embedder's packaged Mojo application name. This is the name by |
+ // which the embedder's own ShellClient factory will be known to the Mojo |
+ // shell. An embedder must override this and provide a corresponding manifest |
+ // in order to customize the application capabilities of the browser process. |
+ // |
+ // If this returns an empty string, the embedder will not be registered as an |
+ // application package. Defaults to "exe:content_browser". |
+ virtual std::string GetPackagedMojoApplicationName(); |
+ |
+ // Returns the Mojo application name to use when registering instances of a |
+ // child process with the shell. An embedder must override this and provide |
+ // corresponding manifests in order to customize the application capabilities |
+ // of any content child process type. |
+ // |
+ // If this returns an empty string for a given process type, that type of |
+ // process is never registered with the shell. Defaults to |
+ // "exe:content_renderer" for renderer processes and the empty string for all |
+ // other process types. |
+ virtual std::string GetMojoApplicationNameForProcess(ProcessType type); |
+ |
+ // Resolves a Mojo application name to the contents of its manifest. An |
+ // embedder should override this to support builtin applications without |
+ // corresponding manifest files in the local filesystem. |
+ // |
+ // Returns |false| if no builtin manifest is available for the named |
+ // application. Otherwise it returns |true| and |*manifest_contents| is |
+ // populated with a JSON manifest. |
+ virtual bool GetMojoApplicationManifest(const base::StringPiece& name, |
+ std::string* manifest_contents); |
+ |
// Allows to register browser Mojo services exposed through the |
// RenderProcessHost. |
virtual void RegisterRenderProcessMojoServices(ServiceRegistry* registry) {} |