| 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/plugin/host_script_object.h" | 5 #include "remoting/host/plugin/host_script_object.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/json/json_reader.h" | 8 #include "base/json/json_reader.h" |
| 9 #include "base/json/json_writer.h" | 9 #include "base/json/json_writer.h" |
| 10 #include "base/message_loop.h" | 10 #include "base/message_loop.h" |
| (...skipping 355 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 366 network_settings.min_port = NetworkSettings::kDefaultMinPort; | 366 network_settings.min_port = NetworkSettings::kDefaultMinPort; |
| 367 network_settings.max_port = NetworkSettings::kDefaultMaxPort; | 367 network_settings.max_port = NetworkSettings::kDefaultMaxPort; |
| 368 } | 368 } |
| 369 | 369 |
| 370 // Create the host. | 370 // Create the host. |
| 371 host_ = new ChromotingHost( | 371 host_ = new ChromotingHost( |
| 372 signal_strategy_.get(), | 372 signal_strategy_.get(), |
| 373 desktop_environment_factory_.get(), | 373 desktop_environment_factory_.get(), |
| 374 CreateHostSessionManager(network_settings, | 374 CreateHostSessionManager(network_settings, |
| 375 host_context_->url_request_context_getter()), | 375 host_context_->url_request_context_getter()), |
| 376 host_context_->audio_task_runner(), |
| 376 host_context_->capture_task_runner(), | 377 host_context_->capture_task_runner(), |
| 377 host_context_->encode_task_runner(), | 378 host_context_->encode_task_runner(), |
| 378 host_context_->network_task_runner()); | 379 host_context_->network_task_runner()); |
| 379 host_->AddStatusObserver(this); | 380 host_->AddStatusObserver(this); |
| 380 log_to_server_.reset( | 381 log_to_server_.reset( |
| 381 new LogToServer(host_, ServerLogEntry::IT2ME, signal_strategy_.get())); | 382 new LogToServer(host_, ServerLogEntry::IT2ME, signal_strategy_.get())); |
| 382 | 383 |
| 383 // Disable audio by default. | 384 // Disable audio by default. |
| 384 // TODO(sergeyu): Add UI to enable it. | 385 // TODO(sergeyu): Add UI to enable it. |
| 385 scoped_ptr<protocol::CandidateSessionConfig> protocol_config = | 386 scoped_ptr<protocol::CandidateSessionConfig> protocol_config = |
| (...skipping 1132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1518 } | 1519 } |
| 1519 | 1520 |
| 1520 void HostNPScriptObject::SetException(const std::string& exception_string) { | 1521 void HostNPScriptObject::SetException(const std::string& exception_string) { |
| 1521 DCHECK(plugin_task_runner_->BelongsToCurrentThread()); | 1522 DCHECK(plugin_task_runner_->BelongsToCurrentThread()); |
| 1522 | 1523 |
| 1523 g_npnetscape_funcs->setexception(parent_, exception_string.c_str()); | 1524 g_npnetscape_funcs->setexception(parent_, exception_string.c_str()); |
| 1524 LOG(INFO) << exception_string; | 1525 LOG(INFO) << exception_string; |
| 1525 } | 1526 } |
| 1526 | 1527 |
| 1527 } // namespace remoting | 1528 } // namespace remoting |
| OLD | NEW |