summaryrefslogtreecommitdiff
path: root/core/fpdfapi/render/cpdf_imagecacheentry.cpp
diff options
context:
space:
mode:
authorNicolas Pena <npm@chromium.org>2017-01-05 13:22:17 -0500
committerChromium commit bot <commit-bot@chromium.org>2017-01-05 20:04:17 +0000
commit48f776f7e801d719683b251dc21ee8c0e3250d90 (patch)
tree53987e0b197419771088e4109ccc8283c705fdaf /core/fpdfapi/render/cpdf_imagecacheentry.cpp
parent91fd904b6b5cdeed0f01617992df5235f79d3fa6 (diff)
downloadpdfium-48f776f7e801d719683b251dc21ee8c0e3250d90.tar.xz
Remove unused CPDF_ImageCacheEntry::GetCachedBitmap
GetCachedBitmap method is not being used. This removal simplifies some of the code. Change-Id: I075c245c3511e8a1b595c8ba148991f7c838f504 Reviewed-on: https://pdfium-review.googlesource.com/2154 Commit-Queue: Nicolás Peña <npm@chromium.org> Reviewed-by: Tom Sepez <tsepez@chromium.org>
Diffstat (limited to 'core/fpdfapi/render/cpdf_imagecacheentry.cpp')
-rw-r--r--core/fpdfapi/render/cpdf_imagecacheentry.cpp41
1 files changed, 0 insertions, 41 deletions
diff --git a/core/fpdfapi/render/cpdf_imagecacheentry.cpp b/core/fpdfapi/render/cpdf_imagecacheentry.cpp
index 84efd925c8..f11cae888d 100644
--- a/core/fpdfapi/render/cpdf_imagecacheentry.cpp
+++ b/core/fpdfapi/render/cpdf_imagecacheentry.cpp
@@ -45,47 +45,6 @@ static uint32_t FPDF_ImageCache_EstimateImageSize(const CFX_DIBSource* pDIB) {
: 0;
}
-bool CPDF_ImageCacheEntry::GetCachedBitmap(CFX_DIBSource*& pBitmap,
- CFX_DIBSource*& pMask,
- uint32_t& MatteColor,
- CPDF_Dictionary* pPageResources,
- bool bStdCS,
- uint32_t GroupFamily,
- bool bLoadMask,
- CPDF_RenderStatus* pRenderStatus,
- int32_t downsampleWidth,
- int32_t downsampleHeight) {
- if (m_pCachedBitmap) {
- pBitmap = m_pCachedBitmap.get();
- pMask = m_pCachedMask.get();
- MatteColor = m_MatteColor;
- return true;
- }
- if (!pRenderStatus)
- return false;
-
- CPDF_RenderContext* pContext = pRenderStatus->GetContext();
- CPDF_PageRenderCache* pPageRenderCache = pContext->GetPageCache();
- m_dwTimeCount = pPageRenderCache->GetTimeCount();
- std::unique_ptr<CPDF_DIBSource> pSrc = pdfium::MakeUnique<CPDF_DIBSource>();
- CPDF_DIBSource* pMaskSrc = nullptr;
- if (!pSrc->Load(m_pDocument, m_pStream, &pMaskSrc, &MatteColor,
- pRenderStatus->m_pFormResource, pPageResources, bStdCS,
- GroupFamily, bLoadMask)) {
- pBitmap = nullptr;
- return false;
- }
- m_MatteColor = MatteColor;
- m_pCachedBitmap = std::move(pSrc);
- if (pMaskSrc)
- m_pCachedMask = pdfium::WrapUnique<CFX_DIBSource>(pMaskSrc);
-
- pBitmap = m_pCachedBitmap.get();
- pMask = m_pCachedMask.get();
- CalcSize();
- return false;
-}
-
CFX_DIBSource* CPDF_ImageCacheEntry::DetachBitmap() {
CFX_DIBSource* pDIBSource = m_pCurBitmap;
m_pCurBitmap = nullptr;