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

Unified Diff: core/src/fxge/ge/fx_ge_fontmap.cpp

Issue 1540263003: Add ContainsKey() and ContainsValue() and use them where appropriate. (Closed) Base URL: https://pdfium.googlesource.com/pdfium@master
Patch Set: rebase Created 5 years 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/fpdfdoc/doc_form.cpp ('k') | fpdfsdk/src/fsdk_mgr.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: core/src/fxge/ge/fx_ge_fontmap.cpp
diff --git a/core/src/fxge/ge/fx_ge_fontmap.cpp b/core/src/fxge/ge/fx_ge_fontmap.cpp
index d169081b5f08afc1860de7952f6e5f84e598fe66..1101da2344b88847660300db5d9213ff9532b4e8 100644
--- a/core/src/fxge/ge/fx_ge_fontmap.cpp
+++ b/core/src/fxge/ge/fx_ge_fontmap.cpp
@@ -9,7 +9,7 @@
#include "core/include/fxge/fx_freetype.h"
#include "core/include/fxge/fx_ge.h"
#include "core/src/fxge/fontdata/chromefontdata/chromefontdata.h"
-#include "text_int.h"
+#include "core/src/fxge/ge/text_int.h"
#include "third_party/base/stl_util.h"
#define GET_TT_SHORT(w) (FX_WORD)(((w)[0] << 8) | (w)[1])
@@ -1347,9 +1347,9 @@ void CFX_FolderFontInfo::ReportFace(CFX_ByteString& path,
if (style != "Regular") {
facename += " " + style;
}
- if (m_FontList.find(facename) != m_FontList.end()) {
+ if (pdfium::ContainsKey(m_FontList, facename))
return;
- }
+
CFX_FontFaceInfo* pInfo =
new CFX_FontFaceInfo(path, facename, tables, offset, filesize);
CFX_ByteString os2 = FPDF_LoadTableFromTT(pFile, tables, nTables, 0x4f532f32);
« no previous file with comments | « core/src/fpdfdoc/doc_form.cpp ('k') | fpdfsdk/src/fsdk_mgr.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698