summaryrefslogtreecommitdiff
path: root/core/fpdfapi/parser
diff options
context:
space:
mode:
Diffstat (limited to 'core/fpdfapi/parser')
-rw-r--r--core/fpdfapi/parser/cpdf_document.cpp3
-rw-r--r--core/fpdfapi/parser/cpdf_document.h4
2 files changed, 4 insertions, 3 deletions
diff --git a/core/fpdfapi/parser/cpdf_document.cpp b/core/fpdfapi/parser/cpdf_document.cpp
index dec0f5097e..fb2c723ce4 100644
--- a/core/fpdfapi/parser/cpdf_document.cpp
+++ b/core/fpdfapi/parser/cpdf_document.cpp
@@ -649,7 +649,8 @@ CPDF_IccProfile* CPDF_Document::LoadIccProfile(CPDF_Stream* pStream) {
return m_pDocPage->GetIccProfile(pStream);
}
-CPDF_Image* CPDF_Document::LoadImageFromPageData(uint32_t dwStreamObjNum) {
+CFX_RetainPtr<CPDF_Image> CPDF_Document::LoadImageFromPageData(
+ uint32_t dwStreamObjNum) {
ASSERT(dwStreamObjNum);
return m_pDocPage->GetImage(dwStreamObjNum);
}
diff --git a/core/fpdfapi/parser/cpdf_document.h b/core/fpdfapi/parser/cpdf_document.h
index 3524231c48..6f09e2230c 100644
--- a/core/fpdfapi/parser/cpdf_document.h
+++ b/core/fpdfapi/parser/cpdf_document.h
@@ -13,6 +13,7 @@
#include <utility>
#include <vector>
+#include "core/fpdfapi/page/cpdf_image.h"
#include "core/fpdfapi/parser/cpdf_indirect_object_holder.h"
#include "core/fpdfapi/parser/cpdf_object.h"
#include "core/fpdfdoc/cpdf_linklist.h"
@@ -26,7 +27,6 @@ class CPDF_DocRenderData;
class CPDF_Font;
class CPDF_FontEncoding;
class CPDF_IccProfile;
-class CPDF_Image;
class CPDF_LinearizedHeader;
class CPDF_Parser;
class CPDF_Pattern;
@@ -78,7 +78,7 @@ class CPDF_Document : public CPDF_IndirectObjectHolder {
bool bShading,
const CFX_Matrix& matrix);
- CPDF_Image* LoadImageFromPageData(uint32_t dwStreamObjNum);
+ CFX_RetainPtr<CPDF_Image> LoadImageFromPageData(uint32_t dwStreamObjNum);
CPDF_StreamAcc* LoadFontFile(CPDF_Stream* pStream);
CPDF_IccProfile* LoadIccProfile(CPDF_Stream* pStream);