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

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

Issue 2028103002: Do not try to load material design paks if not on Mac OS. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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 | « no previous file | no next file » | 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 daab4db206f9ab86e0bfbdac730c606b2af9121a..08f1937933469531e784fa3b69738dfa7e71992f 100644
--- a/ui/base/resource/resource_bundle.cc
+++ b/ui/base/resource/resource_bundle.cc
@@ -697,11 +697,14 @@ void ResourceBundle::FreeImages() {
}
void ResourceBundle::LoadChromeResources() {
+ // TODO(estade): remove material design specific resources.
+ // See crbug.com/613593
// The material design data packs contain some of the same asset IDs as in
// the non-material design data packs. Add these to the ResourceBundle
// first so that they are searched first when a request for an asset is
// made.
if (MaterialDesignController::IsModeMaterial()) {
Evan Stade 2016/06/01 19:14:14 hmm, is this check necessary on !osx? Can we move
mfomitchev 2016/06/01 21:09:45 Good point. Done.
+#if defined(OS_MACOSX)
if (IsScaleFactorSupported(SCALE_FACTOR_100P)) {
AddMaterialDesignDataPackFromPath(
GetResourcesPakFilePath("chrome_material_100_percent.pak"),
@@ -713,6 +716,7 @@ void ResourceBundle::LoadChromeResources() {
GetResourcesPakFilePath("chrome_material_200_percent.pak"),
SCALE_FACTOR_200P);
}
+#endif
}
// Always load the 1x data pack first as the 2x data pack contains both 1x and
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698