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

Unified Diff: ui/base/layout.cc

Issue 11293147: Always add 100P scale format in the supported format list. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Adding TODO. Created 8 years, 1 month 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 | ui/base/resource/resource_bundle_ios.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/base/layout.cc
diff --git a/ui/base/layout.cc b/ui/base/layout.cc
index 6fef499542c57632fb6afc58a7d821309ce5d193..98df1e1ff187ddc222cc61de33651d8c35943909 100644
--- a/ui/base/layout.cc
+++ b/ui/base/layout.cc
@@ -73,18 +73,18 @@ std::vector<ScaleFactor>& GetSupportedScaleFactorsInternal() {
static std::vector<ScaleFactor>* supported_scale_factors =
new std::vector<ScaleFactor>();
if (supported_scale_factors->empty()) {
-#if !defined(OS_IOS)
- // On platforms other than iOS, 100P is always a supported scale factor.
+ // 100P is always a supported scale factor.
supported_scale_factors->push_back(SCALE_FACTOR_100P);
-#endif
#if defined(OS_IOS)
+ // TODO(ios): 100p should not be necessary on iOS retina devices. However
+ // the sync service only supports syncing 100p favicons. Until sync supports
+ // other scales 100p is needed in the list of scale factors to retrieve and
+ // store the favicons in both 100p for sync and 200p for display. cr/160503.
gfx::Display display = gfx::Screen::GetNativeScreen()->GetPrimaryDisplay();
if (display.device_scale_factor() > 1.0) {
DCHECK_EQ(2.0, display.device_scale_factor());
supported_scale_factors->push_back(SCALE_FACTOR_200P);
- } else {
- supported_scale_factors->push_back(SCALE_FACTOR_100P);
}
#elif defined(OS_MACOSX)
if (base::mac::IsOSLionOrLater())
« no previous file with comments | « no previous file | ui/base/resource/resource_bundle_ios.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698