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

Unified Diff: src/ports/SkFontConfigParser_android.cpp

Issue 458543002: Update path to Android font config file (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Derek's late review Created 6 years, 4 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: src/ports/SkFontConfigParser_android.cpp
diff --git a/src/ports/SkFontConfigParser_android.cpp b/src/ports/SkFontConfigParser_android.cpp
index e9c912f4b012e0e9608eab2cf5d7713d6cc48d49..658055d5a2428959921de04a7eddc7fff23b1be3 100644
--- a/src/ports/SkFontConfigParser_android.cpp
+++ b/src/ports/SkFontConfigParser_android.cpp
@@ -19,7 +19,7 @@
// From Android version LMP onwards, all font files collapse into
-// /system/fonts/fonts.xml. Instead of trying to detect which version
+// /system/etc/fonts.xml. Instead of trying to detect which version
// we're on, try to open fonts.xml; if that fails, fall back to the
// older filename.
#define LMP_SYSTEM_FONTS_FILE "/system/etc/fonts.xml"
@@ -465,9 +465,10 @@ static void parseConfigFile(const char* filename, SkTDArray<FontFamily*> &famili
}
static void getSystemFontFamilies(SkTDArray<FontFamily*> &fontFamilies) {
+ int initialCount = fontFamilies.count();
parseConfigFile(LMP_SYSTEM_FONTS_FILE, fontFamilies);
- if (0 == fontFamilies.count()) {
+ if (initialCount == fontFamilies.count()) {
parseConfigFile(OLD_SYSTEM_FONTS_FILE, fontFamilies);
}
}
« 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