Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(663)

Unified Diff: chrome/browser/history/history_service.cc

Issue 15984016: Call scoped_refptr<T>::get() rather than relying on implicit "operator T*" (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased Created 7 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/favicon/favicon_service.cc ('k') | chrome/browser/history/shortcuts_backend_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/history/history_service.cc
diff --git a/chrome/browser/history/history_service.cc b/chrome/browser/history/history_service.cc
index a2021b567d2cc783951eae5af8ec02b2ff16fcea..1e4361ab12de01e527621b6ae0687cbd73f795ef 100644
--- a/chrome/browser/history/history_service.cc
+++ b/chrome/browser/history/history_service.cc
@@ -629,11 +629,15 @@ CancelableTaskTracker::TaskId HistoryService::GetFavicons(
std::vector<chrome::FaviconBitmapResult>* results =
new std::vector<chrome::FaviconBitmapResult>();
return tracker->PostTaskAndReply(
- thread_->message_loop_proxy(),
+ thread_->message_loop_proxy().get(),
FROM_HERE,
base::Bind(&HistoryBackend::GetFavicons,
- history_backend_.get(), icon_urls, icon_types,
- desired_size_in_dip, desired_scale_factors, results),
+ history_backend_.get(),
+ icon_urls,
+ icon_types,
+ desired_size_in_dip,
+ desired_scale_factors,
+ results),
base::Bind(&RunWithFaviconResults, callback, base::Owned(results)));
}
@@ -650,11 +654,15 @@ CancelableTaskTracker::TaskId HistoryService::GetFaviconsForURL(
std::vector<chrome::FaviconBitmapResult>* results =
new std::vector<chrome::FaviconBitmapResult>();
return tracker->PostTaskAndReply(
- thread_->message_loop_proxy(),
+ thread_->message_loop_proxy().get(),
FROM_HERE,
base::Bind(&HistoryBackend::GetFaviconsForURL,
- history_backend_.get(), page_url, icon_types,
- desired_size_in_dip, desired_scale_factors, results),
+ history_backend_.get(),
+ page_url,
+ icon_types,
+ desired_size_in_dip,
+ desired_scale_factors,
+ results),
base::Bind(&RunWithFaviconResults, callback, base::Owned(results)));
}
@@ -670,11 +678,14 @@ CancelableTaskTracker::TaskId HistoryService::GetFaviconForID(
std::vector<chrome::FaviconBitmapResult>* results =
new std::vector<chrome::FaviconBitmapResult>();
return tracker->PostTaskAndReply(
- thread_->message_loop_proxy(),
+ thread_->message_loop_proxy().get(),
FROM_HERE,
base::Bind(&HistoryBackend::GetFaviconForID,
- history_backend_.get(), favicon_id,
- desired_size_in_dip, desired_scale_factor, results),
+ history_backend_.get(),
+ favicon_id,
+ desired_size_in_dip,
+ desired_scale_factor,
+ results),
base::Bind(&RunWithFaviconResults, callback, base::Owned(results)));
}
@@ -692,11 +703,16 @@ CancelableTaskTracker::TaskId HistoryService::UpdateFaviconMappingsAndFetch(
std::vector<chrome::FaviconBitmapResult>* results =
new std::vector<chrome::FaviconBitmapResult>();
return tracker->PostTaskAndReply(
- thread_->message_loop_proxy(),
+ thread_->message_loop_proxy().get(),
FROM_HERE,
base::Bind(&HistoryBackend::UpdateFaviconMappingsAndFetch,
- history_backend_.get(), page_url, icon_urls, icon_types,
- desired_size_in_dip, desired_scale_factors, results),
+ history_backend_.get(),
+ page_url,
+ icon_urls,
+ icon_types,
+ desired_size_in_dip,
+ desired_scale_factors,
+ results),
base::Bind(&RunWithFaviconResults, callback, base::Owned(results)));
}
@@ -1110,7 +1126,7 @@ void HistoryService::ExpireHistoryBetween(
DCHECK(thread_);
DCHECK(thread_checker_.CalledOnValidThread());
DCHECK(history_backend_.get());
- tracker->PostTaskAndReply(thread_->message_loop_proxy(),
+ tracker->PostTaskAndReply(thread_->message_loop_proxy().get(),
FROM_HERE,
base::Bind(&HistoryBackend::ExpireHistoryBetween,
history_backend_,
@@ -1128,7 +1144,7 @@ void HistoryService::ExpireHistory(
DCHECK(thread_checker_.CalledOnValidThread());
DCHECK(history_backend_.get());
tracker->PostTaskAndReply(
- thread_->message_loop_proxy(),
+ thread_->message_loop_proxy().get(),
FROM_HERE,
base::Bind(&HistoryBackend::ExpireHistory, history_backend_, expire_list),
callback);
« no previous file with comments | « chrome/browser/favicon/favicon_service.cc ('k') | chrome/browser/history/shortcuts_backend_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698