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

Unified Diff: chrome/browser/favicon/favicon_service.h

Issue 26563004: Find Favicon in priority of icon_type. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 years, 2 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 | « no previous file | chrome/browser/favicon/favicon_service.cc » ('j') | chrome/browser/history/history_backend.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/favicon/favicon_service.h
diff --git a/chrome/browser/favicon/favicon_service.h b/chrome/browser/favicon/favicon_service.h
index 692a6ebe74e1d570670da09befcfc51ec8658a50..7f32ec91d11f6b993585f9a5bd84900130c9dd5f 100644
--- a/chrome/browser/favicon/favicon_service.h
+++ b/chrome/browser/favicon/favicon_service.h
@@ -46,13 +46,29 @@ class FaviconService : public CancelableRequestProvider,
int desired_size_in_dip)
: profile(profile),
page_url(page_url),
- icon_types(icon_types),
- desired_size_in_dip(desired_size_in_dip) {}
+ desired_size_in_dip(desired_size_in_dip),
+ threshold_for_next_icon_types(0) {
+ icon_types_priority.push_back(icon_types);
+ }
+
+ // Used to get best fit icon with icon types priority, see
+ // HistoryService::GetFaviconsForURL.
+ FaviconForURLParams(Profile* profile,
+ const GURL& page_url,
+ const std::vector<int> icon_types_priority,
sky 2013/10/08 23:47:52 const std::vector<int>&
michaelbai 2013/10/10 05:51:43 Done.
+ int desired_size_in_dip,
+ int threshold_for_next_icon_types)
+ : profile(profile),
+ page_url(page_url),
+ icon_types_priority(icon_types_priority),
+ desired_size_in_dip(desired_size_in_dip),
+ threshold_for_next_icon_types(threshold_for_next_icon_types) {}
pkotwicz 2013/10/09 17:11:51 I would expect to have a vector of thresholds with
michaelbai 2013/10/09 18:35:09 Yes, currently, it will always be the same values,
Profile* profile;
GURL page_url;
- int icon_types;
+ std::vector<int> icon_types_priority;
sky 2013/10/08 23:47:52 How come these take an int instead of IconType? Al
michaelbai 2013/10/09 18:35:09 Using int because The icon_types could be icon_ty
int desired_size_in_dip;
+ int threshold_for_next_icon_types;
};
// Callback for GetFaviconImage() and GetFaviconImageForURL().
« no previous file with comments | « no previous file | chrome/browser/favicon/favicon_service.cc » ('j') | chrome/browser/history/history_backend.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698