diff options
Diffstat (limited to 'core/fpdfapi/render')
-rw-r--r-- | core/fpdfapi/render/cpdf_imagerenderer.cpp | 5 | ||||
-rw-r--r-- | core/fpdfapi/render/cpdf_pagerendercache.cpp | 6 | ||||
-rw-r--r-- | core/fpdfapi/render/cpdf_rendercontext.cpp | 4 | ||||
-rw-r--r-- | core/fpdfapi/render/cpdf_renderstatus.cpp | 5 |
4 files changed, 11 insertions, 9 deletions
diff --git a/core/fpdfapi/render/cpdf_imagerenderer.cpp b/core/fpdfapi/render/cpdf_imagerenderer.cpp index 22eb32b4e9..70371d847b 100644 --- a/core/fpdfapi/render/cpdf_imagerenderer.cpp +++ b/core/fpdfapi/render/cpdf_imagerenderer.cpp @@ -138,11 +138,12 @@ bool CPDF_ImageRenderer::StartRenderDIBSource() { CPDF_Page* pPage = nullptr; if (auto* pPageCache = m_pRenderStatus->m_pContext->GetPageCache()) { pPage = pPageCache->GetPage(); - pDocument = pPage->m_pDocument; + pDocument = pPage->m_pDocument.Get(); } else { pDocument = m_pImageObject->GetImage()->GetDocument(); } - CPDF_Dictionary* pPageResources = pPage ? pPage->m_pPageResources : nullptr; + CPDF_Dictionary* pPageResources = + pPage ? pPage->m_pPageResources.Get() : nullptr; CPDF_Object* pCSObj = m_pImageObject->GetImage()->GetStream()->GetDict()->GetDirectObjectFor( "ColorSpace"); diff --git a/core/fpdfapi/render/cpdf_pagerendercache.cpp b/core/fpdfapi/render/cpdf_pagerendercache.cpp index fa23355154..cc1f267f14 100644 --- a/core/fpdfapi/render/cpdf_pagerendercache.cpp +++ b/core/fpdfapi/render/cpdf_pagerendercache.cpp @@ -88,10 +88,10 @@ bool CPDF_PageRenderCache::StartGetCachedBitmap( m_pCurImageCacheEntry = it->second; } else { m_pCurImageCacheEntry = - new CPDF_ImageCacheEntry(m_pPage->m_pDocument, pStream); + new CPDF_ImageCacheEntry(m_pPage->m_pDocument.Get(), pStream); } int ret = m_pCurImageCacheEntry->StartGetCachedBitmap( - pRenderStatus->m_pFormResource, m_pPage->m_pPageResources, bStdCS, + pRenderStatus->m_pFormResource, m_pPage->m_pPageResources.Get(), bStdCS, GroupFamily, bLoadMask, pRenderStatus); if (ret == 2) return true; @@ -129,7 +129,7 @@ void CPDF_PageRenderCache::ResetBitmap( if (!pBitmap) return; - pEntry = new CPDF_ImageCacheEntry(m_pPage->m_pDocument, pStream); + pEntry = new CPDF_ImageCacheEntry(m_pPage->m_pDocument.Get(), pStream); m_ImageCache[pStream] = pEntry; } else { pEntry = it->second; diff --git a/core/fpdfapi/render/cpdf_rendercontext.cpp b/core/fpdfapi/render/cpdf_rendercontext.cpp index c8626af9ff..2cd59cac18 100644 --- a/core/fpdfapi/render/cpdf_rendercontext.cpp +++ b/core/fpdfapi/render/cpdf_rendercontext.cpp @@ -20,8 +20,8 @@ #include "core/fxge/fx_dib.h" CPDF_RenderContext::CPDF_RenderContext(CPDF_Page* pPage) - : m_pDocument(pPage->m_pDocument), - m_pPageResources(pPage->m_pPageResources), + : m_pDocument(pPage->m_pDocument.Get()), + m_pPageResources(pPage->m_pPageResources.Get()), m_pPageCache(pPage->GetRenderCache()) {} CPDF_RenderContext::CPDF_RenderContext(CPDF_Document* pDoc, diff --git a/core/fpdfapi/render/cpdf_renderstatus.cpp b/core/fpdfapi/render/cpdf_renderstatus.cpp index d485d1dede..e6b01eff3b 100644 --- a/core/fpdfapi/render/cpdf_renderstatus.cpp +++ b/core/fpdfapi/render/cpdf_renderstatus.cpp @@ -1487,11 +1487,12 @@ bool CPDF_RenderStatus::ProcessTransparency(CPDF_PageObject* pPageObj, CPDF_Page* pPage = nullptr; if (m_pContext->GetPageCache()) { pPage = m_pContext->GetPageCache()->GetPage(); - pDocument = pPage->m_pDocument; + pDocument = pPage->m_pDocument.Get(); } else { pDocument = pPageObj->AsImage()->GetImage()->GetDocument(); } - CPDF_Dictionary* pPageResources = pPage ? pPage->m_pPageResources : nullptr; + CPDF_Dictionary* pPageResources = + pPage ? pPage->m_pPageResources.Get() : nullptr; CPDF_Object* pCSObj = pPageObj->AsImage() ->GetImage() ->GetStream() |