diff options
author | Tom Sepez <tsepez@chromium.org> | 2018-09-14 19:51:10 +0000 |
---|---|---|
committer | Chromium commit bot <commit-bot@chromium.org> | 2018-09-14 19:51:10 +0000 |
commit | 59d2a590a5fc061663fec0a1543b608e8af9eec9 (patch) | |
tree | 8e262b0c37cf68a6194199c14b98203e4e292afa | |
parent | 4dc8c50f81bd78711bcfb432629800b8683102b6 (diff) | |
download | pdfium-59d2a590a5fc061663fec0a1543b608e8af9eec9.tar.xz |
Rename FPDF_RenderPage_Retail() to RenderPageWithContext()chromium/3553
Removing the FPDF_ prefix also makes it more obvious that this is
not a public/ entry point. No functional changes.
Bug: pdfium:1149
Change-Id: I6d68d7951cbfc65128339e237017e7b4bc965635
Reviewed-on: https://pdfium-review.googlesource.com/42490
Reviewed-by: Lei Zhang <thestig@chromium.org>
Commit-Queue: Tom Sepez <tsepez@chromium.org>
-rw-r--r-- | fpdfsdk/cpdfsdk_helpers.h | 20 | ||||
-rw-r--r-- | fpdfsdk/fpdf_progressive.cpp | 4 | ||||
-rw-r--r-- | fpdfsdk/fpdf_view.cpp | 36 |
3 files changed, 30 insertions, 30 deletions
diff --git a/fpdfsdk/cpdfsdk_helpers.h b/fpdfsdk/cpdfsdk_helpers.h index 5de947afdf..3695bb1f5b 100644 --- a/fpdfsdk/cpdfsdk_helpers.h +++ b/fpdfsdk/cpdfsdk_helpers.h @@ -245,16 +245,16 @@ void FSDK_SetSandBoxPolicy(FPDF_DWORD policy, FPDF_BOOL enable); FPDF_BOOL FSDK_IsSandBoxPolicyEnabled(FPDF_DWORD policy); // TODO(dsinclair): Where should this live? -void FPDF_RenderPage_Retail(CPDF_PageRenderContext* pContext, - FPDF_PAGE page, - int start_x, - int start_y, - int size_x, - int size_y, - int rotate, - int flags, - bool bNeedToRestore, - IPDFSDK_PauseAdapter* pause); +void RenderPageWithContext(CPDF_PageRenderContext* pContext, + FPDF_PAGE page, + int start_x, + int start_y, + int size_x, + int size_y, + int rotate, + int flags, + bool bNeedToRestore, + IPDFSDK_PauseAdapter* pause); void ReportUnsupportedFeatures(CPDF_Document* pDoc); void CheckUnSupportAnnot(CPDF_Document* pDoc, const CPDF_Annot* pPDFAnnot); diff --git a/fpdfsdk/fpdf_progressive.cpp b/fpdfsdk/fpdf_progressive.cpp index 6d16bce700..931ee17b19 100644 --- a/fpdfsdk/fpdf_progressive.cpp +++ b/fpdfsdk/fpdf_progressive.cpp @@ -57,8 +57,8 @@ FPDF_EXPORT int FPDF_CALLCONV FPDF_RenderPageBitmap_Start(FPDF_BITMAP bitmap, pDevice->Attach(pBitmap, !!(flags & FPDF_REVERSE_BYTE_ORDER), nullptr, false); IPDFSDK_PauseAdapter IPauseAdapter(pause); - FPDF_RenderPage_Retail(pContext, page, start_x, start_y, size_x, size_y, - rotate, flags, false, &IPauseAdapter); + RenderPageWithContext(pContext, page, start_x, start_y, size_x, size_y, + rotate, flags, false, &IPauseAdapter); #ifdef _SKIA_SUPPORT_PATHS_ pDevice->Flush(false); diff --git a/fpdfsdk/fpdf_view.cpp b/fpdfsdk/fpdf_view.cpp index 0cfa362904..247a90240b 100644 --- a/fpdfsdk/fpdf_view.cpp +++ b/fpdfsdk/fpdf_view.cpp @@ -555,8 +555,8 @@ FPDF_EXPORT void FPDF_CALLCONV FPDF_RenderPage(HDC dc, pContext->m_pDevice = pdfium::MakeUnique<CFX_WindowsRenderDevice>(dc); } - FPDF_RenderPage_Retail(pContext, page, start_x, start_y, size_x, size_y, - rotate, flags, true, nullptr); + RenderPageWithContext(pContext, page, start_x, start_y, size_x, size_y, + rotate, flags, true, nullptr); if (bHasMask) { // Finish rendering the page to bitmap and copy the correct segments @@ -586,8 +586,8 @@ FPDF_EXPORT void FPDF_CALLCONV FPDF_RenderPage(HDC dc, option_flags |= RENDER_BREAKFORMASKS; pContext->m_pOptions->SetFlags(option_flags); - FPDF_RenderPage_Retail(pContext, page, start_x, start_y, size_x, size_y, - rotate, flags, true, nullptr); + RenderPageWithContext(pContext, page, start_x, start_y, size_x, size_y, + rotate, flags, true, nullptr); // Render masks for (size_t i = 0; i < mask_boxes.size(); i++) { @@ -642,8 +642,8 @@ FPDF_EXPORT void FPDF_CALLCONV FPDF_RenderPageBitmap(FPDF_BITMAP bitmap, RetainPtr<CFX_DIBitmap> pBitmap(CFXDIBitmapFromFPDFBitmap(bitmap)); pDevice->Attach(pBitmap, !!(flags & FPDF_REVERSE_BYTE_ORDER), nullptr, false); - FPDF_RenderPage_Retail(pContext, page, start_x, start_y, size_x, size_y, - rotate, flags, true, nullptr); + RenderPageWithContext(pContext, page, start_x, start_y, size_x, size_y, + rotate, flags, true, nullptr); #ifdef _SKIA_SUPPORT_PATHS_ pDevice->Flush(true); @@ -706,8 +706,8 @@ FPDF_EXPORT FPDF_RECORDER FPDF_CALLCONV FPDF_RenderPageSkp(FPDF_PAGE page, CFX_DefaultRenderDevice* skDevice = new CFX_DefaultRenderDevice; FPDF_RECORDER recorder = skDevice->CreateRecorder(size_x, size_y); pContext->m_pDevice.reset(skDevice); - FPDF_RenderPage_Retail(pContext, page, 0, 0, size_x, size_y, 0, 0, true, - nullptr); + RenderPageWithContext(pContext, page, 0, 0, size_x, size_y, 0, 0, true, + nullptr); pPage->SetRenderContext(nullptr); return recorder; } @@ -899,16 +899,16 @@ FPDF_EXPORT void FPDF_CALLCONV FPDFBitmap_Destroy(FPDF_BITMAP bitmap) { destroyer.Unleak(CFXDIBitmapFromFPDFBitmap(bitmap)); } -void FPDF_RenderPage_Retail(CPDF_PageRenderContext* pContext, - FPDF_PAGE page, - int start_x, - int start_y, - int size_x, - int size_y, - int rotate, - int flags, - bool bNeedToRestore, - IPDFSDK_PauseAdapter* pause) { +void RenderPageWithContext(CPDF_PageRenderContext* pContext, + FPDF_PAGE page, + int start_x, + int start_y, + int size_x, + int size_y, + int rotate, + int flags, + bool bNeedToRestore, + IPDFSDK_PauseAdapter* pause) { CPDF_Page* pPage = CPDFPageFromFPDFPage(page); if (!pPage) return; |