diff options
Diffstat (limited to 'toolkit/system/windowsproxy/nsWindowsSystemProxySettings.cpp')
-rw-r--r-- | toolkit/system/windowsproxy/nsWindowsSystemProxySettings.cpp | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/toolkit/system/windowsproxy/nsWindowsSystemProxySettings.cpp b/toolkit/system/windowsproxy/nsWindowsSystemProxySettings.cpp index 7921cb60a2..94487505c3 100644 --- a/toolkit/system/windowsproxy/nsWindowsSystemProxySettings.cpp +++ b/toolkit/system/windowsproxy/nsWindowsSystemProxySettings.cpp @@ -241,6 +241,19 @@ nsresult nsWindowsSystemProxySettings::GetProxyForURI(const nsACString& aSpec, return NS_OK; } +NS_IMETHODIMP nsWindowsSystemProxySettings::GetSystemWPADSetting( + bool* aSystemWPADSetting) { + nsresult rv; + uint32_t flags = 0; + nsAutoString buf; + + rv = ReadInternetOption(INTERNET_PER_CONN_AUTOCONFIG_URL, flags, buf); + *aSystemWPADSetting = + (flags & (PROXY_TYPE_AUTO_PROXY_URL | PROXY_TYPE_AUTO_DETECT)) == + PROXY_TYPE_AUTO_DETECT; + return rv; +} + NS_IMPL_COMPONENT_FACTORY(nsWindowsSystemProxySettings) { return mozilla::MakeAndAddRef<nsWindowsSystemProxySettings>() .downcast<nsISupports>(); |