Index: content/common/mojo/mojo_shell_connection_impl.h |
diff --git a/content/common/mojo/mojo_shell_connection_impl.h b/content/common/mojo/mojo_shell_connection_impl.h |
index 484e2ab79f6021c720d81effb403a8b25d9d54f4..8891acba7bc1e54927325891a6c4f7aa51cffe2d 100644 |
--- a/content/common/mojo/mojo_shell_connection_impl.h |
+++ b/content/common/mojo/mojo_shell_connection_impl.h |
@@ -11,6 +11,7 @@ |
#include "base/memory/scoped_ptr.h" |
#include "content/public/common/mojo_shell_connection.h" |
#include "mojo/application/public/cpp/application_delegate.h" |
+#include "mojo/public/cpp/system/message_pipe.h" |
namespace mojo { |
namespace runner { |
@@ -20,8 +21,7 @@ class RunnerConnection; |
namespace content { |
-// Returns true if the Chrome browser process was launched from the external |
-// Mojo shell. |
+// Returns true for processes launched from an external mojo shell. |
bool IsRunningInMojoShell(); |
class MojoShellConnectionImpl : public MojoShellConnection, |
@@ -32,6 +32,9 @@ class MojoShellConnectionImpl : public MojoShellConnection, |
// thread until calling GetApplication() will return an Initialized() |
// application with a bound ShellPtr. |
static void Create(); |
+ // Same as Create(), but receives a handle instead of looking for one on the |
+ // command line. |
+ static void CreateWithMessagePipe(mojo::ScopedMessagePipeHandle handle); |
private: |
MojoShellConnectionImpl(); |
@@ -50,7 +53,7 @@ class MojoShellConnectionImpl : public MojoShellConnection, |
// Blocks the calling thread until a connection to the spawning shell is |
// established, an Application request from it is bound, and the Initialize() |
// method on that application is called. |
- void WaitForShell(); |
+ void WaitForShell(mojo::ScopedMessagePipeHandle handle); |
bool initialized_; |
scoped_ptr<mojo::runner::RunnerConnection> runner_connection_; |