OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/chromeos/login/network_screen.h" | 5 #include "chrome/browser/chromeos/login/network_screen.h" |
6 | 6 |
7 #include "app/l10n_util.h" | 7 #include "app/l10n_util.h" |
8 #include "base/utf_string_conversions.h" | 8 #include "base/utf_string_conversions.h" |
9 #include "base/logging.h" | 9 #include "base/logging.h" |
10 #include "chrome/browser/chromeos/cros/cros_library.h" | 10 #include "chrome/browser/chromeos/cros/cros_library.h" |
(...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
214 if (network && | 214 if (network && |
215 !networks_.IsNetworkConnected(type, id)) { | 215 !networks_.IsNetworkConnected(type, id)) { |
216 if (NetworkList::NETWORK_WIFI == network->network_type) { | 216 if (NetworkList::NETWORK_WIFI == network->network_type) { |
217 if (network->wifi_network.encrypted()) { | 217 if (network->wifi_network.encrypted()) { |
218 OpenPasswordDialog(network->wifi_network); | 218 OpenPasswordDialog(network->wifi_network); |
219 return; | 219 return; |
220 } else { | 220 } else { |
221 WaitForConnection(network); | 221 WaitForConnection(network); |
222 chromeos::CrosLibrary::Get()->GetNetworkLibrary()-> | 222 chromeos::CrosLibrary::Get()->GetNetworkLibrary()-> |
223 ConnectToWifiNetwork(network->wifi_network, | 223 ConnectToWifiNetwork(network->wifi_network, |
224 string16(), string16(), string16()); | 224 std::string(), std::string(), std::string()); |
225 } | 225 } |
226 } else if (NetworkList::NETWORK_CELLULAR == network->network_type) { | 226 } else if (NetworkList::NETWORK_CELLULAR == network->network_type) { |
227 WaitForConnection(network); | 227 WaitForConnection(network); |
228 chromeos::CrosLibrary::Get()->GetNetworkLibrary()-> | 228 chromeos::CrosLibrary::Get()->GetNetworkLibrary()-> |
229 ConnectToCellularNetwork(network->cellular_network); | 229 ConnectToCellularNetwork(network->cellular_network); |
230 } | 230 } |
231 } | 231 } |
232 } | 232 } |
233 | 233 |
234 void NetworkScreen::EnableWiFi() { | 234 void NetworkScreen::EnableWiFi() { |
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
319 if (connection_timer_.IsRunning()) | 319 if (connection_timer_.IsRunning()) |
320 connection_timer_.Stop(); | 320 connection_timer_.Stop(); |
321 connection_timer_.Start(base::TimeDelta::FromSeconds(kConnectionTimeoutSec), | 321 connection_timer_.Start(base::TimeDelta::FromSeconds(kConnectionTimeoutSec), |
322 this, | 322 this, |
323 &NetworkScreen::OnConnectionTimeout); | 323 &NetworkScreen::OnConnectionTimeout); |
324 if (continue_pressed_) | 324 if (continue_pressed_) |
325 ShowConnectingStatus(); | 325 ShowConnectingStatus(); |
326 } | 326 } |
327 | 327 |
328 } // namespace chromeos | 328 } // namespace chromeos |
OLD | NEW |