diff options
Diffstat (limited to 'xfa/fxfa/cxfa_ffwidgethandler.cpp')
-rw-r--r-- | xfa/fxfa/cxfa_ffwidgethandler.cpp | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/xfa/fxfa/cxfa_ffwidgethandler.cpp b/xfa/fxfa/cxfa_ffwidgethandler.cpp index 4c21c24e2e..8988cf1903 100644 --- a/xfa/fxfa/cxfa_ffwidgethandler.cpp +++ b/xfa/fxfa/cxfa_ffwidgethandler.cpp @@ -188,8 +188,11 @@ bool CXFA_FFWidgetHandler::HasEvent(CXFA_WidgetAcc* pWidgetAcc, if (eEventType == XFA_EVENT_Unknown) return false; - if (!pWidgetAcc || pWidgetAcc->GetElementType() == XFA_Element::Draw) + if (!pWidgetAcc || + (pWidgetAcc->GetNode() && + pWidgetAcc->GetNode()->GetElementType() == XFA_Element::Draw)) { return false; + } switch (eEventType) { case XFA_EVENT_Calculate: { @@ -211,8 +214,11 @@ int32_t CXFA_FFWidgetHandler::ProcessEvent(CXFA_WidgetAcc* pWidgetAcc, CXFA_EventParam* pParam) { if (!pParam || pParam->m_eType == XFA_EVENT_Unknown) return XFA_EVENTERROR_NotExist; - if (!pWidgetAcc || pWidgetAcc->GetElementType() == XFA_Element::Draw) + if (!pWidgetAcc || + (pWidgetAcc->GetNode() && + pWidgetAcc->GetNode()->GetElementType() == XFA_Element::Draw)) { return XFA_EVENTERROR_NotExist; + } switch (pParam->m_eType) { case XFA_EVENT_Calculate: |