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

Unified Diff: chromecast/net/connectivity_checker_impl.cc

Issue 2647323010: [Chromecast] Add proxy server support to chromecast (Closed)
Patch Set: Cleanup Created 3 years, 11 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 side-by-side diff with in-line comments
Download patch
Index: chromecast/net/connectivity_checker_impl.cc
diff --git a/chromecast/net/connectivity_checker_impl.cc b/chromecast/net/connectivity_checker_impl.cc
index b1b24eba9dc1f30eb8464738515fa3cab77764d0..9cfd494d8db99a6605000d2cd19e794aec1bc3a9 100644
--- a/chromecast/net/connectivity_checker_impl.cc
+++ b/chromecast/net/connectivity_checker_impl.cc
@@ -58,13 +58,15 @@ const char kMetricNameNetworkConnectivityCheckingErrorType[] =
} // namespace
ConnectivityCheckerImpl::ConnectivityCheckerImpl(
- const scoped_refptr<base::SingleThreadTaskRunner>& task_runner)
+ const scoped_refptr<base::SingleThreadTaskRunner>& task_runner,
+ net::ProxyConfig& proxy_config)
: ConnectivityChecker(),
task_runner_(task_runner),
connected_(false),
connection_type_(net::NetworkChangeNotifier::CONNECTION_NONE),
check_errors_(0),
- network_changed_pending_(false) {
+ network_changed_pending_(false),
+ proxy_config_(proxy_config) {
DCHECK(task_runner_.get());
task_runner->PostTask(FROM_HERE,
base::Bind(&ConnectivityCheckerImpl::Initialize, this));
@@ -80,8 +82,7 @@ void ConnectivityCheckerImpl::Initialize() {
net::URLRequestContextBuilder builder;
builder.set_proxy_config_service(
- base::MakeUnique<net::ProxyConfigServiceFixed>(
- net::ProxyConfig::CreateDirect()));
+ base::MakeUnique<net::ProxyConfigServiceFixed>(proxy_config_));
builder.DisableHttpCache();
url_request_context_ = builder.Build();
« chromecast/browser/cast_browser_process.cc ('K') | « chromecast/net/connectivity_checker_impl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698