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

Unified Diff: xfa/fxfa/app/xfa_fontmgr.cpp

Issue 2259823004: [XFA] Force destruction order of font managers. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Re-arrange header entries Created 4 years, 4 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 | « xfa/fgas/font/fgas_stdfontmgr.cpp ('k') | xfa/fxfa/include/xfa_ffapp.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: xfa/fxfa/app/xfa_fontmgr.cpp
diff --git a/xfa/fxfa/app/xfa_fontmgr.cpp b/xfa/fxfa/app/xfa_fontmgr.cpp
index 5bb4ccb81638ccb0359537ffcbf05ed61bf82df5..d191ce35373805f3095cd21fd8ba237a19ee429b 100644
--- a/xfa/fxfa/app/xfa_fontmgr.cpp
+++ b/xfa/fxfa/app/xfa_fontmgr.cpp
@@ -1775,18 +1775,17 @@ CFGAS_GEFont* CXFA_DefFontMgr::GetFont(CXFA_FFDoc* hDoc,
CFX_WideString wsReplace =
CFX_WideString(pReplace, pNameText - pReplace);
pFont = pFDEFontMgr->LoadFont(wsReplace.c_str(), dwStyle, wCodePage);
- if (pFont) {
+ if (pFont)
break;
- }
+
iLength--;
pNameText++;
pReplace = pNameText;
}
}
}
- if (pFont) {
+ if (pFont)
m_CacheFonts.Add(pFont);
- }
return pFont;
}
@@ -1804,9 +1803,8 @@ CFGAS_GEFont* CXFA_DefFontMgr::GetDefaultFont(
}
ASSERT(pFont);
- if (pFont) {
+ if (pFont)
m_CacheFonts.Add(pFont);
- }
return pFont;
}
struct XFA_PDFFONTNAME {
« no previous file with comments | « xfa/fgas/font/fgas_stdfontmgr.cpp ('k') | xfa/fxfa/include/xfa_ffapp.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698