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

Unified Diff: content/common/mojo/mojo_channel_init.h

Issue 236813002: Move Mojo channel initialization closer to IPC::Channel setup (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 8 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: content/common/mojo/mojo_channel_init.h
diff --git a/content/common/mojo/mojo_channel_init.h b/content/common/mojo/mojo_channel_init.h
index 05b4e0c86cbe613565f3ad8ec0ccaed9da3a2b73..d4dfc81b674051e11df7fdfa5268490c938fe728 100644
--- a/content/common/mojo/mojo_channel_init.h
+++ b/content/common/mojo/mojo_channel_init.h
@@ -31,15 +31,11 @@ class CONTENT_EXPORT MojoChannelInit {
MojoChannelInit();
~MojoChannelInit();
- // Inits the channel. This takes ownership of |file|.
- void Init(base::PlatformFile file,
- scoped_refptr<base::TaskRunner> io_thread_task_runner);
-
- bool is_handle_valid() const { return bootstrap_message_pipe_.is_valid(); }
-
- mojo::ScopedMessagePipeHandle bootstrap_message_pipe() {
- return bootstrap_message_pipe_.Pass();
- }
+ // Initializes the channel. This takes ownership of |file|. Returns the
+ // primordial MessagePipe for the channel.
+ mojo::ScopedMessagePipeHandle Init(
+ base::PlatformFile file,
+ scoped_refptr<base::TaskRunner> io_thread_task_runner);
private:
// Invoked on the main thread once the channel has been established.
@@ -53,9 +49,6 @@ class CONTENT_EXPORT MojoChannelInit {
// If non-null the channel has been established.
mojo::embedder::ChannelInfo* channel_info_;
- // The handle from channel creation.
- mojo::ScopedMessagePipeHandle bootstrap_message_pipe_;
-
base::WeakPtrFactory<MojoChannelInit> weak_factory_;
DISALLOW_COPY_AND_ASSIGN(MojoChannelInit);

Powered by Google App Engine
This is Rietveld 408576698