diff options
author | willchan@chromium.org <willchan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-02-24 22:41:47 +0000 |
---|---|---|
committer | willchan@chromium.org <willchan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-02-24 22:41:47 +0000 |
commit | 6531594abea873c883782041fea5d126507497e1 (patch) | |
tree | 017227faab41fb16f84a2485ec9b03d3f783d132 /webkit/appcache/appcache_group.cc | |
parent | 60a782e6a5a80fbba8fe690f05502147ae998d8c (diff) | |
download | chromium_src-6531594abea873c883782041fea5d126507497e1.zip chromium_src-6531594abea873c883782041fea5d126507497e1.tar.gz chromium_src-6531594abea873c883782041fea5d126507497e1.tar.bz2 |
Switch NetworkChangeNotifier implementations to use ObserverList.
Fix up observer list so we can use FOR_EACH_OBSERVER when check_empty is set.
Clean up the ObserverList API a bit, replacing GetElementAt() with HasObserver() and Clear().
BUG=36590
Review URL: http://codereview.chromium.org/652205
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@39942 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/appcache/appcache_group.cc')
-rw-r--r-- | webkit/appcache/appcache_group.cc | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/webkit/appcache/appcache_group.cc b/webkit/appcache/appcache_group.cc index fd22563..8063b911 100644 --- a/webkit/appcache/appcache_group.cc +++ b/webkit/appcache/appcache_group.cc @@ -215,13 +215,7 @@ void AppCacheGroup::RunQueuedUpdates() { bool AppCacheGroup::FindObserver(UpdateObserver* find_me, const ObserverList<UpdateObserver>& observer_list) { - ObserverList<UpdateObserver>::Iterator it(observer_list); - UpdateObserver* obs; - while ((obs = it.GetNext()) != NULL) { - if (obs == find_me) - return true; - } - return false; + return observer_list.HasObserver(find_me); } void AppCacheGroup::ScheduleUpdateRestart(int delay_ms) { |