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

Unified Diff: chrome/browser/ui/webui/extensions/extension_icon_source.cc

Issue 10828263: Moving FaviconService to a ProfileKeyedService. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: resyncing with library after revert Created 8 years, 4 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
Index: chrome/browser/ui/webui/extensions/extension_icon_source.cc
===================================================================
--- chrome/browser/ui/webui/extensions/extension_icon_source.cc (revision 152993)
+++ chrome/browser/ui/webui/extensions/extension_icon_source.cc (working copy)
@@ -15,6 +15,7 @@
#include "base/threading/thread.h"
#include "chrome/browser/extensions/extension_prefs.h"
#include "chrome/browser/extensions/extension_service.h"
+#include "chrome/browser/favicon/favicon_service_factory.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/common/extensions/extension.h"
#include "chrome/common/extensions/extension_constants.h"
@@ -204,7 +205,7 @@
void ExtensionIconSource::LoadFaviconImage(int request_id) {
FaviconService* favicon_service =
- profile_->GetFaviconService(Profile::EXPLICIT_ACCESS);
+ FaviconServiceFactory::GetForProfile(profile_, Profile::EXPLICIT_ACCESS);
// Fall back to the default icons if the service isn't available.
if (favicon_service == NULL) {
LoadDefaultImage(request_id);
@@ -213,6 +214,7 @@
GURL favicon_url = GetData(request_id)->extension->GetFullLaunchURL();
FaviconService::Handle handle = favicon_service->GetFaviconForURL(
+ profile_,
favicon_url,
history::FAVICON,
&cancelable_consumer_,
@@ -225,7 +227,8 @@
FaviconService::Handle request_handle,
history::FaviconData favicon) {
int request_id = cancelable_consumer_.GetClientData(
- profile_->GetFaviconService(Profile::EXPLICIT_ACCESS), request_handle);
+ FaviconServiceFactory::GetForProfile(profile_, Profile::EXPLICIT_ACCESS),
+ request_handle);
ExtensionIconRequest* request = GetData(request_id);
// Fallback to the default icon if there wasn't a favicon.
« no previous file with comments | « chrome/browser/ui/toolbar/back_forward_menu_model_unittest.cc ('k') | chrome/browser/ui/webui/favicon_source.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698