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

Unified Diff: ui/base/resource/resource_bundle.cc

Issue 2189583004: [not for review - epic CL] Adding Elastic+Momentum+Layered scrolling to views::ScrollView Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 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 | « cc/trees/tree_synchronizer_unittest.cc ('k') | ui/compositor/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/base/resource/resource_bundle.cc
diff --git a/ui/base/resource/resource_bundle.cc b/ui/base/resource/resource_bundle.cc
index 899a8a45cb95aaf05737504cde5e9780fdf25afd..d5942fdfb5984056ef22e43321bbeb4d98ddfb96 100644
--- a/ui/base/resource/resource_bundle.cc
+++ b/ui/base/resource/resource_bundle.cc
@@ -830,7 +830,11 @@ bool ResourceBundle::LoadBitmap(int resource_id,
*scale_factor = ui::SCALE_FACTOR_NONE;
return true;
}
- if (data_packs_[i]->GetScaleFactor() == ui::SCALE_FACTOR_100P)
+
+ // There may be multiple SCALE_FACTOR_100P providers, assume only the first
+ // may provide test fallbacks.
+ if (!data_handle_100_percent &&
+ data_packs_[i]->GetScaleFactor() == ui::SCALE_FACTOR_100P)
data_handle_100_percent = data_packs_[i];
if (data_packs_[i]->GetScaleFactor() == *scale_factor &&
« no previous file with comments | « cc/trees/tree_synchronizer_unittest.cc ('k') | ui/compositor/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698