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

Side by Side Diff: remoting/host/win/session_desktop_environment_factory.cc

Issue 10920019: [Chromoting] Refactoring DesktopEnvironment and moving screen/audio recorders to ClientSession. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 3 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
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #include "remoting/host/win/session_desktop_environment_factory.h"
6
7 #include "remoting/host/audio_capturer.h"
8 #include "remoting/host/chromoting_host_context.h"
9 #include "remoting/host/desktop_environment.h"
10 #include "remoting/host/event_executor.h"
11 #include "remoting/host/video_frame_capturer.h"
12
13 #if defined(OS_WIN)
14 #include "remoting/host/win/session_event_executor.h"
15 #endif // defined(OS_WIN)
16
17 namespace remoting {
18
19 SessionDesktopEnvironmentFactory::SessionDesktopEnvironmentFactory() {
20 }
21
22 SessionDesktopEnvironmentFactory::~SessionDesktopEnvironmentFactory() {
23 }
24
25 scoped_ptr<DesktopEnvironment> SessionDesktopEnvironmentFactory::Create(
26 ChromotingHostContext* context) {
27 #if defined(OS_WIN)
Wez 2012/08/31 18:18:02 This only gets build on Windows, so I don't think
alexeypa (please no reviews) 2012/08/31 23:13:30 Done.
28 scoped_ptr<AudioCapturer> audio_capturer = AudioCapturer::Create();
29 scoped_ptr<EventExecutor> event_executor = EventExecutor::Create(
30 context->desktop_task_runner(),
31 context->ui_task_runner());
32 event_executor.reset(new SessionEventExecutorWin(
33 context->desktop_task_runner(),
34 event_executor.Pass()));
35 scoped_ptr<VideoFrameCapturer> video_capturer(VideoFrameCapturer::Create());
36 return scoped_ptr<DesktopEnvironment>(new DesktopEnvironment(
37 audio_capturer.Pass(),
38 event_executor.Pass(),
39 video_capturer.Pass()));
simonmorris 2012/09/04 18:47:21 This duplicates code, and it's confusing to have c
alexeypa (please no reviews) 2012/09/05 22:53:29 It is Windows-only code. #if defined(OS_WIN) shoul
Wez 2012/09/06 00:13:22 Chaining should work for the IPC stubs depending o
40 #else // !defined(OS_WIN)
41 return DesktopEnvironmentFactory::Create(context);
42 #endif // !defined(OS_WIN)
43 }
44
45 } // namespace remoting
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698