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

Side by Side Diff: remoting/client/client_context.cc

Issue 10454018: MessageLoopProxy cleanups in remoting client. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 6 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 | « remoting/client/client_context.h ('k') | remoting/client/frame_consumer_proxy.h » ('j') | 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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #include "remoting/client/client_context.h" 5 #include "remoting/client/client_context.h"
6 6
7 namespace remoting { 7 namespace remoting {
8 8
9 ClientContext::ClientContext(base::MessageLoopProxy* main_message_loop_proxy) 9 ClientContext::ClientContext(base::SingleThreadTaskRunner* main_task_runner)
10 : main_message_loop_proxy_(main_message_loop_proxy), 10 : main_task_runner_(main_task_runner),
11 decode_thread_("ChromotingClientDecodeThread") { 11 decode_thread_("ChromotingClientDecodeThread") {
12 } 12 }
13 13
14 ClientContext::~ClientContext() { 14 ClientContext::~ClientContext() {
15 } 15 }
16 16
17 void ClientContext::Start() { 17 void ClientContext::Start() {
18 // Start all the threads. 18 // Start all the threads.
19 decode_thread_.Start(); 19 decode_thread_.Start();
20 } 20 }
21 21
22 void ClientContext::Stop() { 22 void ClientContext::Stop() {
23 // Stop all the threads. 23 // Stop all the threads.
24 decode_thread_.Stop(); 24 decode_thread_.Stop();
25 } 25 }
26 26
27 base::MessageLoopProxy* ClientContext::main_message_loop() { 27 base::SingleThreadTaskRunner* ClientContext::main_task_runner() {
28 return main_message_loop_proxy_; 28 return main_task_runner_;
29 } 29 }
30 30
31 base::MessageLoopProxy* ClientContext::decode_message_loop() { 31 base::SingleThreadTaskRunner* ClientContext::decode_task_runner() {
32 return decode_thread_.message_loop_proxy(); 32 return decode_thread_.message_loop_proxy();
33 } 33 }
34 34
35 base::MessageLoopProxy* ClientContext::network_message_loop() {
36 return main_message_loop_proxy_;
37 }
38
39 } // namespace remoting 35 } // namespace remoting
OLDNEW
« no previous file with comments | « remoting/client/client_context.h ('k') | remoting/client/frame_consumer_proxy.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698