Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "chrome/browser/ui/webui/options/chromeos/internet_options_handler.h" | 5 #include "chrome/browser/ui/webui/options/chromeos/internet_options_handler.h" |
| 6 | 6 |
| 7 #include <ctype.h> | 7 #include <ctype.h> |
| 8 | 8 |
| 9 #include <map> | 9 #include <map> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 226 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 237 DCHECK(localized_strings); | 237 DCHECK(localized_strings); |
| 238 internet_options_strings::RegisterLocalizedStrings(localized_strings); | 238 internet_options_strings::RegisterLocalizedStrings(localized_strings); |
| 239 | 239 |
| 240 // TODO(stevenjb): Find a better way to populate initial data before | 240 // TODO(stevenjb): Find a better way to populate initial data before |
| 241 // InitializePage() gets called. | 241 // InitializePage() gets called. |
| 242 std::string owner; | 242 std::string owner; |
| 243 chromeos::CrosSettings::Get()->GetString(chromeos::kDeviceOwner, &owner); | 243 chromeos::CrosSettings::Get()->GetString(chromeos::kDeviceOwner, &owner); |
| 244 bool logged_in_as_owner = LoginState::Get()->GetLoggedInUserType() == | 244 bool logged_in_as_owner = LoginState::Get()->GetLoggedInUserType() == |
| 245 LoginState::LOGGED_IN_USER_OWNER; | 245 LoginState::LOGGED_IN_USER_OWNER; |
| 246 localized_strings->SetBoolean(kLoggedInAsOwnerKey, logged_in_as_owner); | 246 localized_strings->SetBoolean(kLoggedInAsOwnerKey, logged_in_as_owner); |
| 247 localized_strings->SetBoolean( | 247 localized_strings->SetBoolean(kShowCarrierSelectKey, false); |
|
sky
2015/04/16 15:51:00
Is this still needed?
anujsharma
2015/04/17 13:41:05
I thought of removing it. But since "kShowCarrierS
stevenjb
2015/04/17 16:31:58
Please remove this here and from the JS, or add a
| |
| 248 kShowCarrierSelectKey, base::CommandLine::ForCurrentProcess()->HasSwitch( | |
| 249 chromeos::switches::kEnableCarrierSwitching)); | |
| 250 | 248 |
| 251 base::DictionaryValue* network_dictionary = new base::DictionaryValue; | 249 base::DictionaryValue* network_dictionary = new base::DictionaryValue; |
| 252 FillNetworkInfo(network_dictionary); | 250 FillNetworkInfo(network_dictionary); |
| 253 localized_strings->Set(kNetworkDataKey, network_dictionary); | 251 localized_strings->Set(kNetworkDataKey, network_dictionary); |
| 254 } | 252 } |
| 255 | 253 |
| 256 void InternetOptionsHandler::InitializePage() { | 254 void InternetOptionsHandler::InitializePage() { |
| 257 base::DictionaryValue dictionary; | 255 base::DictionaryValue dictionary; |
| 258 dictionary.SetString(::onc::network_type::kCellular, | 256 dictionary.SetString(::onc::network_type::kCellular, |
| 259 GetIconDataUrl(IDR_AURA_UBER_TRAY_NETWORK_BARS_DARK)); | 257 GetIconDataUrl(IDR_AURA_UBER_TRAY_NETWORK_BARS_DARK)); |
| (...skipping 544 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 804 dictionary->SetBoolean( | 802 dictionary->SetBoolean( |
| 805 kTagWimaxAvailable, | 803 kTagWimaxAvailable, |
| 806 handler->IsTechnologyAvailable(NetworkTypePattern::Wimax())); | 804 handler->IsTechnologyAvailable(NetworkTypePattern::Wimax())); |
| 807 dictionary->SetBoolean( | 805 dictionary->SetBoolean( |
| 808 kTagWimaxEnabled, | 806 kTagWimaxEnabled, |
| 809 handler->IsTechnologyEnabled(NetworkTypePattern::Wimax())); | 807 handler->IsTechnologyEnabled(NetworkTypePattern::Wimax())); |
| 810 } | 808 } |
| 811 | 809 |
| 812 } // namespace options | 810 } // namespace options |
| 813 } // namespace chromeos | 811 } // namespace chromeos |
| OLD | NEW |