summaryrefslogtreecommitdiff
path: root/core/include
diff options
context:
space:
mode:
authorTom Sepez <tsepez@chromium.org>2016-02-17 10:07:21 -0800
committerTom Sepez <tsepez@chromium.org>2016-02-17 10:07:21 -0800
commitab27768d235985c0789a10ab490be43e262f48f6 (patch)
tree692c2707020bee87753c05208c7d0c6f176ff30b /core/include
parent32c70815316672091946be88e5941089c359d151 (diff)
downloadpdfium-ab27768d235985c0789a10ab490be43e262f48f6.tar.xz
Banish CFX_ByteArray and CFX_WideArray to the XFA side.
Fix IWYU and include paths as we go. R=thestig@chromium.org Review URL: https://codereview.chromium.org/1701883004 .
Diffstat (limited to 'core/include')
-rw-r--r--core/include/fpdfdoc/fpdf_doc.h2
-rw-r--r--core/include/fxcrt/fx_basic.h2
-rw-r--r--core/include/fxge/fx_font.h23
-rw-r--r--core/include/fxge/fx_ge.h4
4 files changed, 16 insertions, 15 deletions
diff --git a/core/include/fpdfdoc/fpdf_doc.h b/core/include/fpdfdoc/fpdf_doc.h
index 7ade012bf0..17f2c824c6 100644
--- a/core/include/fpdfdoc/fpdf_doc.h
+++ b/core/include/fpdfdoc/fpdf_doc.h
@@ -563,8 +563,6 @@ class CPDF_InterForm : public CFX_PrivateData {
CPDF_FormField* GetField(FX_DWORD index,
const CFX_WideString& csFieldName = L"");
- void GetAllFieldNames(CFX_WideStringArray& allFieldNames);
-
CPDF_FormField* GetFieldByDict(CPDF_Dictionary* pFieldDict) const;
CPDF_FormControl* GetControlAtPoint(CPDF_Page* pPage,
diff --git a/core/include/fxcrt/fx_basic.h b/core/include/fxcrt/fx_basic.h
index 95927c38f2..7099e28447 100644
--- a/core/include/fxcrt/fx_basic.h
+++ b/core/include/fxcrt/fx_basic.h
@@ -545,9 +545,9 @@ class CFX_ObjectArray : public CFX_BasicArray {
CFX_BasicArray::SetSize(0);
}
};
+#ifdef PDF_ENABLE_XFA
typedef CFX_ObjectArray<CFX_ByteString> CFX_ByteStringArray;
typedef CFX_ObjectArray<CFX_WideString> CFX_WideStringArray;
-#ifdef PDF_ENABLE_XFA
class CFX_BaseSegmentedArray {
public:
CFX_BaseSegmentedArray(int unit_size = 1,
diff --git a/core/include/fxge/fx_font.h b/core/include/fxge/fx_font.h
index f2db4a1dc0..044e949ca4 100644
--- a/core/include/fxge/fx_font.h
+++ b/core/include/fxge/fx_font.h
@@ -9,9 +9,10 @@
#include <map>
#include <memory>
+#include <vector>
#include "core/include/fxcrt/fx_system.h"
-#include "fx_dib.h"
+#include "core/include/fxge/fx_dib.h"
typedef struct FT_FaceRec_* FXFT_Face;
typedef void* FXFT_Library;
@@ -306,7 +307,7 @@ class CFX_FontMapper {
IFX_SystemFontInfo* GetSystemFontInfo() { return m_pFontInfo; }
void AddInstalledFont(const CFX_ByteString& name, int charset);
void LoadInstalledFonts();
- CFX_ByteStringArray m_InstalledTTFonts;
+ std::vector<CFX_ByteString> m_InstalledTTFonts;
void SetFontEnumerator(IFX_FontEnumerator* pFontEnumerator) {
m_pFontEnumerator = pFontEnumerator;
}
@@ -325,7 +326,7 @@ class CFX_FontMapper {
int italic_angle);
#endif // PDF_ENABLE_XFA
FX_BOOL IsBuiltinFace(const FXFT_Face face) const;
- int GetFaceSize() const { return m_FaceArray.GetSize(); }
+ int GetFaceSize() const;
CFX_ByteString GetFaceName(int index) const { return m_FaceArray[index]; }
private:
@@ -344,7 +345,7 @@ class CFX_FontMapper {
FXFT_Face m_MMFaces[MM_FACE_COUNT];
CFX_ByteString m_LastFamily;
CFX_DWordArray m_CharsetArray;
- CFX_ByteStringArray m_FaceArray;
+ std::vector<CFX_ByteString> m_FaceArray;
IFX_SystemFontInfo* m_pFontInfo;
FXFT_Face m_FoxitFaces[FOXIT_FACE_COUNT];
IFX_FontEnumerator* m_pFontEnumerator;
@@ -417,12 +418,9 @@ class CFX_FolderFontInfo : public IFX_SystemFontInfo {
FX_BOOL GetFontCharset(void* hFont, int& charset) override;
protected:
- std::map<CFX_ByteString, CFX_FontFaceInfo*> m_FontList;
- CFX_ByteStringArray m_PathList;
- CFX_FontMapper* m_pMapper;
- void ScanPath(CFX_ByteString& path);
- void ScanFile(CFX_ByteString& path);
- void ReportFace(CFX_ByteString& path,
+ void ScanPath(const CFX_ByteString& path);
+ void ScanFile(const CFX_ByteString& path);
+ void ReportFace(const CFX_ByteString& path,
FXSYS_FILE* pFile,
FX_DWORD filesize,
FX_DWORD offset);
@@ -433,7 +431,12 @@ class CFX_FolderFontInfo : public IFX_SystemFontInfo {
int pitch_family,
const FX_CHAR* family,
FX_BOOL bMatchName);
+
+ std::map<CFX_ByteString, CFX_FontFaceInfo*> m_FontList;
+ std::vector<CFX_ByteString> m_PathList;
+ CFX_FontMapper* m_pMapper;
};
+
class CFX_CountedFaceCache {
public:
CFX_FaceCache* m_Obj;
diff --git a/core/include/fxge/fx_ge.h b/core/include/fxge/fx_ge.h
index 01a1c72a8f..ebcdea1483 100644
--- a/core/include/fxge/fx_ge.h
+++ b/core/include/fxge/fx_ge.h
@@ -7,8 +7,8 @@
#ifndef CORE_INCLUDE_FXGE_FX_GE_H_
#define CORE_INCLUDE_FXGE_FX_GE_H_
-#include "fx_dib.h"
-#include "fx_font.h"
+#include "core/include/fxge/fx_dib.h"
+#include "core/include/fxge/fx_font.h"
class CFX_Font;
class CFX_FontMgr;