diff options
Diffstat (limited to 'content/app/mojo/mojo_init.cc')
-rw-r--r-- | content/app/mojo/mojo_init.cc | 32 |
1 files changed, 3 insertions, 29 deletions
diff --git a/content/app/mojo/mojo_init.cc b/content/app/mojo/mojo_init.cc index 07e4d5a..828887d 100644 --- a/content/app/mojo/mojo_init.cc +++ b/content/app/mojo/mojo_init.cc @@ -9,11 +9,7 @@ #include "base/memory/scoped_ptr.h" #include "content/public/common/content_switches.h" #include "ipc/ipc_channel.h" -#include "third_party/mojo/src/mojo/edk/embedder/embedder.h" - -#if defined(MOJO_SHELL_CLIENT) -#include "content/common/mojo/mojo_shell_connection_impl.h" -#endif +#include "mojo/edk/embedder/embedder.h" namespace content { @@ -22,30 +18,8 @@ namespace { class MojoInitializer { public: MojoInitializer() { - const base::CommandLine& command_line = - *base::CommandLine::ForCurrentProcess(); - std::string process_type = - command_line.GetSwitchValueASCII(switches::kProcessType); - if (process_type.empty() && !command_line.HasSwitch("use-old-edk")) { - base::CommandLine::ForCurrentProcess()->AppendSwitch( - "use-new-edk"); - } - - if (command_line.HasSwitch("use-new-edk")) { - bool initialize_as_parent = process_type.empty(); -#if defined(MOJO_SHELL_CLIENT) - if (IsRunningInMojoShell()) - initialize_as_parent = false; -#endif - if (initialize_as_parent) { - mojo::embedder::PreInitializeParentProcess(); - } else { - mojo::embedder::PreInitializeChildProcess(); - } - } - - mojo::embedder::SetMaxMessageSize(IPC::Channel::kMaximumMessageSize); - mojo::embedder::Init(); + mojo::edk::SetMaxMessageSize(IPC::Channel::kMaximumMessageSize); + mojo::edk::Init(); } }; |