| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "athena/system/network_selector.h" | 5 #include "athena/system/network_selector.h" |
| 6 | 6 |
| 7 #include "athena/screen/public/screen_manager.h" | 7 #include "athena/screen/public/screen_manager.h" |
| 8 #include "base/memory/weak_ptr.h" | 8 #include "base/memory/weak_ptr.h" |
| 9 #include "base/strings/utf_string_conversions.h" | 9 #include "base/strings/utf_string_conversions.h" |
| 10 #include "chromeos/network/network_configuration_handler.h" | 10 #include "chromeos/network/network_configuration_handler.h" |
| (...skipping 244 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 255 PreferredSizeChanged(); | 255 PreferredSizeChanged(); |
| 256 GetWidget()->GetRootView()->Layout(); | 256 GetWidget()->GetRootView()->Layout(); |
| 257 ScrollRectToVisible(password_view_->bounds()); | 257 ScrollRectToVisible(password_view_->bounds()); |
| 258 } | 258 } |
| 259 | 259 |
| 260 void OnNetworkConnectionError(const std::string& service_path, | 260 void OnNetworkConnectionError(const std::string& service_path, |
| 261 const std::string& error_name, | 261 const std::string& error_name, |
| 262 scoped_ptr<base::DictionaryValue> error_data) { | 262 scoped_ptr<base::DictionaryValue> error_data) { |
| 263 if (error_name == NetworkConnectionHandler::kErrorConnectCanceled) | 263 if (error_name == NetworkConnectionHandler::kErrorConnectCanceled) |
| 264 return; | 264 return; |
| 265 if (error_name == shill::kErrorBadPassphrase || | 265 if (error_name == NetworkConnectionHandler::kErrorBadPassphrase || |
| 266 error_name == NetworkConnectionHandler::kErrorPassphraseRequired || | 266 error_name == NetworkConnectionHandler::kErrorPassphraseRequired || |
| 267 error_name == NetworkConnectionHandler::kErrorConfigurationRequired || | 267 error_name == NetworkConnectionHandler::kErrorConfigurationRequired || |
| 268 error_name == NetworkConnectionHandler::kErrorAuthenticationRequired) { | 268 error_name == NetworkConnectionHandler::kErrorAuthenticationRequired) { |
| 269 ShowPasswordView(service_path); | 269 ShowPasswordView(service_path); |
| 270 } | 270 } |
| 271 } | 271 } |
| 272 | 272 |
| 273 void ActivateNetwork() { | 273 void ActivateNetwork() { |
| 274 const chromeos::NetworkState* network = | 274 const chromeos::NetworkState* network = |
| 275 NetworkHandler::Get()->network_state_handler()->GetNetworkState( | 275 NetworkHandler::Get()->network_state_handler()->GetNetworkState( |
| (...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 427 | 427 |
| 428 } // namespace | 428 } // namespace |
| 429 | 429 |
| 430 namespace athena { | 430 namespace athena { |
| 431 | 431 |
| 432 void CreateNetworkSelector() { | 432 void CreateNetworkSelector() { |
| 433 new NetworkSelector(); | 433 new NetworkSelector(); |
| 434 } | 434 } |
| 435 | 435 |
| 436 } // namespace athena | 436 } // namespace athena |
| OLD | NEW |