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

Side by Side Diff: components/nacl/renderer/trusted_plugin_channel.h

Issue 131413009: Prototype: Use Chromium IPC for plugin LOAD_MODULE. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased, some FIXMEs cleaned up Created 6 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright (c) 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef COMPONENTS_NACL_RENDERER_TRUSTED_PLUGIN_CHANNEL_H_
6 #define COMPONENTS_NACL_RENDERER_TRUSTED_PLUGIN_CHANNEL_H_
7
8 #include "base/memory/scoped_ptr.h"
9 #include "base/synchronization/waitable_event.h"
10 #include "ipc/ipc_channel_handle.h"
11 #include "ipc/ipc_listener.h"
12 #include "ipc/ipc_sync_channel.h"
13 #include "ppapi/c/pp_completion_callback.h"
14
15 namespace nacl {
16
17 class TrustedPluginChannel : public IPC::Listener {
18 public:
19 TrustedPluginChannel(const IPC::ChannelHandle& handle,
20 PP_CompletionCallback connected_callback);
21
22 bool Send(IPC::Message* message);
23
24 // Listener implementation.
25 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE;
26 virtual void OnChannelConnected(int32 peer_pid) OVERRIDE;
27 virtual void OnChannelError() OVERRIDE;
28
29 private:
30 scoped_ptr<IPC::SyncChannel> channel_;
31 PP_CompletionCallback connected_callback_;
32 base::WaitableEvent shutdown_event_;
33 };
34
35 } // namespace nacl
36
37 #endif // COMPONENTS_NACL_RENDERER_TRUSTED_PLUGIN_CHANNEL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698