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

Unified Diff: mojo/shell/runner/host/child_process.cc

Issue 1676913002: [mojo] Delete third_party/mojo (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: let's try that again 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
« no previous file with comments | « mojo/shell/runner/host/BUILD.gn ('k') | mojo/shell/runner/host/child_process_host.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/shell/runner/host/child_process.cc
diff --git a/mojo/shell/runner/host/child_process.cc b/mojo/shell/runner/host/child_process.cc
index 75230f096baa7471c16d78f129fb3ed3068833eb..8f8c8a1039784163e3ba4e9daf27510183328617 100644
--- a/mojo/shell/runner/host/child_process.cc
+++ b/mojo/shell/runner/host/child_process.cc
@@ -28,6 +28,8 @@
#include "base/threading/thread_checker.h"
#include "mojo/edk/embedder/embedder.h"
#include "mojo/edk/embedder/platform_channel_pair.h"
+#include "mojo/edk/embedder/process_delegate.h"
+#include "mojo/edk/embedder/scoped_platform_handle.h"
#include "mojo/message_pump/message_pump_mojo.h"
#include "mojo/public/cpp/bindings/binding.h"
#include "mojo/public/cpp/system/core.h"
@@ -35,10 +37,6 @@
#include "mojo/shell/runner/common/switches.h"
#include "mojo/shell/runner/host/native_application_support.h"
#include "mojo/shell/runner/init.h"
-#include "third_party/mojo/src/mojo/edk/embedder/embedder.h"
-#include "third_party/mojo/src/mojo/edk/embedder/platform_channel_pair.h"
-#include "third_party/mojo/src/mojo/edk/embedder/process_delegate.h"
-#include "third_party/mojo/src/mojo/edk/embedder/scoped_platform_handle.h"
#if defined(OS_LINUX) && !defined(OS_ANDROID)
#include "base/rand_util.h"
@@ -100,18 +98,15 @@ class Blocker {
class ChildControllerImpl;
// Should be created and initialized on the main thread.
-// TODO(use_chrome_edk)
-// class AppContext : public edk::ProcessDelegate {
-class AppContext : public embedder::ProcessDelegate {
+class AppContext : public edk::ProcessDelegate {
public:
AppContext()
: io_thread_("io_thread"), controller_thread_("controller_thread") {}
~AppContext() override {}
void Init() {
- embedder::PreInitializeChildProcess();
// Initialize Mojo before starting any threads.
- embedder::Init();
+ edk::Init();
// Create and start our I/O thread.
base::Thread::Options io_thread_options(base::MessageLoop::TYPE_IO, 0);
@@ -122,8 +117,7 @@ class AppContext : public embedder::ProcessDelegate {
// TODO(vtl): This should be SLAVE, not NONE.
// This must be created before controller_thread_ since MessagePumpMojo will
// create a message pipe which requires this code to be run first.
- embedder::InitIPCSupport(embedder::ProcessType::NONE, this, io_runner_,
- embedder::ScopedPlatformHandle());
+ edk::InitIPCSupport(this, io_runner_);
}
void StartControllerThread() {
@@ -165,7 +159,7 @@ class AppContext : public embedder::ProcessDelegate {
controller_.reset();
// Next shutdown IPC. We'll unblock the main thread in OnShutdownComplete().
- embedder::ShutdownIPCSupport();
+ edk::ShutdownIPCSupport();
}
// ProcessDelegate implementation.
@@ -337,8 +331,7 @@ int ChildProcessMain() {
#endif
edk::ScopedPlatformHandle platform_channel =
- edk::PlatformChannelPair::PassClientHandleFromParentProcess(
- command_line);
+ edk::PlatformChannelPair::PassClientHandleFromParentProcess(command_line);
CHECK(platform_channel.is_valid());
DCHECK(!base::MessageLoop::current());
« no previous file with comments | « mojo/shell/runner/host/BUILD.gn ('k') | mojo/shell/runner/host/child_process_host.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698