Do some IWYU cleanups.
authorLei Zhang <thestig@chromium.org>
Mon, 15 Jun 2015 23:44:14 +0000 (16:44 -0700)
committerLei Zhang <thestig@chromium.org>
Mon, 15 Jun 2015 23:44:14 +0000 (16:44 -0700)
R=tsepez@chromium.org

Review URL: https://codereview.chromium.org/1176333002.

70 files changed:
core/include/fdrm/fx_crypt.h
core/include/fpdfapi/fpdf_module.h
core/include/fpdfapi/fpdf_objects.h
core/include/fpdfapi/fpdf_parser.h
core/include/fpdfapi/fpdfapi.h
core/include/fpdfdoc/fpdf_ap.h
core/include/fpdfdoc/fpdf_vt.h
core/include/fpdftext/fpdf_text.h
core/include/fxcodec/fx_codec.h
core/include/fxcodec/fx_codec_provider.h
core/include/fxcrt/fx_ext.h
core/include/fxcrt/fx_stream.h
core/include/fxge/fpf.h
core/include/fxge/fx_dib.h
core/include/fxge/fx_font.h
core/src/fdrm/crypto/fx_crypt.cpp
core/src/fdrm/crypto/fx_crypt_aes.cpp
core/src/fdrm/crypto/fx_crypt_sha.cpp
core/src/fpdfapi/fpdf_edit/fpdf_edit_content.cpp
core/src/fpdfapi/fpdf_edit/fpdf_edit_create.cpp
core/src/fpdfapi/fpdf_parser/fpdf_parser_filters.cpp
core/src/fpdfapi/fpdf_render/fpdf_render.cpp
core/src/fpdfdoc/doc_form.cpp
core/src/fpdfdoc/doc_link.cpp
core/src/fpdftext/fpdf_text.cpp
core/src/fpdftext/fpdf_text_int.cpp
core/src/fpdftext/fpdf_text_search.cpp
core/src/fpdftext/unicodenormalization.cpp
core/src/fxcodec/codec/fx_codec_jbig.cpp
core/src/fxcodec/codec/fx_codec_jpx_opj.cpp
core/src/fxcodec/jbig2/JBig2_Context.h
core/src/fxcodec/jbig2/JBig2_GeneralDecoder.h
core/src/fxcodec/jbig2/JBig2_Image.cpp
core/src/fxcodec/lcms2/lcms2-2.6/src/cmserr.c
core/src/fxcrt/extension.h
core/src/fxcrt/fx_arabic.cpp
core/src/fxcrt/fx_arabic.h
core/src/fxcrt/fx_basic_bstring_unittest.cpp
core/src/fxcrt/fx_basic_coords.cpp
core/src/fxcrt/fx_basic_gcc.cpp
core/src/fxcrt/fx_basic_maps.cpp
core/src/fxcrt/fx_basic_plex.cpp
core/src/fxcrt/fx_extension.cpp
core/src/fxcrt/fx_ucddata.cpp
core/src/fxcrt/fx_unicode.cpp
core/src/fxcrt/fxcrt_platforms.cpp
core/src/fxcrt/fxcrt_posix.cpp
core/src/fxcrt/fxcrt_windows.cpp
core/src/fxcrt/plex.h
core/src/fxcrt/xml_int.h
core/src/fxge/android/fx_fpf.h
core/src/fxge/apple/fx_apple_platform.cpp
core/src/fxge/ge/fx_ge_path.cpp
fpdfsdk/include/formfiller/FFL_Utils.h
fpdfsdk/include/formfiller/FormFiller.h
fpdfsdk/include/fsdk_define.h
fpdfsdk/include/fsdk_mgr.h
fpdfsdk/include/javascript/IJavaScript.h
fpdfsdk/include/javascript/JavaScript.h
fpdfsdk/include/javascript/resource.h
fpdfsdk/include/pdfwindow/PDFWindow.h
fpdfsdk/src/fpdf_ext.cpp
fpdfsdk/src/fpdf_searchex.cpp
fpdfsdk/src/fpdftext.cpp
fpdfsdk/src/fpdfview.cpp
fpdfsdk/src/javascript/JS_GlobalData.cpp
fpdfsdk/src/pdfwindow/PWL_Edit.cpp
testing/embedder_test.cpp
testing/embedder_test.h
testing/fx_string_testhelpers.h

index af72fcf..f820999 100644 (file)
@@ -7,7 +7,7 @@
 #ifndef CORE_INCLUDE_FDRM_FX_CRYPT_H_
 #define CORE_INCLUDE_FDRM_FX_CRYPT_H_
 
-#include "../fxcrt/fx_basic.h"
+#include "../fxcrt/fx_system.h"
 
 #ifdef __cplusplus
 extern "C" {
index 31bdb45..65e4117 100644 (file)
@@ -7,7 +7,8 @@
 #ifndef CORE_INCLUDE_FPDFAPI_FPDF_MODULE_H_
 #define CORE_INCLUDE_FPDFAPI_FPDF_MODULE_H_
 
-#include "../fxcrt/fx_ext.h"
+#include "../fxcrt/fx_coordinates.h"
+#include "../fxcrt/fx_system.h"
 
 class CCodec_ModuleMgr;
 class CFX_AffineMatrix;
index f2ace0b..570dc41 100644 (file)
@@ -7,7 +7,8 @@
 #ifndef CORE_INCLUDE_FPDFAPI_FPDF_OBJECTS_H_
 #define CORE_INCLUDE_FPDFAPI_FPDF_OBJECTS_H_
 
-#include "../fxcrt/fx_ext.h"
+#include "../fxcrt/fx_coordinates.h"
+#include "../fxcrt/fx_system.h"
 
 class CPDF_Array;
 class CPDF_Boolean;
index a5020eb..a856433 100644 (file)
@@ -7,7 +7,7 @@
 #ifndef CORE_INCLUDE_FPDFAPI_FPDF_PARSER_H_
 #define CORE_INCLUDE_FPDFAPI_FPDF_PARSER_H_
 
-#include "../fxcrt/fx_ext.h"
+#include "../fxcrt/fx_system.h"
 #include "fpdf_objects.h"
 
 class CPDF_Document;
index 00a0bb9..c2938a5 100644 (file)
@@ -7,7 +7,6 @@
 #ifndef CORE_INCLUDE_FPDFAPI_FPDFAPI_H_
 #define CORE_INCLUDE_FPDFAPI_FPDFAPI_H_
 
-#include "../fxcrt/fx_basic.h"
 #include "../fxge/fx_ge.h"
 #include "fpdf_module.h"
 #include "fpdf_pageobj.h"
index 3385e58..7cfaed4 100644 (file)
@@ -7,7 +7,6 @@
 #ifndef CORE_INCLUDE_FPDFDOC_FPDF_AP_H_
 #define CORE_INCLUDE_FPDFDOC_FPDF_AP_H_
 
-#include "../fxcrt/fx_basic.h"
 #include "../fpdfapi/fpdf_parser.h"
 #include "fpdf_vt.h"
 
index 3f14a46..4baba41 100644 (file)
@@ -8,7 +8,6 @@
 #define CORE_INCLUDE_FPDFDOC_FPDF_VT_H_
 
 #include "../fpdfapi/fpdf_parser.h"
-#include "../fxcrt/fx_basic.h"
 #include "../fxge/fx_dib.h"
 
 class IPDF_VariableText;
index e0b5eb8..ad5888e 100644 (file)
@@ -7,11 +7,11 @@
 #ifndef CORE_INCLUDE_FPDFTEXT_FPDF_TEXT_H_
 #define CORE_INCLUDE_FPDFTEXT_FPDF_TEXT_H_
 
-#include "../fpdfapi/fpdf_page.h"
-#include "../fpdfapi/fpdf_pageobj.h"
 #include "../fpdfapi/fpdf_parser.h"
 
+class CPDF_Page;
 class CPDF_PageObjects;
+class CPDF_TextObject;
 class IPDF_LinkExtract;
 class IPDF_ReflowedPage;
 class IPDF_TextPage;
index 43ac696..e8faf3f 100644 (file)
@@ -7,7 +7,7 @@
 #ifndef CORE_INCLUDE_FXCODEC_FX_CODEC_H_
 #define CORE_INCLUDE_FXCODEC_FX_CODEC_H_
 
-#include "../fxcrt/fx_ext.h"
+#include "../fxcrt/fx_basic.h"
 #include "fx_codec_def.h"
 #include "fx_codec_provider.h"
 
index 8eb3712..0b238b7 100644 (file)
@@ -7,6 +7,8 @@
 #ifndef CORE_INCLUDE_FXCODEC_FX_CODEC_PROVIDER_H_
 #define CORE_INCLUDE_FXCODEC_FX_CODEC_PROVIDER_H_
 
+#include "../fxcrt/fx_system.h"
+
 class IFX_JpegProvider
 {
 public:
index 03a9d0d..f24f454 100644 (file)
@@ -7,11 +7,7 @@
 #ifndef CORE_INCLUDE_FXCRT_FX_EXT_H_
 #define CORE_INCLUDE_FXCRT_FX_EXT_H_
 
-#include "fx_arb.h"
-#include "fx_basic.h"
-#include "fx_coordinates.h"
-#include "fx_ucd.h"
-#include "fx_xml.h"
+#include "fx_system.h"
 
 #ifdef __cplusplus
 extern "C" {
index 4099bef..fdd7b11 100644 (file)
@@ -7,7 +7,6 @@
 #ifndef CORE_INCLUDE_FXCRT_FX_STREAM_H_
 #define CORE_INCLUDE_FXCRT_FX_STREAM_H_
 
-#include "fx_memory.h"
 #include "fx_string.h"
 
 void* FX_OpenFolder(const FX_CHAR* path);
index 9ff294e..fb9bf4d 100644 (file)
@@ -7,6 +7,8 @@
 #ifndef CORE_INCLUDE_FXGE_FPF_H_
 #define CORE_INCLUDE_FXGE_FPF_H_
 
+#include "../fxcrt/fx_coordinates.h"
+
 class IFPF_DeviceModule;
 class IFPF_FontMgr;
 class IFPF_Font;
index 290c30a..5b8ee44 100644 (file)
@@ -7,7 +7,8 @@
 #ifndef CORE_INCLUDE_FXGE_FX_DIB_H_
 #define CORE_INCLUDE_FXGE_FX_DIB_H_
 
-#include "../fxcrt/fx_ext.h"
+#include "../fxcrt/fx_basic.h"
+#include "../fxcrt/fx_coordinates.h"
 
 enum FXDIB_Format {
     FXDIB_Invalid = 0,
index 365d57c..49b8f9a 100644 (file)
@@ -7,7 +7,7 @@
 #ifndef CORE_INCLUDE_FXGE_FX_FONT_H_
 #define CORE_INCLUDE_FXGE_FX_FONT_H_
 
-#include "../fxcrt/fx_ext.h"
+#include "../fxcrt/fx_system.h"
 #include "fx_dib.h"
 
 typedef struct FT_FaceRec_* FXFT_Face;
index 2076cbb..83a420a 100644 (file)
@@ -5,8 +5,6 @@
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
 #include "../../../include/fdrm/fx_crypt.h"
-#include "../../../include/fxcrt/fx_basic.h"
-#include "../../../include/fxcrt/fx_safe_types.h"
 
 #ifdef __cplusplus
 extern "C" {
index 7b5064f..4bd8710 100644 (file)
@@ -4,7 +4,6 @@
 
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
-#include "../../../include/fxcrt/fx_basic.h"
 #include "../../../include/fdrm/fx_crypt.h"
 #ifdef __cplusplus
 extern "C" {
index 012cbdb..b22348a 100644 (file)
@@ -4,7 +4,6 @@
 
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
-#include "../../../include/fxcrt/fx_basic.h"
 #include "../../../include/fdrm/fx_crypt.h"
 #ifdef __cplusplus
 extern "C" {
index 948908e..65f78da 100644 (file)
@@ -7,8 +7,8 @@
 #include "../../../include/fpdfapi/fpdf_page.h"
 #include "../../../include/fpdfapi/fpdf_serial.h"
 #include "../../../include/fpdfapi/fpdf_module.h"
-#include "../../../include/fxcodec/fx_codec.h"
 #include "../fpdf_page/pageint.h"
+
 CFX_ByteTextBuf& operator << (CFX_ByteTextBuf& ar, CFX_AffineMatrix& matrix)
 {
     ar << matrix.a << " " << matrix.b << " " << matrix.c << " " << matrix.d << " " << matrix.e << " " << matrix.f;
index 93531de..b7eb05f 100644 (file)
@@ -4,8 +4,10 @@
 
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
+#include "../../../include/fxcrt/fx_ext.h"
 #include "../../../include/fpdfapi/fpdf_serial.h"
 #include "editint.h"
+
 #define PDF_OBJECTSTREAM_MAXLENGTH     (256 * 1024)
 #define PDF_XREFSTREAM_MAXSIZE         10000
 extern void FlateEncode(const uint8_t* src_buf, FX_DWORD src_data, uint8_t*& dest_buf, FX_DWORD& dest_size);
index 6c33d82..507a429 100644 (file)
@@ -4,11 +4,12 @@
 
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
-#include "../../fx_zlib.h"
 #include "../../../include/fpdfapi/fpdf_parser.h"
 #include "../../../include/fxcodec/fx_codec.h"
 #include "../../../include/fpdfapi/fpdf_module.h"
+#include "../../fx_zlib.h"
 #include "filters_int.h"
+
 CFX_DataFilter::CFX_DataFilter()
 {
     m_bEOF = FALSE;
index 01bec5b..608e124 100644 (file)
@@ -4,12 +4,12 @@
 
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
-#include "../../../include/fpdfapi/fpdf_render.h"
 #include "../../../include/fpdfapi/fpdf_module.h"
-#include "../fpdf_page/pageint.h"
+#include "../../../include/fpdfapi/fpdf_render.h"
 #include "../../../include/fxge/fx_ge.h"
-#include "../../../include/fxcodec/fx_codec.h"
+#include "../fpdf_page/pageint.h"
 #include "render_int.h"
+
 CPDF_DocRenderData::CPDF_DocRenderData(CPDF_Document* pPDFDoc)
     : m_pPDFDoc(pPDFDoc)
     , m_pFontCache(NULL)
index 4124c8f..2b59bee 100644 (file)
@@ -5,7 +5,6 @@
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
 #include "../../include/fpdfdoc/fpdf_doc.h"
-#include "../../include/fxcrt/fx_xml.h"
 #include "doc_utils.h"
 
 const int nMaxRecursion = 32;
index 56c3ed2..fdae96a 100644 (file)
@@ -5,7 +5,6 @@
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
 #include "../../include/fpdfdoc/fpdf_doc.h"
-#include "../../include/fxcrt/fx_safe_types.h"
 
 CPDF_LinkList::~CPDF_LinkList()
 {
index 38715e5..30934f6 100644 (file)
@@ -7,8 +7,11 @@
 #include "../../include/fpdfapi/fpdf_page.h"
 #include "../../include/fpdfapi/fpdf_pageobj.h"
 #include "../../include/fpdftext/fpdf_text.h"
-#include "txtproc.h"
+#include "../../include/fxcrt/fx_arb.h"
+#include "../../include/fxcrt/fx_ucd.h"
 #include "text_int.h"
+#include "txtproc.h"
+
 extern const FX_CHAR* FCS_GetAltStr(FX_WCHAR);
 CFX_ByteString CharFromUnicodeAlt(FX_WCHAR unicode, int destcp, const FX_CHAR* defchar)
 {
index b5e6213..712de48 100644 (file)
@@ -4,13 +4,16 @@
 
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
-#include "../../include/fpdfapi/fpdf_resource.h"
-#include "../../include/fpdfapi/fpdf_pageobj.h"
-#include "../../include/fpdftext/fpdf_text.h"
-#include "../../include/fpdfapi/fpdf_page.h"
-#include "../../include/fpdfapi/fpdf_module.h"
 #include <ctype.h>
 #include <algorithm>
+
+#include "../../include/fpdfapi/fpdf_module.h"
+#include "../../include/fpdfapi/fpdf_page.h"
+#include "../../include/fpdfapi/fpdf_pageobj.h"
+#include "../../include/fpdfapi/fpdf_resource.h"
+#include "../../include/fpdftext/fpdf_text.h"
+#include "../../include/fxcrt/fx_arb.h"
+#include "../../include/fxcrt/fx_ucd.h"
 #include "text_int.h"
 
 namespace {
index 07f493e..21a2564 100644 (file)
@@ -5,7 +5,6 @@
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
 #include "../../include/fpdfapi/fpdf_pageobj.h"
-#include "../../include/fpdftext/fpdf_text.h"
 #include "../../include/fpdfapi/fpdf_page.h"
 class CPDF_TextStream
 {
index fa3d812..468900c 100644 (file)
@@ -4,7 +4,8 @@
 
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
-#include "../../include/fpdftext/fpdf_text.h"
+#include "../../include/fxcrt/fx_string.h"
+
 extern const FX_WCHAR g_UnicodeData_Normalization[];
 extern const FX_WCHAR g_UnicodeData_Normalization_Map1[];
 extern const FX_WCHAR g_UnicodeData_Normalization_Map2[];
index d953220..7a69a24 100644 (file)
@@ -6,6 +6,7 @@
 
 #include "../../../include/fxcodec/fx_codec.h"
 #include "codec_int.h"
+
 CCodec_Jbig2Context::CCodec_Jbig2Context()
 {
     FXSYS_memset(this, 0, sizeof(CCodec_Jbig2Context));
index ce82960..4f548ea 100644 (file)
@@ -8,9 +8,9 @@
 #include <limits>
 
 #include "../../../include/fxcodec/fx_codec.h"
-#include "codec_int.h"
 #include "../fx_libopenjpeg/libopenjpeg20/openjpeg.h"
 #include "../lcms2/include/fx_lcms2.h"
+#include "codec_int.h"
 
 static void fx_error_callback(const char *msg, void *client_data)
 {
index b12853a..6e47a8a 100644 (file)
@@ -1,19 +1,22 @@
 // Copyright 2014 PDFium Authors. All rights reserved.
 // Use of this source code is governed by a BSD-style license that can be
 // found in the LICENSE file.
+
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
 #ifndef _JBIG2_CONTEXT_H_
 #define _JBIG2_CONTEXT_H_
+
+#include <list>
+#include <utility>
+
 #include "JBig2_Module.h"
 #include "JBig2_List.h"
 #include "JBig2_Segment.h"
 #include "JBig2_Page.h"
 #include "JBig2_GeneralDecoder.h"
 #include "../../../include/fxcodec/fx_codec_def.h"
-#include "../../../include/fxcrt/fx_basic.h"
-#include <utility>
+
 typedef std::pair<uint8_t*, CJBig2_SymbolDict*> CJBig2_CachePair;
 typedef enum {
     JBIG2_OUT_OF_PAGE = 0,
index 45e2940..2bd2cea 100644 (file)
@@ -1,18 +1,19 @@
 // Copyright 2014 PDFium Authors. All rights reserved.
 // Use of this source code is governed by a BSD-style license that can be
 // found in the LICENSE file.
+
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
 #ifndef _JBIG2_GENERAL_DECODER_H_
 #define _JBIG2_GENERAL_DECODER_H_
+
 #include "../../../include/fxcodec/fx_codec_def.h"
-#include "../../../include/fxcrt/fx_basic.h"
-#include "JBig2_Define.h"
-#include "JBig2_SymbolDict.h"
+#include "../../../include/fxcrt/fx_coordinates.h"
 #include "JBig2_ArithDecoder.h"
 #include "JBig2_ArithIntDecoder.h"
-#include "../../../include/fxcrt/fx_coordinates.h"
+#include "JBig2_Define.h"
+#include "JBig2_SymbolDict.h"
+
 class CJBig2_HuffmanTable;
 class CJBig2_Image;
 class CJBig2_PatternDict;
index 044ccf7..9ef4464 100644 (file)
@@ -6,7 +6,6 @@
 
 #include <limits.h>
 
-#include "../../../include/fxcrt/fx_basic.h"
 #include "../../../include/fxcrt/fx_coordinates.h"
 #include "../../../include/fxcrt/fx_safe_types.h"
 #include "JBig2_Image.h"
index a32b6e2..b008b52 100644 (file)
@@ -251,8 +251,8 @@ cmsBool  _cmsRegisterMemHandlerPlugin(cmsContext ContextID, cmsPluginBase *Data)
     return TRUE;
 }
 #else
-#include "../../../../../include/fxcrt/fx_system.h"
 #include "../../../../../include/fxcrt/fx_memory.h"
+#include "../../../../../include/fxcrt/fx_system.h"
 
 cmsBool  _cmsRegisterMemHandlerPlugin(cmsContext ContextID, cmsPluginBase* Plugin)
 {
index 2de553a..ba42916 100644 (file)
@@ -7,6 +7,7 @@
 #ifndef CORE_SRC_FXCRT_EXTENSION_H_
 #define CORE_SRC_FXCRT_EXTENSION_H_
 
+#include "../../include/fxcrt/fx_basic.h"
 #include "../../include/fxcrt/fx_safe_types.h"
 
 class IFXCRT_FileAccess
index 27da674..94b514b 100644 (file)
@@ -4,8 +4,9 @@
 
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
-#include "../../include/fxcrt/fx_ext.h"
+#include "../../include/fxcrt/fx_ucd.h"
 #include "fx_arabic.h"
+
 extern const FX_DWORD gs_FX_TextLayout_CodeProperties[65536];
 IFX_BidiChar* IFX_BidiChar::Create()
 {
index 8701361..e7e6a28 100644 (file)
@@ -7,6 +7,8 @@
 #ifndef CORE_SRC_FXCRT_FX_ARABIC_H_
 #define CORE_SRC_FXCRT_FX_ARABIC_H_
 
+#include "../../include/fxcrt/fx_arb.h"
+
 class CFX_BidiChar final : public IFX_BidiChar
 {
 public:
index 9d8f376..f865602 100644 (file)
@@ -2,9 +2,9 @@
 // Use of this source code is governed by a BSD-style license that can be
 // found in the LICENSE file.
 
-#include "testing/gtest/include/gtest/gtest.h"
 #include "../../../testing/fx_string_testhelpers.h"
-#include "../../include/fxcrt/fx_basic.h"
+#include "../../include/fxcrt/fx_string.h"
+#include "testing/gtest/include/gtest/gtest.h"
 
 TEST(fxcrt, ByteStringOperatorSubscript) {
     // CFX_ByteString includes the NUL terminator for non-empty strings.
index 67e2032..2e83080 100644 (file)
@@ -5,7 +5,10 @@
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
 #include <limits.h>
+
+#include "../../include/fxcrt/fx_coordinates.h"
 #include "../../include/fxcrt/fx_ext.h"
+
 void FX_RECT::Normalize()
 {
     if (left > right) {
index b5a81ad..e4416e9 100644 (file)
@@ -5,7 +5,10 @@
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
 #include <limits>
+
 #include "../../include/fxcrt/fx_ext.h"
+#include "../../include/fxcrt/fx_string.h"
+
 template <class T, class STR_T>
 T FXSYS_StrToInt(STR_T str)
 {
index 8a886f8..e34acb0 100644 (file)
@@ -4,8 +4,9 @@
 
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
-#include "../../include/fxcrt/fx_ext.h"
+#include "../../include/fxcrt/fx_basic.h"
 #include "plex.h"
+
 static void ConstructElement(CFX_ByteString* pNewData)
 {
     new (pNewData) CFX_ByteString();
index 8024296..c9088bc 100644 (file)
@@ -4,8 +4,9 @@
 
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
-#include "../../include/fxcrt/fx_basic.h"
+#include "../../include/fxcrt/fx_memory.h"
 #include "plex.h"
+
 CFX_Plex* CFX_Plex::Create(CFX_Plex*& pHead, FX_DWORD nMax, FX_DWORD cbElement)
 {
     CFX_Plex* p = (CFX_Plex*)FX_Alloc(uint8_t, sizeof(CFX_Plex) + nMax * cbElement);
index 98f70cb..4662e8f 100644 (file)
@@ -4,6 +4,7 @@
 
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
+#include "../../include/fxcrt/fx_basic.h"
 #include "../../include/fxcrt/fx_ext.h"
 #include "extension.h"
 #if _FXM_PLATFORM_ == _FXM_PLATFORM_WINDOWS_
@@ -11,6 +12,7 @@
 #else
 #include <ctime>
 #endif
+
 FX_HFILE FX_File_Open(const CFX_ByteStringC& fileName, FX_DWORD dwMode)
 {
     IFXCRT_FileAccess* pFA = FXCRT_FileAccess_Create();
index d3ea5cc..e632769 100644 (file)
@@ -4,7 +4,8 @@
 
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
-#include "../../include/fxcrt/fx_ext.h"
+#include "../../include/fxcrt/fx_system.h"
+
 extern const FX_DWORD gs_FX_TextLayout_CodeProperties[65536] = {
     0xfffe9a93, 0xfffe9a93, 0xfffe9a93, 0xfffe9a93, 0xfffe9a93, 0xfffe9a93, 0xfffe9a93, 0xfffe9a93, 0xfffe9a93, 0xfffe8ae5, 0xfffe9b5c, 0xfffe9ada, 0xfffe9b1a, 0xfffe9b5b, 0xfffe9a93, 0xfffe9a93,
     0xfffe9a93, 0xfffe9a93, 0xfffe9a93, 0xfffe9a93, 0xfffe9a93, 0xfffe9a93, 0xfffe9a93, 0xfffe9a93, 0xfffe9a93, 0xfffe9a93, 0xfffe9a93, 0xfffe9a93, 0xfffe9b53, 0xfffe9b53, 0xfffe9b53, 0xfffe9ad3,
index 08a7443..d66a58a 100644 (file)
@@ -4,7 +4,8 @@
 
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
-#include "../../include/fxcrt/fx_ext.h"
+#include "../../include/fxcrt/fx_ucd.h"
+
 extern const FX_DWORD gs_FX_TextLayout_CodeProperties[65536];
 extern const FX_WCHAR gs_FX_TextLayout_VerticalMirror[64];
 extern const FX_WCHAR gs_FX_TextLayout_BidiMirror[512];
index a6ec964..e718294 100644 (file)
@@ -4,8 +4,9 @@
 
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
-#include "../../include/fxcrt/fx_ext.h"
+#include "../../include/fxcrt/fx_basic.h"
 #include "fxcrt_platforms.h"
+
 #if (_FXM_PLATFORM_ != _FXM_PLATFORM_WINDOWS_ && _FXM_PLATFORM_ != _FXM_PLATFORM_LINUX_ && _FXM_PLATFORM_ != _FXM_PLATFORM_APPLE_ && _FXM_PLATFORM_ != _FXM_PLATFORM_ANDROID_)
 IFXCRT_FileAccess* FXCRT_FileAccess_Create()
 {
index 2ae29cb..84646ef 100644 (file)
@@ -4,8 +4,9 @@
 
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
-#include "../../include/fxcrt/fx_ext.h"
+#include "../../include/fxcrt/fx_basic.h"
 #include "fxcrt_posix.h"
+
 #if _FXM_PLATFORM_ == _FXM_PLATFORM_LINUX_ || _FXM_PLATFORM_ == _FXM_PLATFORM_APPLE_ || _FXM_PLATFORM_ == _FXM_PLATFORM_ANDROID_
 IFXCRT_FileAccess* FXCRT_FileAccess_Create()
 {
index c16f256..34d918b 100644 (file)
@@ -4,8 +4,9 @@
 
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
-#include "../../include/fxcrt/fx_ext.h"
+#include "../../include/fxcrt/fx_string.h"
 #include "fxcrt_windows.h"
+
 #if _FXM_PLATFORM_ == _FXM_PLATFORM_WINDOWS_
 FX_BOOL FX_File_Exist(const CFX_ByteStringC& fileName)
 {
index a4ac4f7..baf27f5 100644 (file)
@@ -6,6 +6,8 @@
 #ifndef CORE_SRC_FXCRT_PLEX_H_
 #define CORE_SRC_FXCRT_PLEX_H_
 
+#include "../../include/fxcrt/fx_system.h"
+
 struct CFX_Plex {
     CFX_Plex* pNext;
     void* data()
index 9469a75..109c7a4 100644 (file)
@@ -7,6 +7,8 @@
 #ifndef CORE_SRC_FXCRT_XML_INT_H_
 #define CORE_SRC_FXCRT_XML_INT_H_
 
+#include "../../include/fxcrt/fx_stream.h"
+
 class CXML_DataBufAcc : public IFX_BufferRead
 {
 public:
index caf3a9f..a484c1e 100644 (file)
@@ -7,7 +7,6 @@
 #ifndef CORE_SRC_FXGE_ANDROID_FX_FPF_H_
 #define CORE_SRC_FXGE_ANDROID_FX_FPF_H_
 
-#include "../../../include/fxcrt/fx_ext.h"
 #include "../../../include/fxge/fpf.h"
 #include "../../../include/fxge/fx_freetype.h"
 #include "../../../include/fxge/fx_ge.h"
index 5186ed4..07c5b6c 100644 (file)
@@ -4,7 +4,7 @@
 
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
-#include "../../../include/fxcrt/fx_ext.h"
+#include "../../../include/fxcrt/fx_system.h"
 #include "../../../include/fxge/fx_ge.h"
 #if _FXM_PLATFORM_  == _FXM_PLATFORM_APPLE_
 #include "apple_int.h"
index 96f5762..ea1d803 100644 (file)
@@ -5,7 +5,7 @@
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
 #include "../../../../third_party/base/numerics/safe_math.h"
-#include "../../../include/fxcrt/fx_basic.h"
+#include "../../../include/fxcrt/fx_system.h"
 #include "../../../include/fxge/fx_ge.h"
 
 CFX_ClipRgn::CFX_ClipRgn(int width, int height)
index de9afaf..fe025ec 100644 (file)
@@ -8,17 +8,16 @@
 #define FPDFSDK_INCLUDE_FORMFILLER_FFL_UTILS_H_
 
 #include "../../../core/include/fpdfapi/fpdf_parser.h"
-#include "../../../core/include/fxcrt/fx_memory.h"
-
-#define FFL_BASE_USERUNIT                      (1.0f / 72.0f)
 
 class CFFL_Utils
 {
 public:
-       static CPDF_Rect                                MaxRect(const CPDF_Rect & rect1,const CPDF_Rect & rect2);
-       static CPDF_Rect                                InflateRect(const CPDF_Rect & crRect, const FX_FLOAT & fSize);
-       static CPDF_Rect                                DeflateRect(const CPDF_Rect & crRect, const FX_FLOAT & fSize);
-       static FX_BOOL                                  TraceObject(CPDF_Object* pObj);
+    static CPDF_Rect MaxRect(const CPDF_Rect& rect1,const CPDF_Rect& rect2);
+    static CPDF_Rect InflateRect(const CPDF_Rect& crRect,
+                                 const FX_FLOAT& fSize);
+    static CPDF_Rect DeflateRect(const CPDF_Rect& crRect,
+                                 const FX_FLOAT& fSize);
+    static FX_BOOL TraceObject(CPDF_Object* pObj);
 };
 
 #endif  // FPDFSDK_INCLUDE_FORMFILLER_FFL_UTILS_H_
index fdca1ff..90351f5 100644 (file)
@@ -10,7 +10,6 @@
 #include "../../../core/include/fpdfapi/fpdf_module.h"
 #include "../../../core/include/fpdfdoc/fpdf_doc.h"
 #include "../../../core/include/fpdfdoc/fpdf_vt.h"
-#include "../../../core/include/fxcrt/fx_xml.h"
 #include "../fsdk_mgr.h"
 #include "../fxedit/fx_edit.h"
 #include "../pdfwindow/IPDFWindow.h"
index a80e5f5..f809043 100644 (file)
 #include <math.h>
 #endif
 
+#include "../../core/include/fpdfapi/fpdf_module.h"
+#include "../../core/include/fpdfapi/fpdf_pageobj.h"
 #include "../../core/include/fpdfapi/fpdf_parser.h"
-#include "../../core/include/fpdfapi/fpdfapi.h"
 #include "../../core/include/fpdfapi/fpdf_parser.h"
-#include "../../core/include/fpdfapi/fpdf_module.h"
 #include "../../core/include/fpdfapi/fpdf_render.h"
-#include "../../core/include/fpdfapi/fpdf_pageobj.h"
 #include "../../core/include/fpdfapi/fpdf_serial.h"
-
-#include "../../core/include/fpdftext/fpdf_text.h"
-
-#include "../../core/include/fxge/fx_ge_win32.h"
-#include "../../core/include/fxge/fx_ge.h"
-
-#include "../../core/include/fxcodec/fx_codec.h"
-
+#include "../../core/include/fpdfapi/fpdfapi.h"
 #include "../../core/include/fpdfdoc/fpdf_doc.h"
 #include "../../core/include/fpdfdoc/fpdf_vt.h"
-
-#include "../../core/include/fxcrt/fx_xml.h"
+#include "../../core/include/fxge/fx_ge.h"
+#include "../../core/include/fxge/fx_ge_win32.h"
 
 
 #ifndef FX_GetAValue
index 166b421..18092bb 100644 (file)
@@ -7,6 +7,7 @@
 #ifndef FPDFSDK_INCLUDE_FSDK_MGR_H_
 #define FPDFSDK_INCLUDE_FSDK_MGR_H_
 
+#include "../../core/include/fpdftext/fpdf_text.h"
 #include "../../public/fpdf_formfill.h"
 #include "../../public/fpdf_fwlevent.h" // cross platform keycode and events define.
 #include "fsdk_common.h"
@@ -16,6 +17,7 @@
 #include "fsdk_baseform.h"
 #include "fsdk_annothandler.h"
 #include "fsdk_actionhandler.h"
+#include "javascript/IJavaScript.h"
 
 class CPDFSDK_Document;
 class CPDFSDK_PageView;
@@ -26,8 +28,6 @@ class IFX_SystemHandler;
 class CPDFSDK_ActionHandler;
 class CJS_RuntimeFactory;
 
-#include "javascript/IJavaScript.h"
-
 class CPDFDoc_Environment final
 {
 public:
index 1d0c55f..783b249 100644 (file)
@@ -7,7 +7,8 @@
 #ifndef FPDFSDK_INCLUDE_JAVASCRIPT_IJAVASCRIPT_H_
 #define FPDFSDK_INCLUDE_JAVASCRIPT_IJAVASCRIPT_H_
 
-#include "../../../core/include/fxcrt/fx_basic.h"
+#include "../../../core/include/fxcrt/fx_string.h"
+#include "../../../core/include/fxcrt/fx_system.h"
 
 class CPDF_Bookmark;
 class CPDF_FormField;
index 96cb9ba..655aca0 100644 (file)
 #include <string>
 #include <vector>
 
-#include "../../../core/include/fdrm/fx_crypt.h"
 #include "../../../core/include/fpdfapi/fpdf_module.h"
 #include "../../../core/include/fpdfapi/fpdf_pageobj.h"
 #include "../../../core/include/fpdfapi/fpdf_serial.h"
 #include "../../../core/include/fpdfdoc/fpdf_doc.h"
 #include "../../../core/include/fpdfdoc/fpdf_vt.h"
-#include "../../../core/include/fxcrt/fx_xml.h"
 #include "../fsdk_mgr.h"
 #include "../fx_systemhandler.h"
 #include "../fxedit/fx_edit.h"
index 88011f2..4337859 100644 (file)
@@ -7,7 +7,7 @@
 #ifndef FPDFSDK_INCLUDE_JAVASCRIPT_RESOURCE_H_
 #define FPDFSDK_INCLUDE_JAVASCRIPT_RESOURCE_H_
 
-#include "../../../core/include/fxcrt/fx_basic.h"  // For CFX_WideString.
+#include "../../../core/include/fxcrt/fx_string.h"  // For CFX_WideString.
 #include "../fsdk_define.h"  // For FX_UINT.
 
 class CJS_Context;
index 3cd1e02..2abb38c 100644 (file)
@@ -10,7 +10,6 @@
 #include "../../../core/include/fpdfapi/fpdf_module.h"
 #include "../../../core/include/fpdfdoc/fpdf_doc.h"
 #include "../../../core/include/fpdfdoc/fpdf_vt.h"
-#include "../../../core/include/fxcrt/fx_xml.h"
 #include "../../../public/fpdf_fwlevent.h"
 #include "../fx_systemhandler.h"
 #include "../fxedit/fx_edit.h"
index 1e68c6b..9afe9b5 100644 (file)
@@ -4,6 +4,7 @@
 
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
+#include "../../core/include/fxcrt/fx_xml.h"
 #include "../../public/fpdf_ext.h"
 #include "../include/fsdk_define.h"
 
index d63f8ff..e012d30 100644 (file)
@@ -5,10 +5,14 @@
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
 #include "../../public/fpdf_searchex.h"
-#include "../include/fsdk_define.h"
 
-DLLEXPORT int STDCALL  FPDFText_GetCharIndexFromTextIndex(FPDF_TEXTPAGE text_page, int nTextIndex)
+#include "../../core/include/fpdftext/fpdf_text.h"
+
+DLLEXPORT int STDCALL FPDFText_GetCharIndexFromTextIndex(
+    FPDF_TEXTPAGE text_page,
+    int nTextIndex)
 {
-       if(!text_page) return -1;
-       return ((IPDF_TextPage*)text_page)->CharIndexFromTextIndex(nTextIndex);
+    if (!text_page)
+        return -1;
+    return ((IPDF_TextPage*)text_page)->CharIndexFromTextIndex(nTextIndex);
 }
index 1840247..aba24f4 100644 (file)
@@ -4,8 +4,9 @@
 
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
+#include "../../core/include/fpdfdoc/fpdf_doc.h"
+#include "../../core/include/fpdftext/fpdf_text.h"
 #include "../../public/fpdf_text.h"
-#include "../include/fsdk_define.h"
 
 #ifdef _WIN32
 #include <tchar.h>
index 10bfc3d..48c6516 100644 (file)
@@ -4,6 +4,7 @@
 
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
+#include "../../core/include/fxcodec/fx_codec.h"
 #include "../../core/include/fxcrt/fx_safe_types.h"
 #include "../../public/fpdf_ext.h"
 #include "../../public/fpdf_progressive.h"
index 2947a63..2ba5c3b 100644 (file)
@@ -4,6 +4,7 @@
 
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
+#include "../../../core/include/fdrm/fx_crypt.h"
 #include "../../include/javascript/JavaScript.h"
 #include "../../include/javascript/IJavaScript.h"
 #include "../../include/javascript/JS_GlobalData.h"
index 627e7a8..58d8a79 100644 (file)
@@ -5,6 +5,7 @@
 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
 
 #include "../../../core/include/fxcrt/fx_safe_types.h"
+#include "../../../core/include/fxcrt/fx_xml.h"
 #include "../../include/pdfwindow/PDFWindow.h"
 #include "../../include/pdfwindow/PWL_Caret.h"
 #include "../../include/pdfwindow/PWL_Edit.h"
index 8457a79..ee2ad08 100644 (file)
@@ -14,7 +14,6 @@
 #include <utility>
 #include <vector>
 
-#include "../core/include/fxcrt/fx_system.h"
 #include "../public/fpdf_text.h"
 #include "../public/fpdfview.h"
 #include "testing/gmock/include/gmock/gmock.h"
index b0834dd..0ac68d5 100644 (file)
@@ -7,7 +7,6 @@
 
 #include <string>
 
-#include "../core/include/fxcrt/fx_system.h"
 #include "../public/fpdf_dataavail.h"
 #include "../public/fpdf_ext.h"
 #include "../public/fpdf_formfill.h"
index 7d06688..13b4afb 100644 (file)
@@ -7,7 +7,7 @@
 
 #include <ostream>
 
-#include "../core/include/fxcrt/fx_basic.h"
+#include "../core/include/fxcrt/fx_string.h"
 
 // Output stream operator so GTEST macros work with FX strings.
 std::ostream& operator<<(std::ostream& out, const CFX_ByteStringC& str);