Title: [188729] trunk/Source/WebCore
Revision
188729
Author
mmaxfi...@apple.com
Date
2015-08-20 18:36:18 -0700 (Thu, 20 Aug 2015)

Log Message

Cleanup after r188726

Unreviewed.

No new tests because there is no behavior change.

* platform/graphics/ios/FontCacheIOS.mm:
(WebCore::FontCache::systemFallbackForCharacters):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (188728 => 188729)


--- trunk/Source/WebCore/ChangeLog	2015-08-21 01:35:32 UTC (rev 188728)
+++ trunk/Source/WebCore/ChangeLog	2015-08-21 01:36:18 UTC (rev 188729)
@@ -1,5 +1,16 @@
 2015-08-20  Myles C. Maxfield  <mmaxfi...@apple.com>
 
+        Cleanup after r188726
+
+        Unreviewed.
+
+        No new tests because there is no behavior change.
+
+        * platform/graphics/ios/FontCacheIOS.mm:
+        (WebCore::FontCache::systemFallbackForCharacters):
+
+2015-08-20  Myles C. Maxfield  <mmaxfi...@apple.com>
+
         [iOS] Delete dead code
         https://bugs.webkit.org/show_bug.cgi?id=148278
 

Modified: trunk/Source/WebCore/platform/graphics/ios/FontCacheIOS.mm (188728 => 188729)


--- trunk/Source/WebCore/platform/graphics/ios/FontCacheIOS.mm	2015-08-21 01:35:32 UTC (rev 188728)
+++ trunk/Source/WebCore/platform/graphics/ios/FontCacheIOS.mm	2015-08-21 01:36:18 UTC (rev 188729)
@@ -108,8 +108,6 @@
             return getSystemFontFallbackForCharacters(description, originalFontData, characters, length);
     }
 
-    RefPtr<Font> font;
-
     RetainPtr<CTFontDescriptorRef> fallbackFontDescriptor = adoptCF(CTFontCreatePhysicalFontDescriptorForCharactersWithLanguage(originalFontData->getCTFont(), characters, length, nullptr, nullptr));
     if (auto foundFontName = adoptCF(static_cast<CFStringRef>(CTFontDescriptorCopyAttribute(fallbackFontDescriptor.get(), kCTFontNameAttribute)))) {
         if (c >= 0x0600 && c <= 0x06ff) { // Arabic
@@ -117,12 +115,10 @@
             if (fontFamilyShouldNotBeUsedForArabic(familyName.get()))
                 foundFontName = isFontWeightBold(description.weight()) ? CFSTR("GeezaPro-Bold") : CFSTR("GeezaPro");
         }
-        font = fontForFamily(description, foundFontName.get(), false);
+        if (RefPtr<Font> font = fontForFamily(description, foundFontName.get(), false))
+            return font;
     }
 
-    if (font)
-        return font.release();
-
     return lastResortFallbackFont(description);
 }
 
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to