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

Side by Side Diff: ppapi/proxy/proxy_channel.h

Issue 6901146: Switch IPC::ChannelProxy to use MessageLoopProxy instead of MessageLoop. This allows us to remov... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 7 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
« no previous file with comments | « ppapi/proxy/ppb_flash_file_proxy.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef PPAPI_PROXY_PROXY_CHANNEL_H_ 5 #ifndef PPAPI_PROXY_PROXY_CHANNEL_H_
6 #define PPAPI_PROXY_PROXY_CHANNEL_H_ 6 #define PPAPI_PROXY_PROXY_CHANNEL_H_
7 7
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "base/process.h" 9 #include "base/process.h"
10 #include "ipc/ipc_message.h" 10 #include "ipc/ipc_message.h"
11 #include "ipc/ipc_platform_file.h" 11 #include "ipc/ipc_platform_file.h"
12 #include "ipc/ipc_sync_channel.h" 12 #include "ipc/ipc_sync_channel.h"
13 13
14 class MessageLoop;
15
16 namespace base { 14 namespace base {
15 class MessageLoopProxy;
17 class WaitableEvent; 16 class WaitableEvent;
18 } 17 }
19 18
20 namespace IPC { 19 namespace IPC {
21 class TestSink; 20 class TestSink;
22 } 21 }
23 22
24 namespace pp { 23 namespace pp {
25 namespace proxy { 24 namespace proxy {
26 25
27 class VarSerializationRules; 26 class VarSerializationRules;
28 27
29 class ProxyChannel : public IPC::Channel::Listener, 28 class ProxyChannel : public IPC::Channel::Listener,
30 public IPC::Message::Sender { 29 public IPC::Message::Sender {
31 public: 30 public:
32 typedef void (*ShutdownModuleFunc)(); 31 typedef void (*ShutdownModuleFunc)();
33 32
34 class Delegate { 33 class Delegate {
35 public: 34 public:
36 // Returns the dedicated message loop for processing IPC requests. 35 // Returns the dedicated message loop for processing IPC requests.
37 virtual MessageLoop* GetIPCMessageLoop() = 0; 36 virtual base::MessageLoopProxy* GetIPCMessageLoop() = 0;
38 37
39 // Returns the event object that becomes signalled when the main thread's 38 // Returns the event object that becomes signalled when the main thread's
40 // message loop exits. 39 // message loop exits.
41 virtual base::WaitableEvent* GetShutdownEvent() = 0; 40 virtual base::WaitableEvent* GetShutdownEvent() = 0;
42 }; 41 };
43 42
44 virtual ~ProxyChannel(); 43 virtual ~ProxyChannel();
45 44
46 // Alternative to InitWithChannel() for unit tests that want to send all 45 // Alternative to InitWithChannel() for unit tests that want to send all
47 // messages sent via this channel to the given test sink. The test sink 46 // messages sent via this channel to the given test sink. The test sink
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
102 // remote side has crashed. 101 // remote side has crashed.
103 scoped_ptr<IPC::SyncChannel> channel_; 102 scoped_ptr<IPC::SyncChannel> channel_;
104 103
105 DISALLOW_COPY_AND_ASSIGN(ProxyChannel); 104 DISALLOW_COPY_AND_ASSIGN(ProxyChannel);
106 }; 105 };
107 106
108 } // namespace proxy 107 } // namespace proxy
109 } // namespace pp 108 } // namespace pp
110 109
111 #endif // PPAPI_PROXY_PROXY_CHANNEL_H_ 110 #endif // PPAPI_PROXY_PROXY_CHANNEL_H_
OLDNEW
« no previous file with comments | « ppapi/proxy/ppb_flash_file_proxy.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698