OLD | NEW |
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/host/it2me_host_user_interface.h" | 5 #include "remoting/host/it2me_host_user_interface.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "remoting/host/chromoting_host.h" | 8 #include "remoting/host/chromoting_host.h" |
9 #include "remoting/host/chromoting_host_context.h" | 9 #include "remoting/host/chromoting_host_context.h" |
10 #include "remoting/host/continue_window.h" | 10 #include "remoting/host/continue_window.h" |
(...skipping 12 matching lines...) Expand all Loading... |
23 } // namespace | 23 } // namespace |
24 | 24 |
25 namespace remoting { | 25 namespace remoting { |
26 | 26 |
27 class It2MeHostUserInterface::TimerTask { | 27 class It2MeHostUserInterface::TimerTask { |
28 public: | 28 public: |
29 TimerTask(base::MessageLoopProxy* message_loop, | 29 TimerTask(base::MessageLoopProxy* message_loop, |
30 const base::Closure& task, | 30 const base::Closure& task, |
31 int delay_ms) | 31 int delay_ms) |
32 : thread_proxy_(message_loop) { | 32 : thread_proxy_(message_loop) { |
33 thread_proxy_.PostDelayedTask( | 33 thread_proxy_.PostDelayedTask(FROM_HERE, task, delay_ms); |
34 FROM_HERE, task, base::TimeDelta::FromMilliseconds(delay_ms)); | |
35 } | 34 } |
36 | 35 |
37 private: | 36 private: |
38 ScopedThreadProxy thread_proxy_; | 37 ScopedThreadProxy thread_proxy_; |
39 }; | 38 }; |
40 | 39 |
41 | 40 |
42 It2MeHostUserInterface::It2MeHostUserInterface(ChromotingHostContext* context) | 41 It2MeHostUserInterface::It2MeHostUserInterface(ChromotingHostContext* context) |
43 : HostUserInterface(context) { | 42 : HostUserInterface(context) { |
44 } | 43 } |
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
150 ui_message_loop(), | 149 ui_message_loop(), |
151 base::Bind(&It2MeHostUserInterface::OnContinueWindowTimer, | 150 base::Bind(&It2MeHostUserInterface::OnContinueWindowTimer, |
152 base::Unretained(this)), | 151 base::Unretained(this)), |
153 kContinueWindowShowTimeoutMs)); | 152 kContinueWindowShowTimeoutMs)); |
154 } else { | 153 } else { |
155 timer_task_.reset(); | 154 timer_task_.reset(); |
156 } | 155 } |
157 } | 156 } |
158 | 157 |
159 } // namespace remoting | 158 } // namespace remoting |
OLD | NEW |