diff options
author | brettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-01-21 04:55:52 +0000 |
---|---|---|
committer | brettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-01-21 04:55:52 +0000 |
commit | 20305ec6f1acf21392c2f3938a14a96f1e28e76d (patch) | |
tree | 6eff1f7be4bad1a1362d3466f0ac59292dc51acc /chrome/browser/history | |
parent | c6e8346b56ab61b35845aefcf9b241c654fe1253 (diff) | |
download | chromium_src-20305ec6f1acf21392c2f3938a14a96f1e28e76d.zip chromium_src-20305ec6f1acf21392c2f3938a14a96f1e28e76d.tar.gz chromium_src-20305ec6f1acf21392c2f3938a14a96f1e28e76d.tar.bz2 |
Remove obsolete base/lock.h and fix up callers to use the new header file and
the base namespace. Fix several files including lock.h unnecessarily.
BUG=none
TEST=none
Original review=http://codereview.chromium.org/6142009/
Patch by leviw@chromium.org
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@72106 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/history')
-rw-r--r-- | chrome/browser/history/top_sites.cc | 10 | ||||
-rw-r--r-- | chrome/browser/history/top_sites.h | 4 |
2 files changed, 7 insertions, 7 deletions
diff --git a/chrome/browser/history/top_sites.cc b/chrome/browser/history/top_sites.cc index ac0cc7c..e35aca3 100644 --- a/chrome/browser/history/top_sites.cc +++ b/chrome/browser/history/top_sites.cc @@ -217,7 +217,7 @@ void TopSites::GetMostVisitedURLs(CancelableRequestConsumer* consumer, AddRequest(request, consumer); MostVisitedURLList filtered_urls; { - AutoLock lock(lock_); + base::AutoLock lock(lock_); if (!loaded_) { // A request came in before we finished loading. Put the request in // pending_callbacks_ and we'll notify it when we finish loading. @@ -233,7 +233,7 @@ void TopSites::GetMostVisitedURLs(CancelableRequestConsumer* consumer, bool TopSites::GetPageThumbnail(const GURL& url, scoped_refptr<RefCountedBytes>* bytes) { // WARNING: this may be invoked on any thread. - AutoLock lock(lock_); + base::AutoLock lock(lock_); return thread_safe_cache_->GetPageThumbnail(url, bytes); } @@ -800,7 +800,7 @@ void TopSites::MoveStateToLoaded() { MostVisitedURLList filtered_urls; PendingCallbackSet pending_callbacks; { - AutoLock lock(lock_); + base::AutoLock lock(lock_); if (loaded_) return; // Don't do anything if we're already loaded. @@ -822,14 +822,14 @@ void TopSites::MoveStateToLoaded() { } void TopSites::ResetThreadSafeCache() { - AutoLock lock(lock_); + base::AutoLock lock(lock_); MostVisitedURLList cached; ApplyBlacklistAndPinnedURLs(cache_->top_sites(), &cached); thread_safe_cache_->SetTopSites(cached); } void TopSites::ResetThreadSafeImageCache() { - AutoLock lock(lock_); + base::AutoLock lock(lock_); thread_safe_cache_->SetThumbnails(cache_->images()); thread_safe_cache_->RemoveUnreferencedThumbnails(); } diff --git a/chrome/browser/history/top_sites.h b/chrome/browser/history/top_sites.h index 556bc131..00d2343 100644 --- a/chrome/browser/history/top_sites.h +++ b/chrome/browser/history/top_sites.h @@ -13,9 +13,9 @@ #include "base/basictypes.h" #include "base/gtest_prod_util.h" -#include "base/lock.h" #include "base/ref_counted.h" #include "base/ref_counted_memory.h" +#include "base/synchronization/lock.h" #include "base/time.h" #include "base/timer.h" #include "chrome/browser/cancelable_request.h" @@ -297,7 +297,7 @@ class TopSites Profile* profile_; // Lock used to access |thread_safe_cache_|. - mutable Lock lock_; + mutable base::Lock lock_; CancelableRequestConsumer cancelable_consumer_; |