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

Unified Diff: fpdfsdk/src/fpdf_sysfontinfo.cpp

Issue 1257743005: Name IFX_SysFontInfo subclasses consistently. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: whitespace Created 5 years, 5 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 | « core/src/fxge/win32/fx_win32_device.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: fpdfsdk/src/fpdf_sysfontinfo.cpp
diff --git a/fpdfsdk/src/fpdf_sysfontinfo.cpp b/fpdfsdk/src/fpdf_sysfontinfo.cpp
index cf0cdd915bdc35c232c3cbd1aa78f62fb83e1858..6b7d6fbe4cd25bd93a4f2601e515164dba59fc6a 100644
--- a/fpdfsdk/src/fpdf_sysfontinfo.cpp
+++ b/fpdfsdk/src/fpdf_sysfontinfo.cpp
@@ -8,10 +8,10 @@
#include "../include/fsdk_define.h"
#include "../include/pdfwindow/PWL_FontMap.h"
-class CSysFontInfo_Ext final : public IFX_SystemFontInfo
+class CFX_ExternalFontInfo final : public IFX_SystemFontInfo
{
public:
- FPDF_SYSFONTINFO* m_pInfo;
+ CFX_ExternalFontInfo(FPDF_SYSFONTINFO* pInfo) : m_pInfo(pInfo) { }
virtual void Release() override
{
@@ -78,7 +78,9 @@ public:
}
private:
- ~CSysFontInfo_Ext() { }
+ ~CFX_ExternalFontInfo() { }
+
+ FPDF_SYSFONTINFO* const m_pInfo;
};
DLLEXPORT void STDCALL FPDF_AddInstalledFont(void* mapper, const char* name, int charset)
@@ -88,11 +90,11 @@ DLLEXPORT void STDCALL FPDF_AddInstalledFont(void* mapper, const char* name, int
DLLEXPORT void STDCALL FPDF_SetSystemFontInfo(FPDF_SYSFONTINFO* pFontInfoExt)
{
- if (pFontInfoExt->version != 1) return;
+ if (pFontInfoExt->version != 1)
+ return;
- CSysFontInfo_Ext* pFontInfo = new CSysFontInfo_Ext;
- pFontInfo->m_pInfo = pFontInfoExt;
- CFX_GEModule::Get()->GetFontMgr()->SetSystemFontInfo(pFontInfo);
+ CFX_GEModule::Get()->GetFontMgr()->SetSystemFontInfo(
+ new CFX_ExternalFontInfo(pFontInfoExt));
}
DLLEXPORT const FPDF_CharsetFontMap* STDCALL FPDF_GetDefaultTTFMap()
« no previous file with comments | « core/src/fxge/win32/fx_win32_device.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698