summaryrefslogtreecommitdiffstats
path: root/net/base/network_change_notifier_win.h
diff options
context:
space:
mode:
Diffstat (limited to 'net/base/network_change_notifier_win.h')
-rw-r--r--net/base/network_change_notifier_win.h16
1 files changed, 5 insertions, 11 deletions
diff --git a/net/base/network_change_notifier_win.h b/net/base/network_change_notifier_win.h
index 0f1f8d4..b11ec0d 100644
--- a/net/base/network_change_notifier_win.h
+++ b/net/base/network_change_notifier_win.h
@@ -7,8 +7,7 @@
#include "base/basictypes.h"
#include "base/object_watcher.h"
-#include "base/observer_list.h"
-#include "net/base/network_change_notifier.h"
+#include "net/base/network_change_notifier_helper.h"
namespace net {
@@ -17,19 +16,16 @@ class NetworkChangeNotifierWin : public NetworkChangeNotifier {
NetworkChangeNotifierWin();
// Called by NetworkChangeNotifierWin::Impl.
- void OnIPAddressChanged() {
- FOR_EACH_OBSERVER(Observer, observers_, OnIPAddressChanged());
- }
-
+ void OnIPAddressChanged() { helper_.OnIPAddressChanged(); }
// NetworkChangeNotifier methods:
virtual void AddObserver(Observer* observer) {
- observers_.AddObserver(observer);
+ helper_.AddObserver(observer);
}
virtual void RemoveObserver(Observer* observer) {
- observers_.RemoveObserver(observer);
+ helper_.RemoveObserver(observer);
}
private:
@@ -37,9 +33,7 @@ class NetworkChangeNotifierWin : public NetworkChangeNotifier {
virtual ~NetworkChangeNotifierWin();
- // TODO(willchan): Fix the URLRequestContextGetter leaks and flip the false to
- // true so we assert that all observers have been removed.
- ObserverList<Observer, false> observers_;
+ internal::NetworkChangeNotifierHelper helper_;
scoped_ptr<Impl> impl_;
DISALLOW_COPY_AND_ASSIGN(NetworkChangeNotifierWin);