summaryrefslogtreecommitdiff
path: root/core/fpdfapi
diff options
context:
space:
mode:
Diffstat (limited to 'core/fpdfapi')
-rw-r--r--core/fpdfapi/edit/cpdf_creator.cpp1
-rw-r--r--core/fpdfapi/edit/cpdf_flateencoder.cpp1
-rw-r--r--core/fpdfapi/edit/cpdf_flateencoder.h2
-rw-r--r--core/fpdfapi/edit/cpdf_pagecontentgenerator_unittest.cpp1
-rw-r--r--core/fpdfapi/font/cfx_stockfontarray.cpp3
-rw-r--r--core/fpdfapi/font/cpdf_cmapmanager.cpp1
-rw-r--r--core/fpdfapi/page/cpdf_meshstream.cpp1
-rw-r--r--core/fpdfapi/page/cpdf_sampledfunc.cpp1
-rw-r--r--core/fpdfapi/page/cpdf_streamparser.h3
-rw-r--r--core/fpdfapi/parser/cpdf_object_walker.h6
-rw-r--r--core/fpdfapi/parser/cpdf_stream.h1
-rw-r--r--core/fpdfapi/parser/cpdf_stream_acc.cpp1
-rw-r--r--core/fpdfapi/parser/cpdf_stream_acc.h3
-rw-r--r--core/fpdfapi/parser/cpdf_stream_acc_unittest.cpp2
14 files changed, 19 insertions, 8 deletions
diff --git a/core/fpdfapi/edit/cpdf_creator.cpp b/core/fpdfapi/edit/cpdf_creator.cpp
index 0823146b15..a42cfaa852 100644
--- a/core/fpdfapi/edit/cpdf_creator.cpp
+++ b/core/fpdfapi/edit/cpdf_creator.cpp
@@ -12,6 +12,7 @@
#include "core/fpdfapi/edit/cpdf_flateencoder.h"
#include "core/fpdfapi/parser/cpdf_array.h"
#include "core/fpdfapi/parser/cpdf_crypto_handler.h"
+#include "core/fpdfapi/parser/cpdf_dictionary.h"
#include "core/fpdfapi/parser/cpdf_document.h"
#include "core/fpdfapi/parser/cpdf_number.h"
#include "core/fpdfapi/parser/cpdf_parser.h"
diff --git a/core/fpdfapi/edit/cpdf_flateencoder.cpp b/core/fpdfapi/edit/cpdf_flateencoder.cpp
index a42b256ed2..ba04d7d938 100644
--- a/core/fpdfapi/edit/cpdf_flateencoder.cpp
+++ b/core/fpdfapi/edit/cpdf_flateencoder.cpp
@@ -9,6 +9,7 @@
#include <memory>
#include "constants/stream_dict_common.h"
+#include "core/fpdfapi/parser/cpdf_dictionary.h"
#include "core/fpdfapi/parser/cpdf_name.h"
#include "core/fpdfapi/parser/cpdf_number.h"
#include "core/fpdfapi/parser/fpdf_parser_decode.h"
diff --git a/core/fpdfapi/edit/cpdf_flateencoder.h b/core/fpdfapi/edit/cpdf_flateencoder.h
index 14ca7cec16..5fc5fe947f 100644
--- a/core/fpdfapi/edit/cpdf_flateencoder.h
+++ b/core/fpdfapi/edit/cpdf_flateencoder.h
@@ -9,13 +9,13 @@
#include <memory>
-#include "core/fpdfapi/parser/cpdf_dictionary.h"
#include "core/fpdfapi/parser/cpdf_stream_acc.h"
#include "core/fxcrt/fx_memory.h"
#include "core/fxcrt/maybe_owned.h"
#include "core/fxcrt/retain_ptr.h"
#include "third_party/base/span.h"
+class CPDF_Dictionary;
class CPDF_Stream;
class CPDF_FlateEncoder {
diff --git a/core/fpdfapi/edit/cpdf_pagecontentgenerator_unittest.cpp b/core/fpdfapi/edit/cpdf_pagecontentgenerator_unittest.cpp
index 99bb42e3b4..249dd8ef0d 100644
--- a/core/fpdfapi/edit/cpdf_pagecontentgenerator_unittest.cpp
+++ b/core/fpdfapi/edit/cpdf_pagecontentgenerator_unittest.cpp
@@ -13,6 +13,7 @@
#include "core/fpdfapi/page/cpdf_page.h"
#include "core/fpdfapi/page/cpdf_pathobject.h"
#include "core/fpdfapi/page/cpdf_textobject.h"
+#include "core/fpdfapi/parser/cpdf_dictionary.h"
#include "core/fpdfapi/parser/cpdf_document.h"
#include "core/fpdfapi/parser/cpdf_name.h"
#include "core/fpdfapi/parser/cpdf_parser.h"
diff --git a/core/fpdfapi/font/cfx_stockfontarray.cpp b/core/fpdfapi/font/cfx_stockfontarray.cpp
index 3b61e11f36..0aa984dec9 100644
--- a/core/fpdfapi/font/cfx_stockfontarray.cpp
+++ b/core/fpdfapi/font/cfx_stockfontarray.cpp
@@ -9,9 +9,10 @@
#include <memory>
#include <utility>
+#include "core/fpdfapi/parser/cpdf_dictionary.h"
#include "core/fxcrt/fx_memory.h"
-CFX_StockFontArray::CFX_StockFontArray() {}
+CFX_StockFontArray::CFX_StockFontArray() = default;
CFX_StockFontArray::~CFX_StockFontArray() {
for (size_t i = 0; i < FX_ArraySize(m_StockFonts); ++i) {
diff --git a/core/fpdfapi/font/cpdf_cmapmanager.cpp b/core/fpdfapi/font/cpdf_cmapmanager.cpp
index c33759cd11..8eebd89b30 100644
--- a/core/fpdfapi/font/cpdf_cmapmanager.cpp
+++ b/core/fpdfapi/font/cpdf_cmapmanager.cpp
@@ -10,6 +10,7 @@
#include "core/fpdfapi/font/cpdf_cid2unicodemap.h"
#include "core/fpdfapi/font/cpdf_cmap.h"
+#include "third_party/base/ptr_util.h"
#include "third_party/base/stl_util.h"
CPDF_CMapManager::CPDF_CMapManager() {}
diff --git a/core/fpdfapi/page/cpdf_meshstream.cpp b/core/fpdfapi/page/cpdf_meshstream.cpp
index 57a5dd1da1..7503ccb625 100644
--- a/core/fpdfapi/page/cpdf_meshstream.cpp
+++ b/core/fpdfapi/page/cpdf_meshstream.cpp
@@ -9,6 +9,7 @@
#include "core/fpdfapi/page/cpdf_colorspace.h"
#include "core/fpdfapi/page/cpdf_function.h"
#include "core/fpdfapi/parser/cpdf_array.h"
+#include "core/fpdfapi/parser/cpdf_dictionary.h"
#include "third_party/base/span.h"
namespace {
diff --git a/core/fpdfapi/page/cpdf_sampledfunc.cpp b/core/fpdfapi/page/cpdf_sampledfunc.cpp
index 143aeb4f8a..d898daadc5 100644
--- a/core/fpdfapi/page/cpdf_sampledfunc.cpp
+++ b/core/fpdfapi/page/cpdf_sampledfunc.cpp
@@ -7,6 +7,7 @@
#include "core/fpdfapi/page/cpdf_sampledfunc.h"
#include "core/fpdfapi/parser/cpdf_array.h"
+#include "core/fpdfapi/parser/cpdf_dictionary.h"
#include "core/fxcrt/cfx_bitstream.h"
#include "core/fxcrt/cfx_fixedbufgrow.h"
#include "core/fxcrt/fx_safe_types.h"
diff --git a/core/fpdfapi/page/cpdf_streamparser.h b/core/fpdfapi/page/cpdf_streamparser.h
index 062527813c..af181ffbd1 100644
--- a/core/fpdfapi/page/cpdf_streamparser.h
+++ b/core/fpdfapi/page/cpdf_streamparser.h
@@ -10,7 +10,6 @@
#include <memory>
#include <utility>
-#include "core/fpdfapi/parser/cpdf_dictionary.h"
#include "core/fpdfapi/parser/cpdf_document.h"
#include "core/fpdfapi/parser/cpdf_object.h"
#include "core/fpdfapi/parser/cpdf_stream.h"
@@ -18,6 +17,8 @@
#include "core/fxcrt/weak_ptr.h"
#include "third_party/base/span.h"
+class CPDF_Dictionary;
+
class CPDF_StreamParser {
public:
enum SyntaxType { EndOfData, Number, Keyword, Name, Others };
diff --git a/core/fpdfapi/parser/cpdf_object_walker.h b/core/fpdfapi/parser/cpdf_object_walker.h
index e0fd35de29..0af683c01c 100644
--- a/core/fpdfapi/parser/cpdf_object_walker.h
+++ b/core/fpdfapi/parser/cpdf_object_walker.h
@@ -8,9 +8,11 @@
#include <memory>
#include <stack>
-#include "core/fpdfapi/parser/cpdf_dictionary.h"
+#include "core/fxcrt/fx_string.h"
#include "core/fxcrt/unowned_ptr.h"
+class CPDF_Object;
+
// Walk on all non-null sub-objects in an object in depth, include itself,
// like in flat list.
class CPDF_ObjectWalker {
@@ -42,7 +44,7 @@ class CPDF_ObjectWalker {
size_t current_depth() const { return current_depth_; }
const CPDF_Object* GetParent() const { return parent_object_.Get(); }
- ByteString dictionary_key() const { return dict_key_; }
+ const ByteString& dictionary_key() const { return dict_key_; }
private:
static std::unique_ptr<SubobjectIterator> MakeIterator(
diff --git a/core/fpdfapi/parser/cpdf_stream.h b/core/fpdfapi/parser/cpdf_stream.h
index aada80e35c..4f1eb05478 100644
--- a/core/fpdfapi/parser/cpdf_stream.h
+++ b/core/fpdfapi/parser/cpdf_stream.h
@@ -11,7 +11,6 @@
#include <set>
#include <sstream>
-#include "core/fpdfapi/parser/cpdf_dictionary.h"
#include "core/fpdfapi/parser/cpdf_object.h"
#include "core/fxcrt/fx_stream.h"
diff --git a/core/fpdfapi/parser/cpdf_stream_acc.cpp b/core/fpdfapi/parser/cpdf_stream_acc.cpp
index 7956124c62..c87e404186 100644
--- a/core/fpdfapi/parser/cpdf_stream_acc.cpp
+++ b/core/fpdfapi/parser/cpdf_stream_acc.cpp
@@ -8,6 +8,7 @@
#include <utility>
+#include "core/fpdfapi/parser/cpdf_dictionary.h"
#include "core/fpdfapi/parser/fpdf_parser_decode.h"
CPDF_StreamAcc::CPDF_StreamAcc(const CPDF_Stream* pStream)
diff --git a/core/fpdfapi/parser/cpdf_stream_acc.h b/core/fpdfapi/parser/cpdf_stream_acc.h
index e725041e80..37e21d26d8 100644
--- a/core/fpdfapi/parser/cpdf_stream_acc.h
+++ b/core/fpdfapi/parser/cpdf_stream_acc.h
@@ -9,7 +9,6 @@
#include <memory>
-#include "core/fpdfapi/parser/cpdf_dictionary.h"
#include "core/fpdfapi/parser/cpdf_stream.h"
#include "core/fxcrt/fx_string.h"
#include "core/fxcrt/fx_system.h"
@@ -17,6 +16,8 @@
#include "core/fxcrt/retain_ptr.h"
#include "third_party/base/span.h"
+class CPDF_Dictionary;
+
class CPDF_StreamAcc final : public Retainable {
public:
template <typename T, typename... Args>
diff --git a/core/fpdfapi/parser/cpdf_stream_acc_unittest.cpp b/core/fpdfapi/parser/cpdf_stream_acc_unittest.cpp
index 1fbb342548..146bd4b77b 100644
--- a/core/fpdfapi/parser/cpdf_stream_acc_unittest.cpp
+++ b/core/fpdfapi/parser/cpdf_stream_acc_unittest.cpp
@@ -4,8 +4,8 @@
#include "core/fpdfapi/parser/cpdf_stream_acc.h"
+#include "core/fpdfapi/parser/cpdf_dictionary.h"
#include "core/fpdfapi/parser/cpdf_stream.h"
-
#include "core/fxcrt/cfx_memorystream.h"
#include "core/fxcrt/fx_stream.h"
#include "testing/gtest/include/gtest/gtest.h"