本文整理汇总了C++中CPDF_Page::GetPrivateData方法的典型用法代码示例。如果您正苦于以下问题:C++ CPDF_Page::GetPrivateData方法的具体用法?C++ CPDF_Page::GetPrivateData怎么用?C++ CPDF_Page::GetPrivateData使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CPDF_Page
的用法示例。
在下文中一共展示了CPDF_Page::GetPrivateData方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: IPauseAdapter
DLLEXPORT int STDCALL FPDF_RenderPage_Continue(FPDF_PAGE page,IFSDK_PAUSE * pause)
{
if (page == NULL)
return FPDF_RENDER_FAILED;
if (!pause)
return FPDF_RENDER_FAILED;
if (pause->version !=1)
return FPDF_RENDER_FAILED;
CPDF_Page* pPage = (CPDF_Page*)page;
// FXMT_CSLOCK_OBJ(&pPage->m_PageLock);
CRenderContext * pContext = (CRenderContext*)pPage->GetPrivateData((void*)1);
if (pContext && pContext->m_pRenderer)
{
IFSDK_PAUSE_Adapter IPauseAdapter(pause);
pContext->m_pRenderer->Continue(&IPauseAdapter);
CPDF_ProgressiveRenderer::RenderStatus status = CPDF_ProgressiveRenderer::Failed;
status = pContext->m_pRenderer->GetStatus();
return status;
}
return FPDF_RENDER_FAILED;
}
示例2: CPDFPageFromFPDFPage
DLLEXPORT void STDCALL FPDF_RenderPage_Close(FPDF_PAGE page) {
CPDF_Page* pPage = CPDFPageFromFPDFPage(page);
if (!pPage)
return;
CRenderContext* pContext = (CRenderContext*)pPage->GetPrivateData((void*)1);
if (!pContext)
return;
pContext->m_pDevice->RestoreState();
delete pContext;
pPage->RemovePrivateData((void*)1);
}
示例3:
DLLEXPORT void STDCALL FPDF_RenderPage_Close(FPDF_PAGE page)
{
if (page == NULL) return;
CPDF_Page* pPage = (CPDF_Page*)page;
// FXMT_CSLOCK_OBJ(&pPage->m_PageLock);
CRenderContext * pContext = (CRenderContext*)pPage->GetPrivateData((void*)1);
if (pContext)
{
pContext->m_pDevice->RestoreState();
delete pContext;
pPage->RemovePrivateData((void*)1);
}
}
示例4: IPauseAdapter
DLLEXPORT int STDCALL FPDF_RenderPage_Continue(FPDF_PAGE page,
IFSDK_PAUSE* pause) {
if (!pause || pause->version != 1)
return FPDF_RENDER_FAILED;
CPDF_Page* pPage = CPDFPageFromFPDFPage(page);
if (!pPage)
return FPDF_RENDER_FAILED;
CRenderContext* pContext = (CRenderContext*)pPage->GetPrivateData((void*)1);
if (pContext && pContext->m_pRenderer) {
IFSDK_PAUSE_Adapter IPauseAdapter(pause);
pContext->m_pRenderer->Continue(&IPauseAdapter);
return CPDF_ProgressiveRenderer::ToFPDFStatus(
pContext->m_pRenderer->GetStatus());
}
return FPDF_RENDER_FAILED;
}