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

Unified Diff: chrome/browser/favicon/favicon_handler.cc

Issue 24175004: Remove dependency on ui::ScaleFactor from ui/gfx (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix new usage of scale in FastShowPickler Created 7 years, 3 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/extensions/image_loader.cc ('k') | chrome/browser/favicon/favicon_handler_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/favicon/favicon_handler.cc
diff --git a/chrome/browser/favicon/favicon_handler.cc b/chrome/browser/favicon/favicon_handler.cc
index 8eb1897cb4e179140414b29505d4ab4d39c9e5f5..5e1459cb8ed4a18474af2b2b01eb623060c79f37 100644
--- a/chrome/browser/favicon/favicon_handler.cc
+++ b/chrome/browser/favicon/favicon_handler.cc
@@ -67,7 +67,7 @@ int GetMaximalIconSize(chrome::IconType icon_type) {
base_size = 0;
break;
}
- return ui::GetScaleFactorScale(ui::GetMaxScaleFactor()) * base_size;
+ return gfx::ImageSkia::GetMaxSupportedScale() * base_size;
}
bool DoUrlAndIconMatch(const FaviconURL& favicon_url,
@@ -148,7 +148,7 @@ bool HasExpiredOrIncompleteResult(
FaviconUtil::GetFaviconScaleFactors();
for (size_t i = 0; i < scale_factors.size(); ++i) {
int edge_size_in_pixel = floor(
- desired_size_in_dip * ui::GetScaleFactorScale(scale_factors[i]));
+ desired_size_in_dip * ui::GetImageScale(scale_factors[i]));
std::vector<gfx::Size>::iterator it = std::find(favicon_sizes.begin(),
favicon_sizes.end(), gfx::Size(edge_size_in_pixel, edge_size_in_pixel));
if (it == favicon_sizes.end())
« no previous file with comments | « chrome/browser/extensions/image_loader.cc ('k') | chrome/browser/favicon/favicon_handler_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698