OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/net/network_change_notifier_chromeos.h" | 5 #include "chrome/browser/chromeos/net/network_change_notifier_chromeos.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "chrome/browser/chromeos/cros/cros_library.h" | 8 #include "chrome/browser/chromeos/cros/cros_library.h" |
9 #include "content/browser/browser_thread.h" | 9 #include "content/browser/browser_thread.h" |
10 | 10 |
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
89 chromeos::NetworkLibrary* lib = | 89 chromeos::NetworkLibrary* lib = |
90 chromeos::CrosLibrary::Get()->GetNetworkLibrary(); | 90 chromeos::CrosLibrary::Get()->GetNetworkLibrary(); |
91 lib->RemoveNetworkManagerObserver(this); | 91 lib->RemoveNetworkManagerObserver(this); |
92 lib->RemoveObserverForAllNetworks(this); | 92 lib->RemoveObserverForAllNetworks(this); |
93 | 93 |
94 chromeos::PowerLibrary* power = | 94 chromeos::PowerLibrary* power = |
95 chromeos::CrosLibrary::Get()->GetPowerLibrary(); | 95 chromeos::CrosLibrary::Get()->GetPowerLibrary(); |
96 power->RemoveObserver(this); | 96 power->RemoveObserver(this); |
97 } | 97 } |
98 | 98 |
99 void NetworkChangeNotifierChromeos::PowerChanged(PowerLibrary* obj) { | 99 void NetworkChangeNotifierChromeos::PowerChanged( |
| 100 const PowerSupplyStatus& status) { |
100 } | 101 } |
101 | 102 |
102 void NetworkChangeNotifierChromeos::SystemResumed() { | 103 void NetworkChangeNotifierChromeos::SystemResumed() { |
103 // Force invalidation of various net resources on system resume. | 104 // Force invalidation of various net resources on system resume. |
104 BrowserThread::PostTask( | 105 BrowserThread::PostTask( |
105 BrowserThread::IO, FROM_HERE, | 106 BrowserThread::IO, FROM_HERE, |
106 base::Bind( | 107 base::Bind( |
107 &NetworkChangeNotifier::NotifyObserversOfIPAddressChange)); | 108 &NetworkChangeNotifier::NotifyObserversOfIPAddressChange)); |
108 } | 109 } |
109 | 110 |
(...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
248 | 249 |
249 // static | 250 // static |
250 void NetworkChangeNotifierChromeos::UpdateInitialState( | 251 void NetworkChangeNotifierChromeos::UpdateInitialState( |
251 NetworkChangeNotifierChromeos* self) { | 252 NetworkChangeNotifierChromeos* self) { |
252 chromeos::NetworkLibrary* net = | 253 chromeos::NetworkLibrary* net = |
253 chromeos::CrosLibrary::Get()->GetNetworkLibrary(); | 254 chromeos::CrosLibrary::Get()->GetNetworkLibrary(); |
254 self->UpdateNetworkState(net); | 255 self->UpdateNetworkState(net); |
255 } | 256 } |
256 | 257 |
257 } // namespace net | 258 } // namespace net |
OLD | NEW |