Chromium Code Reviews| 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/client_session.h" | 5 #include "remoting/host/client_session.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 | 8 |
| 9 #include "base/message_loop/message_loop_proxy.h" | 9 #include "base/message_loop/message_loop_proxy.h" |
| 10 #include "remoting/base/capabilities.h" | 10 #include "remoting/base/capabilities.h" |
| 11 #include "remoting/base/logging.h" | 11 #include "remoting/base/logging.h" |
| 12 #include "remoting/codec/audio_encoder.h" | 12 #include "remoting/codec/audio_encoder.h" |
| 13 #include "remoting/codec/audio_encoder_opus.h" | 13 #include "remoting/codec/audio_encoder_opus.h" |
| 14 #include "remoting/codec/audio_encoder_verbatim.h" | 14 #include "remoting/codec/audio_encoder_verbatim.h" |
| 15 #include "remoting/codec/video_encoder.h" | 15 #include "remoting/codec/video_encoder.h" |
| 16 #include "remoting/codec/video_encoder_verbatim.h" | 16 #include "remoting/codec/video_encoder_verbatim.h" |
| 17 #include "remoting/codec/video_encoder_vpx.h" | 17 #include "remoting/codec/video_encoder_vpx.h" |
| 18 #include "remoting/host/audio_capturer.h" | 18 #include "remoting/host/audio_capturer.h" |
| 19 #include "remoting/host/audio_scheduler.h" | 19 #include "remoting/host/audio_scheduler.h" |
| 20 #include "remoting/host/desktop_environment.h" | 20 #include "remoting/host/desktop_environment.h" |
| 21 #include "remoting/host/display_rotation_filter.h" | |
| 21 #include "remoting/host/host_extension_session.h" | 22 #include "remoting/host/host_extension_session.h" |
| 22 #include "remoting/host/input_injector.h" | 23 #include "remoting/host/input_injector.h" |
| 23 #include "remoting/host/screen_controls.h" | 24 #include "remoting/host/screen_controls.h" |
| 24 #include "remoting/host/screen_resolution.h" | 25 #include "remoting/host/screen_resolution.h" |
| 25 #include "remoting/host/video_scheduler.h" | 26 #include "remoting/host/video_scheduler.h" |
| 26 #include "remoting/proto/control.pb.h" | 27 #include "remoting/proto/control.pb.h" |
| 27 #include "remoting/proto/event.pb.h" | 28 #include "remoting/proto/event.pb.h" |
| 28 #include "remoting/protocol/client_stub.h" | 29 #include "remoting/protocol/client_stub.h" |
| 29 #include "remoting/protocol/clipboard_thread_proxy.h" | 30 #include "remoting/protocol/clipboard_thread_proxy.h" |
| 30 #include "remoting/protocol/pairing_registry.h" | 31 #include "remoting/protocol/pairing_registry.h" |
| (...skipping 16 matching lines...) Expand all Loading... | |
| 47 DesktopEnvironmentFactory* desktop_environment_factory, | 48 DesktopEnvironmentFactory* desktop_environment_factory, |
| 48 const base::TimeDelta& max_duration, | 49 const base::TimeDelta& max_duration, |
| 49 scoped_refptr<protocol::PairingRegistry> pairing_registry, | 50 scoped_refptr<protocol::PairingRegistry> pairing_registry, |
| 50 const std::vector<HostExtension*>& extensions) | 51 const std::vector<HostExtension*>& extensions) |
| 51 : event_handler_(event_handler), | 52 : event_handler_(event_handler), |
| 52 connection_(connection.Pass()), | 53 connection_(connection.Pass()), |
| 53 client_jid_(connection_->session()->jid()), | 54 client_jid_(connection_->session()->jid()), |
| 54 desktop_environment_factory_(desktop_environment_factory), | 55 desktop_environment_factory_(desktop_environment_factory), |
| 55 input_tracker_(&host_input_filter_), | 56 input_tracker_(&host_input_filter_), |
| 56 remote_input_filter_(&input_tracker_), | 57 remote_input_filter_(&input_tracker_), |
| 57 mouse_clamping_filter_(&remote_input_filter_), | 58 display_rotation_filter_( |
| 59 CreateDisplayRotationFilter(&remote_input_filter_)), | |
|
Wez
2014/11/26 02:28:34
This feels like a property of the DesktopEnvironme
kelvinp
2014/12/02 00:12:26
Done.
kelvinp
2014/12/02 00:12:26
Done.
| |
| 60 mouse_clamping_filter_(display_rotation_filter_.get()), | |
|
Wez
2014/11/26 02:28:34
Use *display_rotation_filter_ here. In general, av
kelvinp
2014/12/02 00:12:26
*display_rotation_filter_ returns an InputStub&,
| |
| 58 disable_input_filter_(mouse_clamping_filter_.input_filter()), | 61 disable_input_filter_(mouse_clamping_filter_.input_filter()), |
| 59 disable_clipboard_filter_(clipboard_echo_filter_.host_filter()), | 62 disable_clipboard_filter_(clipboard_echo_filter_.host_filter()), |
| 60 auth_input_filter_(&disable_input_filter_), | 63 auth_input_filter_(&disable_input_filter_), |
| 61 auth_clipboard_filter_(&disable_clipboard_filter_), | 64 auth_clipboard_filter_(&disable_clipboard_filter_), |
| 62 client_clipboard_factory_(clipboard_echo_filter_.client_filter()), | 65 client_clipboard_factory_(clipboard_echo_filter_.client_filter()), |
| 63 max_duration_(max_duration), | 66 max_duration_(max_duration), |
| 64 audio_task_runner_(audio_task_runner), | 67 audio_task_runner_(audio_task_runner), |
| 65 input_task_runner_(input_task_runner), | 68 input_task_runner_(input_task_runner), |
| 66 video_capture_task_runner_(video_capture_task_runner), | 69 video_capture_task_runner_(video_capture_task_runner), |
| 67 video_encode_task_runner_(video_encode_task_runner), | 70 video_encode_task_runner_(video_encode_task_runner), |
| (...skipping 445 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 513 return make_scoped_ptr(new AudioEncoderVerbatim()); | 516 return make_scoped_ptr(new AudioEncoderVerbatim()); |
| 514 } else if (audio_config.codec == protocol::ChannelConfig::CODEC_OPUS) { | 517 } else if (audio_config.codec == protocol::ChannelConfig::CODEC_OPUS) { |
| 515 return make_scoped_ptr(new AudioEncoderOpus()); | 518 return make_scoped_ptr(new AudioEncoderOpus()); |
| 516 } | 519 } |
| 517 | 520 |
| 518 NOTREACHED(); | 521 NOTREACHED(); |
| 519 return nullptr; | 522 return nullptr; |
| 520 } | 523 } |
| 521 | 524 |
| 522 } // namespace remoting | 525 } // namespace remoting |
| OLD | NEW |