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

Unified Diff: Source/core/css/CSSFontSelector.cpp

Issue 324293003: Change FontFaceSet#check() behavior when no matched font-face (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 6 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: Source/core/css/CSSFontSelector.cpp
diff --git a/Source/core/css/CSSFontSelector.cpp b/Source/core/css/CSSFontSelector.cpp
index 76f5734cd3ddb15673a2eca3e5d25e809ef547e6..38cdcb53efaf2792d85d0f12fad2e85ff5d5241c 100644
--- a/Source/core/css/CSSFontSelector.cpp
+++ b/Source/core/css/CSSFontSelector.cpp
@@ -149,6 +149,14 @@ void CSSFontSelector::willUseFontData(const FontDescription& fontDescription, co
face->willUseFontData(fontDescription, character);
}
+bool CSSFontSelector::isPlatformFontAvailable(const FontDescription& fontDescription, const AtomicString& passedFamily)
+{
+ AtomicString family = familyNameFromSettings(m_genericFontFamilySettings, fontDescription, passedFamily);
+ if (family.isEmpty())
+ family = passedFamily;
+ return FontCache::fontCache()->isPlatformFontAvailable(fontDescription, family);
+}
+
#if !ENABLE(OILPAN)
void CSSFontSelector::clearDocument()
{

Powered by Google App Engine
This is Rietveld 408576698