Chromium Code Reviews| Index: chrome/browser/ui/webui/options/chromeos/internet_options_handler.cc |
| diff --git a/chrome/browser/ui/webui/options/chromeos/internet_options_handler.cc b/chrome/browser/ui/webui/options/chromeos/internet_options_handler.cc |
| index cccdc5443035d0b1f2356b1434b26f7d01b0d9d7..632195afcc28c1f07998768a2bf879b7f26d3a70 100644 |
| --- a/chrome/browser/ui/webui/options/chromeos/internet_options_handler.cc |
| +++ b/chrome/browser/ui/webui/options/chromeos/internet_options_handler.cc |
| @@ -29,9 +29,11 @@ |
| #include "chrome/browser/chromeos/login/user_manager.h" |
| #include "chrome/browser/chromeos/mobile_config.h" |
| #include "chrome/browser/chromeos/options/network_config_view.h" |
| +#include "chrome/browser/chromeos/proxy_config_service_impl.h" |
| #include "chrome/browser/chromeos/sim_dialog_delegate.h" |
| #include "chrome/browser/chromeos/status/network_menu_icon.h" |
| #include "chrome/browser/chromeos/user_cros_settings_provider.h" |
| +#include "chrome/browser/net/pref_proxy_config_tracker.h" |
|
kuan
2011/11/10 14:27:25
u don't need this, 'cos it's included by proxy_con
pastarmovj
2011/11/10 16:08:26
Again I think that we need to include whatever we
|
| #include "chrome/browser/profiles/profile.h" |
| #include "chrome/browser/ui/browser.h" |
| #include "chrome/browser/ui/browser_list.h" |
| @@ -54,8 +56,7 @@ |
| static const char kOtherNetworksFakePath[] = "?"; |
| InternetOptionsHandler::InternetOptionsHandler() |
| - : chromeos::CrosOptionsPageUIHandler(NULL), |
| - proxy_settings_(NULL) { |
| + : chromeos::CrosOptionsPageUIHandler(NULL) { |
| registrar_.Add(this, chrome::NOTIFICATION_REQUIRE_PIN_SETTING_CHANGE_ENDED, |
| content::NotificationService::AllSources()); |
| registrar_.Add(this, chrome::NOTIFICATION_ENTER_PIN_ENDED, |
| @@ -690,8 +691,10 @@ void InternetOptionsHandler::SetIPConfigCallback(const ListValue* args) { |
| void InternetOptionsHandler::PopulateDictionaryDetails( |
| const chromeos::Network* network) { |
| DCHECK(network); |
| - if (proxy_settings()) |
| - proxy_settings()->SetCurrentNetwork(network->service_path()); |
| + |
| + Profile::FromWebUI(web_ui_)->GetProxyConfigTracker()->UISetCurrentNetwork( |
|
kuan
2011/11/10 14:27:25
i think u need to check "if (web_ui_)"; i vaguely
pastarmovj
2011/11/10 16:08:26
Done.
|
| + network->service_path()); |
| + |
| DictionaryValue dictionary; |
| std::string hardware_address; |
| chromeos::NetworkIPConfigVector ipconfigs = cros_->GetIPConfigs( |
| @@ -775,16 +778,6 @@ void InternetOptionsHandler::PopulateDictionaryDetails( |
| "options.InternetOptions.showDetailedInfo", dictionary); |
| } |
| -chromeos::ProxyCrosSettingsProvider* InternetOptionsHandler::proxy_settings() { |
| - if (!proxy_settings_) { |
| - proxy_settings_ = static_cast<chromeos::ProxyCrosSettingsProvider*>( |
| - chromeos::CrosSettings::Get()->GetProvider("cros.session.proxy")); |
| - if (!proxy_settings_) |
| - NOTREACHED() << "Error getting access to proxy cros settings provider"; |
| - } |
| - return proxy_settings_; |
| -} |
| - |
| void InternetOptionsHandler::PopulateWifiDetails( |
| const chromeos::WifiNetwork* wifi, |
| DictionaryValue* dictionary) { |