Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "content/shell/browser/layout_test/layout_test_url_request_context_gett er.h" | 5 #include "content/shell/browser/layout_test/layout_test_url_request_context_gett er.h" |
| 6 | 6 |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "base/logging.h" | 8 #include "base/logging.h" |
| 9 #include "content/public/browser/browser_thread.h" | 9 #include "content/public/browser/browser_thread.h" |
| 10 #include "content/shell/browser/shell_network_delegate.h" | 10 #include "content/shell/browser/shell_network_delegate.h" |
| (...skipping 16 matching lines...) Expand all Loading... | |
| 27 protocol_handlers, | 27 protocol_handlers, |
| 28 request_interceptors.Pass(), | 28 request_interceptors.Pass(), |
| 29 net_log) { | 29 net_log) { |
| 30 // Must first be created on the UI thread. | 30 // Must first be created on the UI thread. |
| 31 DCHECK_CURRENTLY_ON(BrowserThread::UI); | 31 DCHECK_CURRENTLY_ON(BrowserThread::UI); |
| 32 } | 32 } |
| 33 | 33 |
| 34 LayoutTestURLRequestContextGetter::~LayoutTestURLRequestContextGetter() { | 34 LayoutTestURLRequestContextGetter::~LayoutTestURLRequestContextGetter() { |
| 35 } | 35 } |
| 36 | 36 |
| 37 net::NetworkDelegate* | 37 scoped_ptr<net::NetworkDelegate> |
| 38 LayoutTestURLRequestContextGetter::CreateNetworkDelegate() { | 38 LayoutTestURLRequestContextGetter::CreateNetworkDelegate() { |
| 39 ShellNetworkDelegate::SetAcceptAllCookies(false); | 39 ShellNetworkDelegate::SetAcceptAllCookies(false); |
| 40 return new ShellNetworkDelegate; | 40 return make_scoped_ptr(new ShellNetworkDelegate); |
| 41 } | 41 } |
| 42 | 42 |
| 43 net::ProxyConfigService* | 43 scoped_ptr<net::ProxyConfigService> |
| 44 LayoutTestURLRequestContextGetter::GetProxyConfigService() { | 44 LayoutTestURLRequestContextGetter::GetProxyConfigService() { |
| 45 return nullptr; | 45 return scoped_ptr<net::ProxyConfigService>(); |
|
davidben
2015/09/08 17:02:45
You can use nullptr here.
| |
| 46 } | 46 } |
| 47 | 47 |
| 48 net::ProxyService* LayoutTestURLRequestContextGetter::GetProxyService() { | 48 scoped_ptr<net::ProxyService> |
| 49 LayoutTestURLRequestContextGetter::GetProxyService() { | |
| 49 return net::ProxyService::CreateDirect(); | 50 return net::ProxyService::CreateDirect(); |
| 50 } | 51 } |
| 51 | 52 |
| 52 } // namespace content | 53 } // namespace content |
| OLD | NEW |