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

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

Issue 1722743002: Adds ability for chrome to behave as mojo_runner (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: merge to tip of tree 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
Index: mojo/shell/runner/host/out_of_process_native_runner.h
diff --git a/mojo/shell/runner/host/out_of_process_native_runner.h b/mojo/shell/runner/host/out_of_process_native_runner.h
index 0edb0aae615d1f26eafdbf2b2aba3be56a7a9b63..6b63c8ad6e059b95a0b0d2d3b8c1279c21fd4ece 100644
--- a/mojo/shell/runner/host/out_of_process_native_runner.h
+++ b/mojo/shell/runner/host/out_of_process_native_runner.h
@@ -7,8 +7,6 @@
#include <stdint.h>
-#include <vector>
-
#include "base/callback.h"
#include "base/files/file_path.h"
#include "base/macros.h"
@@ -23,20 +21,20 @@ namespace mojo {
namespace shell {
class ChildProcessHost;
-struct CommandLineSwitch;
+class NativeRunnerDelegate;
// An implementation of |NativeRunner| that loads/runs the given app (from the
// file system) in a separate process (of its own).
class OutOfProcessNativeRunner : public NativeRunner {
public:
- OutOfProcessNativeRunner(
- base::TaskRunner* launch_process_runner,
- const std::vector<CommandLineSwitch>& command_line_switches);
+ OutOfProcessNativeRunner(base::TaskRunner* launch_process_runner,
+ NativeRunnerDelegate* delegate);
~OutOfProcessNativeRunner() override;
// NativeRunner:
void Start(
const base::FilePath& app_path,
+ const Identity& identity,
bool start_sandboxed,
InterfaceRequest<mojom::ShellClient> request,
const base::Callback<void(base::ProcessId)>& pid_available_callback,
@@ -56,12 +54,11 @@ class OutOfProcessNativeRunner : public NativeRunner {
base::ProcessId pid);
base::TaskRunner* const launch_process_runner_;
+ NativeRunnerDelegate* delegate_;
base::FilePath app_path_;
base::Closure app_completed_callback_;
- std::vector<CommandLineSwitch> command_line_switches_;
-
scoped_ptr<ChildProcessHost> child_process_host_;
DISALLOW_COPY_AND_ASSIGN(OutOfProcessNativeRunner);
@@ -69,16 +66,15 @@ class OutOfProcessNativeRunner : public NativeRunner {
class OutOfProcessNativeRunnerFactory : public NativeRunnerFactory {
public:
- OutOfProcessNativeRunnerFactory(
- base::TaskRunner* launch_process_runner,
- const std::vector<CommandLineSwitch>& command_line_switches);
+ OutOfProcessNativeRunnerFactory(base::TaskRunner* launch_process_runner,
+ NativeRunnerDelegate* delegate);
~OutOfProcessNativeRunnerFactory() override;
scoped_ptr<NativeRunner> Create(const base::FilePath& app_path) override;
private:
base::TaskRunner* const launch_process_runner_;
- std::vector<CommandLineSwitch> command_line_switches_;
+ NativeRunnerDelegate* delegate_;
DISALLOW_COPY_AND_ASSIGN(OutOfProcessNativeRunnerFactory);
};

Powered by Google App Engine
This is Rietveld 408576698