Rename CFX_FontCache::GetCachedFace() to GetFaceCache() Avoid confusion with other GetCachedFace() methods which actually return a cached face (and not a face cache itself). Change-Id: I68f0e76fe88ab3745840e7061c6212a112bf012b Reviewed-on: https://pdfium-review.googlesource.com/c/pdfium/+/54432 Reviewed-by: Lei Zhang <thestig@chromium.org> Commit-Queue: Tom Sepez <tsepez@chromium.org>
diff --git a/core/fxge/cfx_font.cpp b/core/fxge/cfx_font.cpp index 2f39a0b..992d22b 100644 --- a/core/fxge/cfx_font.cpp +++ b/core/fxge/cfx_font.cpp
@@ -583,7 +583,7 @@ RetainPtr<CFX_FaceCache> CFX_Font::GetOrCreateFaceCache() const { if (!m_FaceCache) - m_FaceCache = CFX_GEModule::Get()->GetFontCache()->GetCachedFace(this); + m_FaceCache = CFX_GEModule::Get()->GetFontCache()->GetFaceCache(this); return m_FaceCache; }
diff --git a/core/fxge/cfx_fontcache.cpp b/core/fxge/cfx_fontcache.cpp index b9300bc..bb3e1a6 100644 --- a/core/fxge/cfx_fontcache.cpp +++ b/core/fxge/cfx_fontcache.cpp
@@ -19,7 +19,7 @@ CFX_FontCache::~CFX_FontCache() = default; -RetainPtr<CFX_FaceCache> CFX_FontCache::GetCachedFace(const CFX_Font* pFont) { +RetainPtr<CFX_FaceCache> CFX_FontCache::GetFaceCache(const CFX_Font* pFont) { FXFT_Face face = pFont->GetFace(); const bool bExternal = !face; auto& map = bExternal ? m_ExtFaceMap : m_FTFaceMap; @@ -34,6 +34,6 @@ #ifdef _SKIA_SUPPORT_ CFX_TypeFace* CFX_FontCache::GetDeviceCache(const CFX_Font* pFont) { - return GetCachedFace(pFont)->GetDeviceCache(pFont); + return GetFaceCache(pFont)->GetDeviceCache(pFont); } #endif
diff --git a/core/fxge/cfx_fontcache.h b/core/fxge/cfx_fontcache.h index 516e779..7eb0821 100644 --- a/core/fxge/cfx_fontcache.h +++ b/core/fxge/cfx_fontcache.h
@@ -21,7 +21,7 @@ CFX_FontCache(); ~CFX_FontCache(); - RetainPtr<CFX_FaceCache> GetCachedFace(const CFX_Font* pFont); + RetainPtr<CFX_FaceCache> GetFaceCache(const CFX_Font* pFont); #ifdef _SKIA_SUPPORT_ CFX_TypeFace* GetDeviceCache(const CFX_Font* pFont); #endif
diff --git a/core/fxge/win32/cfx_psrenderer.cpp b/core/fxge/win32/cfx_psrenderer.cpp index d684600..77dd564 100644 --- a/core/fxge/win32/cfx_psrenderer.cpp +++ b/core/fxge/win32/cfx_psrenderer.cpp
@@ -664,7 +664,7 @@ << pObject2Device->e << " " << pObject2Device->f << "]cm\n"; CFX_FontCache* pCache = CFX_GEModule::Get()->GetFontCache(); - RetainPtr<CFX_FaceCache> pFaceCache = pCache->GetCachedFace(pFont); + RetainPtr<CFX_FaceCache> pFaceCache = pCache->GetFaceCache(pFont); int last_fontnum = -1; for (int i = 0; i < nChars; i++) { int ps_fontnum, ps_glyphindex;