summaryrefslogtreecommitdiffstats
path: root/remoting/protocol/connection_to_client.h
diff options
context:
space:
mode:
authorsergeyu@chromium.org <sergeyu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-08-12 23:07:05 +0000
committersergeyu@chromium.org <sergeyu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-08-12 23:07:05 +0000
commit60fc9600a685d2e8c29c9ad81b167549fb223fd3 (patch)
tree1b9fac808def5132230fa240066540640951b5bc /remoting/protocol/connection_to_client.h
parent28b50a7b55c56a941f948fc4e8de8c06cb46fc3c (diff)
downloadchromium_src-60fc9600a685d2e8c29c9ad81b167549fb223fd3.zip
chromium_src-60fc9600a685d2e8c29c9ad81b167549fb223fd3.tar.gz
chromium_src-60fc9600a685d2e8c29c9ad81b167549fb223fd3.tar.bz2
Use MessageLoopProxy for network message loop.
When we switch to P2P Pepper API we will need to run networking code on the main plugin thread. Switching to MessageLoopProxy for network thread, so that it's easier to switch network thread in the future. BUG=None TEST=None Review URL: http://codereview.chromium.org/7633009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@96651 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'remoting/protocol/connection_to_client.h')
-rw-r--r--remoting/protocol/connection_to_client.h9
1 files changed, 6 insertions, 3 deletions
diff --git a/remoting/protocol/connection_to_client.h b/remoting/protocol/connection_to_client.h
index 76e95de..fc892d0 100644
--- a/remoting/protocol/connection_to_client.h
+++ b/remoting/protocol/connection_to_client.h
@@ -10,11 +10,14 @@
#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
-#include "base/message_loop.h"
#include "base/synchronization/lock.h"
#include "remoting/protocol/session.h"
#include "remoting/protocol/video_writer.h"
+namespace base {
+class MessageLoopProxy;
+} // namespace base
+
namespace remoting {
namespace protocol {
@@ -54,7 +57,7 @@ class ConnectionToClient :
// that this object runs on. A viewer object receives events and messages from
// a libjingle channel, these events are delegated to |handler|.
// It is guaranteed that |handler| is called only on the |message_loop|.
- ConnectionToClient(MessageLoop* message_loop,
+ ConnectionToClient(base::MessageLoopProxy* message_loop,
EventHandler* handler);
virtual void Init(Session* session);
@@ -101,7 +104,7 @@ class ConnectionToClient :
void CloseChannels();
// The message loop that this object runs on.
- MessageLoop* loop_;
+ scoped_refptr<base::MessageLoopProxy> message_loop_;
// Event handler for handling events sent from this object.
EventHandler* handler_;