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

Unified Diff: components/favicon/core/favicon_service.h

Issue 2665623002: Fix Jumplist favicons to have high resolution in HDPI Windows displays (Closed)
Patch Set: Add faviconSize parameter to GetFaviconImageForPageURL() Created 3 years, 11 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: components/favicon/core/favicon_service.h
diff --git a/components/favicon/core/favicon_service.h b/components/favicon/core/favicon_service.h
index 9585934169f21c7407aff49adb9fa1718a3a30af..06607b819ba8317167c119131563a87086eb5f63 100644
--- a/components/favicon/core/favicon_service.h
+++ b/components/favicon/core/favicon_service.h
@@ -19,6 +19,7 @@
#include "components/favicon_base/favicon_types.h"
#include "components/favicon_base/favicon_usage_data.h"
#include "components/keyed_service/core/keyed_service.h"
+#include "ui/gfx/favicon_size.h"
class GURL;
@@ -94,15 +95,17 @@ class FaviconService : public KeyedService {
// (e.g. <http://www.google.com>)
// Requests the favicon for the page at |page_url| of type
- // favicon_base::FAVICON and of size gfx::kFaviconSize. The returned
- // gfx::Image is populated with representations for all of the scale factors
- // supported by the platform (e.g. MacOS). If data is unavailable for some or
- // all of the scale factors, the bitmaps with the best matching sizes are
- // resized.
+ // favicon_base::FAVICON and of size |faviconSize|. gfx::kFaviconSize is used
+ // by default for |faviconSize|, while gfx::kHdpiFaviconSize should be used
+ // for high DPI machines or displays. The returned gfx::Image is populated
+ // with representations for all of the scale factors supported by the platform
+ // (e.g. MacOS). If data is unavailable for some or all of the scale factors,
+ // the bitmaps with the best matching sizes are resized.
base::CancelableTaskTracker::TaskId GetFaviconImageForPageURL(
const GURL& page_url,
const favicon_base::FaviconImageCallback& callback,
- base::CancelableTaskTracker* tracker);
+ base::CancelableTaskTracker* tracker,
+ const int faviconSize = gfx::kFaviconSize);
sky 2017/01/31 23:28:44 You shouldn't need to specify a size. The gfx::Ima
chengx 2017/02/02 20:52:58 Acknowledged.
// Requests the favicon for the page at |page_url| with one of |icon_types|
// and with |desired_size_in_pixel|. |icon_types| can be any combination of

Powered by Google App Engine
This is Rietveld 408576698