OLD | NEW |
(Empty) | |
| 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 |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef CHROME_BROWSER_CHROMEOS_NETWORK_LOGIN_OBSERVER_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_NETWORK_LOGIN_OBSERVER_H_ |
| 7 #pragma once |
| 8 |
| 9 #include <map> |
| 10 #include <string> |
| 11 |
| 12 #include "base/basictypes.h" |
| 13 #include "chrome/browser/chromeos/cros/network_library.h" |
| 14 |
| 15 namespace views { |
| 16 class WindowDelegate; |
| 17 } |
| 18 |
| 19 namespace chromeos { |
| 20 |
| 21 // The network login observer reshows a login dialog if there was an error. |
| 22 |
| 23 class NetworkLoginObserver : public NetworkLibrary::NetworkManagerObserver { |
| 24 public: |
| 25 explicit NetworkLoginObserver(NetworkLibrary* netlib); |
| 26 virtual ~NetworkLoginObserver(); |
| 27 |
| 28 typedef std::map<std::string, bool> WifiFailureMap; |
| 29 private: |
| 30 virtual void CreateModalPopup(views::WindowDelegate* view); |
| 31 |
| 32 virtual void RefreshStoredNetworks(const WifiNetworkVector& wifi_networks); |
| 33 |
| 34 // NetworkLibrary::NetworkManagerObserver implementation. |
| 35 virtual void OnNetworkManagerChanged(NetworkLibrary* obj); |
| 36 |
| 37 // Wifi networks by service path mapped to if it failed previously. |
| 38 WifiFailureMap wifi_network_failures_; |
| 39 |
| 40 DISALLOW_COPY_AND_ASSIGN(NetworkLoginObserver); |
| 41 }; |
| 42 |
| 43 } // namespace chromeos |
| 44 |
| 45 #endif // CHROME_BROWSER_CHROMEOS_NETWORK_LOGIN_OBSERVER_H_ |
OLD | NEW |