diff options
Diffstat (limited to 'fpdfsdk')
-rw-r--r-- | fpdfsdk/fpdf_progressive.cpp | 2 | ||||
-rw-r--r-- | fpdfsdk/fpdfdoc_unittest.cpp | 2 | ||||
-rw-r--r-- | fpdfsdk/fpdfview.cpp | 6 | ||||
-rw-r--r-- | fpdfsdk/pdfwindow/PWL_FontMap.cpp | 3 |
4 files changed, 6 insertions, 7 deletions
diff --git a/fpdfsdk/fpdf_progressive.cpp b/fpdfsdk/fpdf_progressive.cpp index 1933c88485..13349cd762 100644 --- a/fpdfsdk/fpdf_progressive.cpp +++ b/fpdfsdk/fpdf_progressive.cpp @@ -91,5 +91,5 @@ DLLEXPORT void STDCALL FPDF_RenderPage_Close(FPDF_PAGE page) { return; pContext->m_pDevice->RestoreState(false); - pPage->SetRenderContext(std::unique_ptr<CPDF_PageRenderContext>()); + pPage->SetRenderContext(nullptr); } diff --git a/fpdfsdk/fpdfdoc_unittest.cpp b/fpdfsdk/fpdfdoc_unittest.cpp index fc85404dba..48be72399c 100644 --- a/fpdfsdk/fpdfdoc_unittest.cpp +++ b/fpdfsdk/fpdfdoc_unittest.cpp @@ -25,7 +25,7 @@ class CPDF_TestDocument : public CPDF_Document { public: - CPDF_TestDocument() : CPDF_Document(std::unique_ptr<CPDF_Parser>()) {} + CPDF_TestDocument() : CPDF_Document(nullptr) {} void SetRoot(CPDF_Dictionary* root) { m_pRootDict = root; } CPDF_IndirectObjectHolder* GetHolder() { return this; } diff --git a/fpdfsdk/fpdfview.cpp b/fpdfsdk/fpdfview.cpp index 92ca34effa..be56c531d2 100644 --- a/fpdfsdk/fpdfview.cpp +++ b/fpdfsdk/fpdfview.cpp @@ -575,7 +575,7 @@ DLLEXPORT void STDCALL FPDF_RenderPage(HDC dc, } } - pPage->SetRenderContext(std::unique_ptr<CPDF_PageRenderContext>()); + pPage->SetRenderContext(nullptr); } #endif // defined(_WIN32) @@ -604,7 +604,7 @@ DLLEXPORT void STDCALL FPDF_RenderPageBitmap(FPDF_BITMAP bitmap, FPDF_RenderPage_Retail(pContext, page, start_x, start_y, size_x, size_y, rotate, flags, TRUE, nullptr); - pPage->SetRenderContext(std::unique_ptr<CPDF_PageRenderContext>()); + pPage->SetRenderContext(nullptr); } #ifdef _SKIA_SUPPORT_ @@ -622,7 +622,7 @@ DLLEXPORT FPDF_RECORDER STDCALL FPDF_RenderPageSkp(FPDF_PAGE page, pContext->m_pDevice.reset(skDevice); FPDF_RenderPage_Retail(pContext, page, 0, 0, size_x, size_y, 0, 0, TRUE, nullptr); - pPage->SetRenderContext(std::unique_ptr<CPDF_PageRenderContext>()); + pPage->SetRenderContext(nullptr); return recorder; } #endif diff --git a/fpdfsdk/pdfwindow/PWL_FontMap.cpp b/fpdfsdk/pdfwindow/PWL_FontMap.cpp index a6f79e283c..b2a1f2580d 100644 --- a/fpdfsdk/pdfwindow/PWL_FontMap.cpp +++ b/fpdfsdk/pdfwindow/PWL_FontMap.cpp @@ -48,8 +48,7 @@ CPWL_FontMap::~CPWL_FontMap() { CPDF_Document* CPWL_FontMap::GetDocument() { if (!m_pPDFDoc) { if (CPDF_ModuleMgr::Get()) { - m_pPDFDoc = - pdfium::MakeUnique<CPDF_Document>(std::unique_ptr<CPDF_Parser>()); + m_pPDFDoc = pdfium::MakeUnique<CPDF_Document>(nullptr); m_pPDFDoc->CreateNewDoc(); } } |