| 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 #ifndef CHROMEOS_NETWORK_NETWORK_CHANGE_NOTIFIER_CHROMEOS_H_ | 5 #ifndef CHROMEOS_NETWORK_NETWORK_CHANGE_NOTIFIER_CHROMEOS_H_ |
| 6 #define CHROMEOS_NETWORK_NETWORK_CHANGE_NOTIFIER_CHROMEOS_H_ | 6 #define CHROMEOS_NETWORK_NETWORK_CHANGE_NOTIFIER_CHROMEOS_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 19 matching lines...) Expand all Loading... |
| 30 | 30 |
| 31 // Starts observing changes from the network state handler. | 31 // Starts observing changes from the network state handler. |
| 32 void Initialize(); | 32 void Initialize(); |
| 33 | 33 |
| 34 // Stops observing changes from the network state handler. | 34 // Stops observing changes from the network state handler. |
| 35 void Shutdown(); | 35 void Shutdown(); |
| 36 | 36 |
| 37 // NetworkChangeNotifier overrides. | 37 // NetworkChangeNotifier overrides. |
| 38 net::NetworkChangeNotifier::ConnectionType GetCurrentConnectionType() | 38 net::NetworkChangeNotifier::ConnectionType GetCurrentConnectionType() |
| 39 const override; | 39 const override; |
| 40 double GetCurrentMaxBandwidth() const override; | 40 double GetCurrentMaxBandwidthAndConnectionType( |
| 41 ConnectionType* connection_type) const override; |
| 41 | 42 |
| 42 // PowerManagerClient::Observer overrides. | 43 // PowerManagerClient::Observer overrides. |
| 43 void SuspendDone(const base::TimeDelta& sleep_duration) override; | 44 void SuspendDone(const base::TimeDelta& sleep_duration) override; |
| 44 | 45 |
| 45 // NetworkStateHandlerObserver overrides. | 46 // NetworkStateHandlerObserver overrides. |
| 46 void DefaultNetworkChanged( | 47 void DefaultNetworkChanged( |
| 47 const chromeos::NetworkState* default_network) override; | 48 const chromeos::NetworkState* default_network) override; |
| 48 | 49 |
| 49 private: | 50 private: |
| 50 FRIEND_TEST_ALL_PREFIXES(NetworkChangeNotifierChromeosTest, | 51 FRIEND_TEST_ALL_PREFIXES(NetworkChangeNotifierChromeosTest, |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 107 // For setting up network refresh polling callbacks. | 108 // For setting up network refresh polling callbacks. |
| 108 scoped_refptr<base::SingleThreadTaskRunner> task_runner_; | 109 scoped_refptr<base::SingleThreadTaskRunner> task_runner_; |
| 109 base::WeakPtrFactory<NetworkChangeNotifierChromeos> weak_ptr_factory_; | 110 base::WeakPtrFactory<NetworkChangeNotifierChromeos> weak_ptr_factory_; |
| 110 | 111 |
| 111 DISALLOW_COPY_AND_ASSIGN(NetworkChangeNotifierChromeos); | 112 DISALLOW_COPY_AND_ASSIGN(NetworkChangeNotifierChromeos); |
| 112 }; | 113 }; |
| 113 | 114 |
| 114 } // namespace chromeos | 115 } // namespace chromeos |
| 115 | 116 |
| 116 #endif // CHROMEOS_NETWORK_NETWORK_CHANGE_NOTIFIER_CHROMEOS_H_ | 117 #endif // CHROMEOS_NETWORK_NETWORK_CHANGE_NOTIFIER_CHROMEOS_H_ |
| OLD | NEW |