summaryrefslogtreecommitdiff
path: root/fpdfsdk/fpdfsave.cpp
diff options
context:
space:
mode:
authorDan Sinclair <dsinclair@chromium.org>2017-09-21 15:49:49 -0400
committerChromium commit bot <commit-bot@chromium.org>2017-09-21 20:17:31 +0000
commit0b95042db2e6dab5876abd12ce485fff0a8e08fe (patch)
tree02132ed53945fde30bfbf230ff4e9b5308dd7732 /fpdfsdk/fpdfsave.cpp
parenta5eb9f05b7c3f82630784e043ccf75c4e019b18f (diff)
downloadpdfium-0b95042db2e6dab5876abd12ce485fff0a8e08fe.tar.xz
Rename CFX_RetainPtr to RetainPtr
This CL renames CFX_RetainPtr to RetainPtr and places in the fxcrt namespace. Bug: pdfium:898 Change-Id: I8798a9f79cb0840d3f037e8d04937cedd742914e Reviewed-on: https://pdfium-review.googlesource.com/14616 Reviewed-by: Tom Sepez <tsepez@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
Diffstat (limited to 'fpdfsdk/fpdfsave.cpp')
-rw-r--r--fpdfsdk/fpdfsave.cpp18
1 files changed, 8 insertions, 10 deletions
diff --git a/fpdfsdk/fpdfsave.cpp b/fpdfsdk/fpdfsave.cpp
index 455b5ba9ba..9f1e684d72 100644
--- a/fpdfsdk/fpdfsave.cpp
+++ b/fpdfsdk/fpdfsave.cpp
@@ -43,9 +43,8 @@
namespace {
#ifdef PDF_ENABLE_XFA
-bool SaveXFADocumentData(
- CPDFXFA_Context* pContext,
- std::vector<CFX_RetainPtr<IFX_SeekableStream>>* fileList) {
+bool SaveXFADocumentData(CPDFXFA_Context* pContext,
+ std::vector<RetainPtr<IFX_SeekableStream>>* fileList) {
if (!pContext)
return false;
@@ -102,7 +101,7 @@ bool SaveXFADocumentData(
CPDF_Stream* pTemplateStream = pArray->GetStreamAt(iTemplate);
auto pAcc = pdfium::MakeRetain<CPDF_StreamAcc>(pTemplateStream);
pAcc->LoadAllData();
- CFX_RetainPtr<IFX_SeekableStream> pTemplate =
+ RetainPtr<IFX_SeekableStream> pTemplate =
pdfium::MakeRetain<CFX_MemoryStream>(
const_cast<uint8_t*>(pAcc->GetData()), pAcc->GetSize(), false);
pChecksum->UpdateChecksum(pTemplate);
@@ -137,7 +136,7 @@ bool SaveXFADocumentData(
}
// L"datasets"
{
- CFX_RetainPtr<IFX_SeekableStream> pDsfileWrite =
+ RetainPtr<IFX_SeekableStream> pDsfileWrite =
pdfium::MakeRetain<CFX_MemoryStream>(false);
if (pXFADocView->GetDoc()->SavePackage(XFA_HASHCODE_Datasets, pDsfileWrite,
nullptr) &&
@@ -165,7 +164,7 @@ bool SaveXFADocumentData(
}
// L"form"
{
- CFX_RetainPtr<IFX_SeekableStream> pfileWrite =
+ RetainPtr<IFX_SeekableStream> pfileWrite =
pdfium::MakeRetain<CFX_MemoryStream>(false);
if (pXFADocView->GetDoc()->SavePackage(XFA_HASHCODE_Form, pfileWrite,
pChecksum.get()) &&
@@ -214,9 +213,8 @@ bool SendPostSaveToXFADoc(CPDFXFA_Context* pContext) {
return true;
}
-bool SendPreSaveToXFADoc(
- CPDFXFA_Context* pContext,
- std::vector<CFX_RetainPtr<IFX_SeekableStream>>* fileList) {
+bool SendPreSaveToXFADoc(CPDFXFA_Context* pContext,
+ std::vector<RetainPtr<IFX_SeekableStream>>* fileList) {
if (pContext->GetDocType() != XFA_DocType::Dynamic &&
pContext->GetDocType() != XFA_DocType::Static)
return true;
@@ -249,7 +247,7 @@ bool FPDF_Doc_Save(FPDF_DOCUMENT document,
#ifdef PDF_ENABLE_XFA
CPDFXFA_Context* pContext = static_cast<CPDFXFA_Context*>(document);
- std::vector<CFX_RetainPtr<IFX_SeekableStream>> fileList;
+ std::vector<RetainPtr<IFX_SeekableStream>> fileList;
SendPreSaveToXFADoc(pContext, &fileList);
#endif // PDF_ENABLE_XFA