summaryrefslogtreecommitdiff
path: root/fpdfsdk/fpdfxfa
diff options
context:
space:
mode:
Diffstat (limited to 'fpdfsdk/fpdfxfa')
-rw-r--r--fpdfsdk/fpdfxfa/fpdfxfa_app.cpp3
-rw-r--r--fpdfsdk/fpdfxfa/fpdfxfa_page.cpp5
2 files changed, 5 insertions, 3 deletions
diff --git a/fpdfsdk/fpdfxfa/fpdfxfa_app.cpp b/fpdfsdk/fpdfxfa/fpdfxfa_app.cpp
index 88c31ef006..4edfcf0676 100644
--- a/fpdfsdk/fpdfxfa/fpdfxfa_app.cpp
+++ b/fpdfsdk/fpdfxfa/fpdfxfa_app.cpp
@@ -11,6 +11,7 @@
#include "fpdfsdk/cpdfsdk_environment.h"
#include "fpdfsdk/fpdfxfa/fpdfxfa_util.h"
#include "fpdfsdk/fsdk_define.h"
+#include "third_party/base/ptr_util.h"
#include "xfa/fxbarcode/BC_Library.h"
#include "xfa/fxfa/xfa_ffapp.h"
#include "xfa/fxfa/xfa_fontmgr.h"
@@ -56,7 +57,7 @@ FX_BOOL CPDFXFA_App::Initialize(v8::Isolate* pIsolate) {
if (!m_pIsolate)
return FALSE;
- m_pXFAApp = WrapUnique(new CXFA_FFApp(this));
+ m_pXFAApp = pdfium::MakeUnique<CXFA_FFApp>(this);
m_pXFAApp->SetDefaultFontMgr(
std::unique_ptr<CXFA_DefFontMgr>(new CXFA_DefFontMgr));
diff --git a/fpdfsdk/fpdfxfa/fpdfxfa_page.cpp b/fpdfsdk/fpdfxfa/fpdfxfa_page.cpp
index fdbd2d08e4..b3bc20bad8 100644
--- a/fpdfsdk/fpdfxfa/fpdfxfa_page.cpp
+++ b/fpdfsdk/fpdfxfa/fpdfxfa_page.cpp
@@ -12,6 +12,7 @@
#include "fpdfsdk/fpdfxfa/fpdfxfa_util.h"
#include "fpdfsdk/fsdk_define.h"
#include "public/fpdf_formfill.h"
+#include "third_party/base/ptr_util.h"
#include "xfa/fxfa/xfa_ffdocview.h"
#include "xfa/fxfa/xfa_ffpageview.h"
@@ -39,7 +40,7 @@ FX_BOOL CPDFXFA_Page::LoadPDFPage() {
return FALSE;
if (!m_pPDFPage || m_pPDFPage->m_pFormDict != pDict) {
- m_pPDFPage = WrapUnique(new CPDF_Page(pPDFDoc, pDict, true));
+ m_pPDFPage = pdfium::MakeUnique<CPDF_Page>(pPDFDoc, pDict, true);
m_pPDFPage->ParseContent();
}
return TRUE;
@@ -88,7 +89,7 @@ FX_BOOL CPDFXFA_Page::LoadPDFPage(CPDF_Dictionary* pageDict) {
return FALSE;
m_pPDFPage =
- WrapUnique(new CPDF_Page(m_pDocument->GetPDFDoc(), pageDict, true));
+ pdfium::MakeUnique<CPDF_Page>(m_pDocument->GetPDFDoc(), pageDict, true);
m_pPDFPage->ParseContent();
return TRUE;
}