| Index: remoting/host/client_session.cc
|
| diff --git a/remoting/host/client_session.cc b/remoting/host/client_session.cc
|
| index 99c7ed509963a449f2a799cf36e044f4d7cbe00c..432ab211fa320e07ebd1b069c0017462cb4be7c1 100644
|
| --- a/remoting/host/client_session.cc
|
| +++ b/remoting/host/client_session.cc
|
| @@ -12,6 +12,7 @@
|
| #include "base/single_thread_task_runner.h"
|
| #include "base/threading/thread_task_runner_handle.h"
|
| #include "build/build_config.h"
|
| +#include "remoting/base/auto_thread_task_runner.h"
|
| #include "remoting/base/capabilities.h"
|
| #include "remoting/base/constants.h"
|
| #include "remoting/base/logging.h"
|
| @@ -60,8 +61,8 @@ std::unique_ptr<AudioEncoder> CreateAudioEncoder(
|
| } // namespace
|
|
|
| ClientSession::ClientSession(
|
| + const ChromotingHostContext& context,
|
| EventHandler* event_handler,
|
| - scoped_refptr<base::SingleThreadTaskRunner> audio_task_runner,
|
| std::unique_ptr<protocol::ConnectionToClient> connection,
|
| DesktopEnvironmentFactory* desktop_environment_factory,
|
| const base::TimeDelta& max_duration,
|
| @@ -78,12 +79,18 @@ ClientSession::ClientSession(
|
| disable_clipboard_filter_(clipboard_echo_filter_.host_filter()),
|
| client_clipboard_factory_(clipboard_echo_filter_.client_filter()),
|
| max_duration_(max_duration),
|
| - audio_task_runner_(audio_task_runner),
|
| + audio_task_runner_(context.audio_task_runner()),
|
| pairing_registry_(pairing_registry),
|
| // Note that |lossless_video_color_| defaults to true, but actually only
|
| // controls VP9 video stream color quality.
|
| lossless_video_color_(!base::CommandLine::ForCurrentProcess()->HasSwitch(
|
| kDisableI444SwitchName)),
|
| + power_save_blocker_(
|
| + device::PowerSaveBlocker::kPowerSaveBlockPreventDisplaySleep,
|
| + device::PowerSaveBlocker::kReasonVideoPlayback,
|
| + "Remoting session is active",
|
| + context.ui_task_runner(),
|
| + context.file_task_runner()),
|
| weak_factory_(this) {
|
| connection_->SetEventHandler(this);
|
|
|
|
|