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

Unified Diff: Source/core/platform/graphics/skia/FontCacheSkiaWin.cpp

Issue 23835013: Add AtomicString, SkString version of equalIgnoringCase (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 7 years, 3 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: Source/core/platform/graphics/skia/FontCacheSkiaWin.cpp
diff --git a/Source/core/platform/graphics/skia/FontCacheSkiaWin.cpp b/Source/core/platform/graphics/skia/FontCacheSkiaWin.cpp
index 4462607a6d7f0a07de02b3cfef473bab8747a37a..9338967630e1f979d350bf9a13b4b063d363023e 100644
--- a/Source/core/platform/graphics/skia/FontCacheSkiaWin.cpp
+++ b/Source/core/platform/graphics/skia/FontCacheSkiaWin.cpp
@@ -157,6 +157,11 @@ PassRefPtr<SimpleFontData> FontCache::getFontDataForCharacter(const Font& font,
return 0;
}
+static inline bool equalIgnoringCase(const AtomicString& a, const SkString& b)
+{
+ return equalIgnoringCase(a, AtomicString::fromUTF8(b.c_str()));
+}
+
static bool typefacesMatchesFamily(const SkTypeface* tf, const AtomicString& family)
{
SkTypeface::LocalizedStrings* actualFamilies = tf->createFamilyNameIterator();
@@ -164,7 +169,7 @@ static bool typefacesMatchesFamily(const SkTypeface* tf, const AtomicString& fam
SkTypeface::LocalizedString actualFamily;
while (actualFamilies->next(&actualFamily)) {
- if (equalIgnoringCase(family, AtomicString::fromUTF8(actualFamily.fString.c_str()))) {
+ if (equalIgnoringCase(family, actualFamily.fString)) {
matchesRequestedFamily = true;
break;
}
« 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