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/desktop_environment.h" | 5 #include "remoting/host/desktop_environment.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/compiler_specific.h" | 8 #include "base/compiler_specific.h" |
9 #include "remoting/host/audio_capturer.h" | 9 #include "remoting/host/audio_capturer.h" |
10 #include "remoting/host/video_frame_capturer.h" | 10 #include "remoting/host/video_frame_capturer.h" |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
46 scoped_ptr<AudioCapturer> audio_capturer = AudioCapturer::Create(); | 46 scoped_ptr<AudioCapturer> audio_capturer = AudioCapturer::Create(); |
47 | 47 |
48 if (capturer.get() == NULL || event_executor.get() == NULL) { | 48 if (capturer.get() == NULL || event_executor.get() == NULL) { |
49 LOG(ERROR) << "Unable to create DesktopEnvironment"; | 49 LOG(ERROR) << "Unable to create DesktopEnvironment"; |
50 return scoped_ptr<DesktopEnvironment>(); | 50 return scoped_ptr<DesktopEnvironment>(); |
51 } | 51 } |
52 | 52 |
53 #if defined(OS_WIN) | 53 #if defined(OS_WIN) |
54 event_executor.reset(new SessionEventExecutorWin( | 54 event_executor.reset(new SessionEventExecutorWin( |
55 context->desktop_task_runner(), | 55 context->desktop_task_runner(), |
56 context->file_task_runner(), | |
57 event_executor.Pass())); | 56 event_executor.Pass())); |
58 #endif | 57 #endif |
59 | 58 |
60 return scoped_ptr<DesktopEnvironment>( | 59 return scoped_ptr<DesktopEnvironment>( |
61 new DesktopEnvironment(context, | 60 new DesktopEnvironment(context, |
62 capturer.Pass(), | 61 capturer.Pass(), |
63 event_executor.Pass(), | 62 event_executor.Pass(), |
64 audio_capturer.Pass())); | 63 audio_capturer.Pass())); |
65 } | 64 } |
66 | 65 |
(...skipping 27 matching lines...) Expand all Loading... |
94 void DesktopEnvironment::OnSessionStarted( | 93 void DesktopEnvironment::OnSessionStarted( |
95 scoped_ptr<protocol::ClipboardStub> client_clipboard) { | 94 scoped_ptr<protocol::ClipboardStub> client_clipboard) { |
96 event_executor_->OnSessionStarted(client_clipboard.Pass()); | 95 event_executor_->OnSessionStarted(client_clipboard.Pass()); |
97 } | 96 } |
98 | 97 |
99 void DesktopEnvironment::OnSessionFinished() { | 98 void DesktopEnvironment::OnSessionFinished() { |
100 event_executor_->OnSessionFinished(); | 99 event_executor_->OnSessionFinished(); |
101 } | 100 } |
102 | 101 |
103 } // namespace remoting | 102 } // namespace remoting |
OLD | NEW |