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

Unified Diff: mojo/shell/runner/host/child_process_host.h

Issue 1801963002: Change primordial pipes to ShellClient (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase onto catalog CL Created 4 years, 9 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/runner/host/child_process_base.cc ('k') | mojo/shell/runner/host/child_process_host.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/shell/runner/host/child_process_host.h
diff --git a/mojo/shell/runner/host/child_process_host.h b/mojo/shell/runner/host/child_process_host.h
index 6c6411dc7bcab384caebcf41435ec022710f18dc..c13251a34fafcba9da8aee04d2ad8ae6b1366d2c 100644
--- a/mojo/shell/runner/host/child_process_host.h
+++ b/mojo/shell/runner/host/child_process_host.h
@@ -10,9 +10,11 @@
#include <string>
#include "base/callback.h"
+#include "base/command_line.h"
#include "base/files/file_path.h"
#include "base/macros.h"
#include "base/memory/ref_counted.h"
+#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
#include "base/process/process.h"
#include "base/synchronization/lock.h"
@@ -59,10 +61,9 @@ class ChildProcessHost {
// |Start()|s the child process; calls |DidStart()| (on the thread on which
// |Start()| was called) when the child has been started (or failed to start).
- void Start(mojom::ShellClientRequest request,
- const String& name,
- const ProcessReadyCallback& callback,
- const base::Closure& quit_closure);
+ mojom::ShellClientPtr Start(const String& name,
+ const ProcessReadyCallback& callback,
+ const base::Closure& quit_closure);
// Waits for the child process to terminate.
void Join();
@@ -71,7 +72,7 @@ class ChildProcessHost {
void DidStart(const ProcessReadyCallback& callback);
private:
- void DoLaunch();
+ void DoLaunch(scoped_ptr<base::CommandLine> child_command_line);
scoped_refptr<base::TaskRunner> launch_process_runner_;
NativeRunnerDelegate* delegate_ = nullptr;
@@ -79,21 +80,15 @@ class ChildProcessHost {
Identity target_;
const base::FilePath app_path_;
base::Process child_process_;
- // Used for the ShellClientFactory binding.
- edk::PlatformChannelPair platform_channel_pair_;
- mojom::ShellClientFactoryPtr factory_;
- edk::HandlePassingInformation handle_passing_info_;
- // Used to back the NodeChannel between the parent and child node.
- scoped_ptr<edk::PlatformChannelPair> node_channel_;
+ // Used to initialize the Mojo IPC channel between parent and child.
+ scoped_ptr<edk::PlatformChannelPair> mojo_ipc_channel_;
+ edk::HandlePassingInformation handle_passing_info_;
// Since Start() calls a method on another thread, we use an event to block
// the main thread if it tries to destruct |this| while launching the process.
base::WaitableEvent start_child_process_event_;
- // A token the child can use to connect a primordial pipe to the host.
- std::string primordial_pipe_token_;
-
base::WeakPtrFactory<ChildProcessHost> weak_factory_;
DISALLOW_COPY_AND_ASSIGN(ChildProcessHost);
« no previous file with comments | « mojo/shell/runner/host/child_process_base.cc ('k') | mojo/shell/runner/host/child_process_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698