 Chromium Code Reviews
 Chromium Code Reviews Issue 26563004:
  Find Favicon in priority of icon_type.  (Closed) 
  Base URL: https://chromium.googlesource.com/chromium/src.git@master
    
  
    Issue 26563004:
  Find Favicon in priority of icon_type.  (Closed) 
  Base URL: https://chromium.googlesource.com/chromium/src.git@master| 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(). |