FontCache::fontCache() never returns nullptr so it can be made to return a reference...
authormmaxfield@apple.com <mmaxfield@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 24 Apr 2014 19:05:47 +0000 (19:05 +0000)
committermmaxfield@apple.com <mmaxfield@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 24 Apr 2014 19:05:47 +0000 (19:05 +0000)
commitc5c62d794e4911cc13c967600ea87ffd597a94aa
tree75f9ee3ed0c128d1f893520d83beb3ddce2a4ca7
parent1f1f63da585568a855a8c4e4516cc758918d707a
FontCache::fontCache() never returns nullptr so it can be made to return a reference instead
https://bugs.webkit.org/show_bug.cgi?id=132110

Reviewed by Tim Horton.

Updates callers to use '.' instead of '->'.

No new tests are necessary because there should be no behavior change.

Source/WebCore:
* css/CSSFontFaceSource.cpp:
(WebCore::CSSFontFaceSource::getFontData):
* css/CSSFontSelector.cpp:
(WebCore::CSSFontSelector::CSSFontSelector):
(WebCore::CSSFontSelector::~CSSFontSelector):
(WebCore::CSSFontSelector::addFontFaceRule):
(WebCore::fontDataForGenericFamily):
(WebCore::CSSFontSelector::getFallbackFontData):
* platform/MemoryPressureHandler.cpp:
(WebCore::MemoryPressureHandler::releaseMemory):
* platform/graphics/FontCache.cpp:
(WebCore::fontCache): Return a reference
* platform/graphics/FontCache.h:
(WebCore::FontCachePurgePreventer::FontCachePurgePreventer):
(WebCore::FontCachePurgePreventer::~FontCachePurgePreventer):
* platform/graphics/FontGlyphs.cpp:
(WebCore::FontGlyphs::FontGlyphs):
(WebCore::FontGlyphs::releaseFontData):
(WebCore::FontGlyphs::realizeFontDataAt):
(WebCore::FontGlyphs::glyphDataAndPageForCharacter):
* platform/graphics/freetype/FontPlatformDataFreeType.cpp:
(WebCore::FontPlatformData::verticalData):
* platform/graphics/ios/SimpleFontDataIOS.mm:
(WebCore::SimpleFontData::platformCreateScaledFontData):
* platform/graphics/mac/ComplexTextControllerCoreText.mm:
(WebCore::ComplexTextController::collectComplexTextRunsForCharacters):
* platform/graphics/mac/FontCacheMac.mm:
(WebCore::invalidateFontCache):
(WebCore::fontCacheRegisteredFontsChangedNotificationCallback):
* platform/graphics/mac/SimpleFontDataMac.mm:
(WebCore::SimpleFontData::platformDestroy):
(WebCore::SimpleFontData::platformCreateScaledFontData):
* platform/graphics/win/FontCacheWin.cpp:
(WebCore::getCJKCodePageMasks):
* platform/graphics/win/SimpleFontDataWin.cpp:
(WebCore::SimpleFontData::containsCharacters):
* platform/graphics/wince/FontCacheWinCE.cpp:
(WebCore::getCJKCodePageMasks):
* platform/graphics/wince/FontPlatformData.cpp:
(WebCore::FontFamilyCodePageInfo::codePages):
(WebCore::FixedSizeFontData::create):
* platform/graphics/wince/GlyphPageTreeNodeWinCE.cpp:
(WebCore::GlyphPage::fill):
* platform/graphics/wince/SimpleFontDataWinCE.cpp:
(WebCore::SimpleFontData::platformCreateScaledFontData):
(WebCore::SimpleFontData::containsCharacters):

Source/WebKit/efl:
* ewk/ewk_settings.cpp:
(ewk_settings_memory_cache_clear):

Source/WebKit/ios:
* Misc/EmojiFallbackFontSelector.cpp:
(EmojiFallbackFontSelector::getFallbackFontData):

Source/WebKit/mac:
* Misc/WebCoreStatistics.mm:
(+[WebCoreStatistics cachedFontDataCount]):
(+[WebCoreStatistics cachedFontDataInactiveCount]):
(+[WebCoreStatistics purgeInactiveFontData]):
* WebView/WebView.mm:
(+[WebView purgeInactiveFontData]):

Source/WebKit/win:
* WebCoreStatistics.cpp:
(WebCoreStatistics::cachedFontDataCount):
(WebCoreStatistics::cachedFontDataInactiveCount):
(WebCoreStatistics::purgeInactiveFontData):

Source/WebKit2:
* WebProcess/WebProcess.cpp:
(WebKit::WebProcess::terminate):
(WebKit::WebProcess::didClose):
(WebKit::WebProcess::getWebCoreStatistics):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@167768 268f45cc-cd09-0410-ab3c-d52691b4dbfc
29 files changed:
Source/WebCore/ChangeLog
Source/WebCore/css/CSSFontFaceSource.cpp
Source/WebCore/css/CSSFontSelector.cpp
Source/WebCore/platform/MemoryPressureHandler.cpp
Source/WebCore/platform/graphics/FontCache.cpp
Source/WebCore/platform/graphics/FontCache.h
Source/WebCore/platform/graphics/FontGlyphs.cpp
Source/WebCore/platform/graphics/freetype/FontPlatformDataFreeType.cpp
Source/WebCore/platform/graphics/ios/SimpleFontDataIOS.mm
Source/WebCore/platform/graphics/mac/ComplexTextControllerCoreText.mm
Source/WebCore/platform/graphics/mac/FontCacheMac.mm
Source/WebCore/platform/graphics/mac/SimpleFontDataMac.mm
Source/WebCore/platform/graphics/win/FontCacheWin.cpp
Source/WebCore/platform/graphics/win/SimpleFontDataWin.cpp
Source/WebCore/platform/graphics/wince/FontCacheWinCE.cpp
Source/WebCore/platform/graphics/wince/FontPlatformData.cpp
Source/WebCore/platform/graphics/wince/GlyphPageTreeNodeWinCE.cpp
Source/WebCore/platform/graphics/wince/SimpleFontDataWinCE.cpp
Source/WebKit/efl/ChangeLog
Source/WebKit/efl/ewk/ewk_settings.cpp
Source/WebKit/ios/ChangeLog
Source/WebKit/ios/Misc/EmojiFallbackFontSelector.cpp
Source/WebKit/mac/ChangeLog
Source/WebKit/mac/Misc/WebCoreStatistics.mm
Source/WebKit/mac/WebView/WebView.mm
Source/WebKit/win/ChangeLog
Source/WebKit/win/WebCoreStatistics.cpp
Source/WebKit2/ChangeLog
Source/WebKit2/WebProcess/WebProcess.cpp