本文整理汇总了C++中CPDFSDK_PageView::GetFocusAnnot方法的典型用法代码示例。如果您正苦于以下问题:C++ CPDFSDK_PageView::GetFocusAnnot方法的具体用法?C++ CPDFSDK_PageView::GetFocusAnnot怎么用?C++ CPDFSDK_PageView::GetFocusAnnot使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CPDFSDK_PageView
的用法示例。
在下文中一共展示了CPDFSDK_PageView::GetFocusAnnot方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: Annot_OnKeyDown
bool CPDFSDK_AnnotHandlerMgr::Annot_OnKeyDown(CPDFSDK_Annot* pAnnot,
int nKeyCode,
int nFlag) {
if (CPDFSDK_FormFillEnvironment::IsCTRLKeyDown(nFlag) ||
CPDFSDK_FormFillEnvironment::IsALTKeyDown(nFlag)) {
return GetAnnotHandler(pAnnot)->OnKeyDown(pAnnot, nKeyCode, nFlag);
}
CPDFSDK_PageView* pPage = pAnnot->GetPageView();
CPDFSDK_Annot* pFocusAnnot = pPage->GetFocusAnnot();
if (pFocusAnnot && (nKeyCode == FWL_VKEY_Tab)) {
CPDFSDK_Annot::ObservedPtr pNext(GetNextAnnot(
pFocusAnnot, !CPDFSDK_FormFillEnvironment::IsSHIFTKeyDown(nFlag)));
if (pNext && pNext.Get() != pFocusAnnot) {
pPage->GetFormFillEnv()->SetFocusAnnot(&pNext);
return true;
}
}
return GetAnnotHandler(pAnnot)->OnKeyDown(pAnnot, nKeyCode, nFlag);
}
示例2: Annot_OnKeyDown
FX_BOOL CPDFSDK_AnnotHandlerMgr::Annot_OnKeyDown(CPDFSDK_Annot* pAnnot,
int nKeyCode,
int nFlag) {
if (!m_pApp->FFI_IsCTRLKeyDown(nFlag) && !m_pApp->FFI_IsALTKeyDown(nFlag)) {
CPDFSDK_PageView* pPage = pAnnot->GetPageView();
CPDFSDK_Annot* pFocusAnnot = pPage->GetFocusAnnot();
if (pFocusAnnot && (nKeyCode == FWL_VKEY_Tab)) {
CPDFSDK_Annot* pNext =
GetNextAnnot(pFocusAnnot, !m_pApp->FFI_IsSHIFTKeyDown(nFlag));
if (pNext && pNext != pFocusAnnot) {
CPDFSDK_Document* pDocument = pPage->GetSDKDocument();
pDocument->SetFocusAnnot(pNext);
return TRUE;
}
}
}
if (IPDFSDK_AnnotHandler* pAnnotHandler = GetAnnotHandler(pAnnot)) {
return pAnnotHandler->OnKeyDown(pAnnot, nKeyCode, nFlag);
}
return FALSE;
}