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

Unified Diff: third_party/WebKit/Source/platform/fonts/win/FontCacheSkiaWin.cpp

Issue 2161683002: Add LayoutLocale class (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Test stability Created 4 years, 5 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
Index: third_party/WebKit/Source/platform/fonts/win/FontCacheSkiaWin.cpp
diff --git a/third_party/WebKit/Source/platform/fonts/win/FontCacheSkiaWin.cpp b/third_party/WebKit/Source/platform/fonts/win/FontCacheSkiaWin.cpp
index 5d6a886dedbbec51938aa31f58b96e84c61691d7..70e018ed8f6619a76b2dc9b24a767a25f525a16f 100644
--- a/third_party/WebKit/Source/platform/fonts/win/FontCacheSkiaWin.cpp
+++ b/third_party/WebKit/Source/platform/fonts/win/FontCacheSkiaWin.cpp
@@ -126,8 +126,7 @@ PassRefPtr<SimpleFontData> FontCache::fallbackFontForCharacter(
UScriptCode script;
const wchar_t* family = getFallbackFamily(character,
fontDescription.genericFamily(),
- fontDescription.script(),
- fontDescription.locale(),
+ fontDescription.localeOrDefault(),
&script,
fallbackPriority,
m_fontManager.get());
@@ -145,8 +144,8 @@ PassRefPtr<SimpleFontData> FontCache::fallbackFontForCharacter(
// fall back on the user's default locale.
// TODO(kulshin): extract locale fallback logic from
// FontCacheAndroid.cpp and share that code
- if (!fontDescription.locale().isEmpty()) {
- fontLocale = toSkFontMgrLocale(fontDescription.locale());
+ if (fontDescription.locale()) {
+ fontLocale = fontDescription.locale()->localeForSkFontMgr();
bcp47Locale = fontLocale.data();
localeCount = 1;
}

Powered by Google App Engine
This is Rietveld 408576698