From e9b8d0afc364a922a064ac88ad656fcec6c703de Mon Sep 17 00:00:00 2001 From: "eroman@chromium.org" Date: Tue, 17 Aug 2010 04:10:29 +0000 Subject: Watch the Internet Explorer registry keys so we can detect proxy settings changes faster. Previously we would poll on a background thread every 5 seconds (triggered by network activity) to check for changes. This meant there was a 5 second window during which new requests might still be using the old settings. With this CL, the settings are noticed almost immediately and the continuous polling is de-emphasized. (We still poll, but less often. This is a precaution since we are relying on implementation details of a winhttp function, and can't be sure it won't change in the future, or is even completely accurate right now). BUG=52120 TEST=Open chrome://net-internals/#requests. Request some webpage. Now make changes to the Internet explorer proxy settinsg. You should see a PROXY_CONFIG_CHANGED event emitted immediately after saving each change in the dialog box. Review URL: http://codereview.chromium.org/3161016 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@56305 0039d316-1c4b-4281-b951-d872f2087c98 --- net/proxy/polling_proxy_config_service.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'net/proxy/polling_proxy_config_service.h') diff --git a/net/proxy/polling_proxy_config_service.h b/net/proxy/polling_proxy_config_service.h index 455359a..b4295ec 100644 --- a/net/proxy/polling_proxy_config_service.h +++ b/net/proxy/polling_proxy_config_service.h @@ -40,6 +40,9 @@ class PollingProxyConfigService : public ProxyConfigService { virtual ~PollingProxyConfigService(); + // Polls for changes by posting a task to the worker pool. + void CheckForChangesNow(); + private: class Core; scoped_refptr core_; -- cgit v1.1