diff options
author | battre@chromium.org <battre@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-15 17:26:54 +0000 |
---|---|---|
committer | battre@chromium.org <battre@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-15 17:26:54 +0000 |
commit | d2d63be523cbd238e11e160d904bcb351fdfb9e8 (patch) | |
tree | cb4162162d4586ca4e9fd974f9f3744ba78f1bae /chrome/browser/browser_process_impl.cc | |
parent | 0997dbb61cacad042c452b37e03d4de5a0ed82bb (diff) | |
download | chromium_src-d2d63be523cbd238e11e160d904bcb351fdfb9e8.zip chromium_src-d2d63be523cbd238e11e160d904bcb351fdfb9e8.tar.gz chromium_src-d2d63be523cbd238e11e160d904bcb351fdfb9e8.tar.bz2 |
Extended: Add "system" URLRequestContext (not ready for use!)
This is an extension of http://codereview.chromium.org/6280018 that provides a proxy configuration which respects command line parameters and policies
BUG=67232,70732
TEST=Start chrome, observe two PROXY_CONFIG_CHANGED events in about:net-internals (if you are on a corporate network with PAC configurations), observe that everything behaves as usual. In particular the https://www.google.com/searchdomaincheck?format=domain&type=chrome request should not fail as it uses the new system URLRequestContext.
Review URL: http://codereview.chromium.org/6292017
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@78228 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/browser_process_impl.cc')
-rw-r--r-- | chrome/browser/browser_process_impl.cc | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/chrome/browser/browser_process_impl.cc b/chrome/browser/browser_process_impl.cc index 61dacf3..aff5fa7 100644 --- a/chrome/browser/browser_process_impl.cc +++ b/chrome/browser/browser_process_impl.cc @@ -54,6 +54,7 @@ #include "chrome/common/extensions/extension_l10n_util.h" #include "chrome/common/extensions/extension_resource.h" #include "chrome/common/json_pref_store.h" +#include "chrome/common/net/url_request_context_getter.h" #include "chrome/common/pref_names.h" #include "chrome/common/switch_utils.h" #include "chrome/common/url_constants.h" @@ -77,6 +78,10 @@ #include "content/common/child_process_messages.h" #endif +#if defined(OS_CHROMEOS) +#include "chrome/browser/chromeos/proxy_config_service_impl.h" +#endif // defined(OS_CHROMEOS) + #if (defined(OS_WIN) || defined(OS_LINUX)) && !defined(OS_CHROMEOS) // How often to check if the persistent instance of Chrome needs to restart // to install an update. @@ -438,6 +443,23 @@ ui::Clipboard* BrowserProcessImpl::clipboard() { return clipboard_.get(); } +URLRequestContextGetter* BrowserProcessImpl::system_request_context() { + DCHECK(CalledOnValidThread()); + return io_thread()->system_url_request_context_getter(); +} + +#if defined(OS_CHROMEOS) +chromeos::ProxyConfigServiceImpl* +BrowserProcessImpl::chromeos_proxy_config_service_impl() { + DCHECK(CalledOnValidThread()); + if (!chromeos_proxy_config_service_impl_) { + chromeos_proxy_config_service_impl_ = + new chromeos::ProxyConfigServiceImpl(); + } + return chromeos_proxy_config_service_impl_; +} +#endif // defined(OS_CHROMEOS) + ExtensionEventRouterForwarder* BrowserProcessImpl::extension_event_router_forwarder() { return extension_event_router_forwarder_.get(); |