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

Unified Diff: fpdfsdk/fpdf_sysfontinfo.cpp

Issue 2485283002: Add FPDF_FreeDefaultSystemFontInfo API (Closed)
Patch Set: Created 4 years, 1 month 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 | fpdfsdk/fpdfview_c_api_test.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: fpdfsdk/fpdf_sysfontinfo.cpp
diff --git a/fpdfsdk/fpdf_sysfontinfo.cpp b/fpdfsdk/fpdf_sysfontinfo.cpp
index ef62ae3f8a1a39d8e6a651b6671f59acc129aca2..aa21d29f9e7c09998e35ae55121a7e8149976029 100644
--- a/fpdfsdk/fpdf_sysfontinfo.cpp
+++ b/fpdfsdk/fpdf_sysfontinfo.cpp
@@ -194,3 +194,9 @@ DLLEXPORT FPDF_SYSFONTINFO* STDCALL FPDF_GetDefaultSystemFontInfo() {
pFontInfoExt->m_pFontInfo = pFontInfo.release();
return pFontInfoExt;
}
+
+DLLEXPORT void FPDF_FreeDefaultSystemFontInfo(
+ FPDF_SYSFONTINFO* pDefaultFontInfo) {
+ auto* pDefault = static_cast<FPDF_SYSFONTINFO_DEFAULT*>(pDefaultFontInfo);
Tom Sepez 2016/11/08 22:45:05 nit: local not needed, just delete static_cast ...
npm 2016/11/08 22:49:37 Done.
+ delete pDefault;
+}
« no previous file with comments | « no previous file | fpdfsdk/fpdfview_c_api_test.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698