本文整理汇总了C++中CXFA_FFWidgetHandler类的典型用法代码示例。如果您正苦于以下问题:C++ CXFA_FFWidgetHandler类的具体用法?C++ CXFA_FFWidgetHandler怎么用?C++ CXFA_FFWidgetHandler使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了CXFA_FFWidgetHandler类的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: GetXFAWidgetHandler
bool CPDFSDK_XFAWidgetHandler::OnRButtonDown(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot::ObservedPtr* pAnnot,
uint32_t nFlags,
const CFX_FloatPoint& point) {
if (!pPageView || !(*pAnnot))
return false;
CXFA_FFWidgetHandler* pWidgetHandler = GetXFAWidgetHandler(pAnnot->Get());
return pWidgetHandler->OnRButtonDown((*pAnnot)->GetXFAWidget(),
GetFWLFlags(nFlags), point.x, point.y);
}
示例2: GetXFAWidgetHandler
bool CPDFSDK_XFAWidgetHandler::OnMouseMove(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot::ObservedPtr* pAnnot,
uint32_t nFlags,
const CFX_PointF& point) {
if (!pPageView || !(*pAnnot))
return false;
CXFA_FFWidgetHandler* pWidgetHandler = GetXFAWidgetHandler(pAnnot->Get());
return pWidgetHandler->OnMouseMove((*pAnnot)->GetXFAWidget(),
GetFWLFlags(nFlags), point);
}
示例3: GetXFAWidgetHandler
FX_BOOL CPDFSDK_XFAAnnotHandler::OnRButtonUp(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
uint32_t nFlags,
const CFX_FloatPoint& point) {
if (!pPageView || !pAnnot)
return FALSE;
CXFA_FFWidgetHandler* pWidgetHandler = GetXFAWidgetHandler(pAnnot);
return pWidgetHandler->OnRButtonUp(pAnnot->GetXFAWidget(),
GetFWLFlags(nFlags), point.x, point.y);
}
示例4: OnBeforeNotifySubmit
bool CPDFXFA_DocEnvironment::OnBeforeNotifySubmit() {
if (m_pContext->GetDocType() != DOCTYPE_DYNAMIC_XFA &&
m_pContext->GetDocType() != DOCTYPE_STATIC_XFA) {
return true;
}
if (!m_pContext->GetXFADocView())
return true;
CXFA_FFWidgetHandler* pWidgetHandler =
m_pContext->GetXFADocView()->GetWidgetHandler();
if (!pWidgetHandler)
return true;
std::unique_ptr<CXFA_WidgetAccIterator> pWidgetAccIterator(
m_pContext->GetXFADocView()->CreateWidgetAccIterator());
if (pWidgetAccIterator) {
CXFA_EventParam Param;
Param.m_eType = XFA_EVENT_PreSubmit;
while (CXFA_WidgetAcc* pWidgetAcc = pWidgetAccIterator->MoveToNext())
pWidgetHandler->ProcessEvent(pWidgetAcc, &Param);
}
pWidgetAccIterator.reset(
m_pContext->GetXFADocView()->CreateWidgetAccIterator());
if (!pWidgetAccIterator)
return true;
CXFA_WidgetAcc* pWidgetAcc = pWidgetAccIterator->MoveToNext();
pWidgetAcc = pWidgetAccIterator->MoveToNext();
while (pWidgetAcc) {
int fRet = pWidgetAcc->ProcessValidate(-1);
if (fRet == XFA_EVENTERROR_Error) {
CPDFSDK_FormFillEnvironment* pFormFillEnv = m_pContext->GetFormFillEnv();
if (!pFormFillEnv)
return false;
CFX_WideString ws;
ws.FromLocal(IDS_XFA_Validate_Input);
CFX_ByteString bs = ws.UTF16LE_Encode();
int len = bs.GetLength();
pFormFillEnv->Alert((FPDF_WIDESTRING)bs.GetBuffer(len),
(FPDF_WIDESTRING)L"", 0, 1);
bs.ReleaseBuffer(len);
return false;
}
pWidgetAcc = pWidgetAccIterator->MoveToNext();
}
m_pContext->GetXFADocView()->UpdateDocView();
return true;
}