void CScript_HostPseudoModel::Script_HostPseudoModel_GetFocus( CFXJSE_Arguments* pArguments) { IXFA_Notify* pNotify = m_pDocument->GetParser()->GetNotify(); if (!pNotify) { return; } CXFA_Node* pNode = pNotify->GetFocusWidgetNode(); if (!pNode) { return; } FXJSE_Value_Set(pArguments->GetReturnValue(), m_pDocument->GetScriptContext()->GetJSValueFromMap(pNode)); }
void CScript_SignaturePseudoModel::Script_SignaturePseudoModel_Enumerate( CFXJSE_Arguments* pArguments) { int32_t iLength = pArguments->GetLength(); if (iLength != 0) { ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"enumerate"); return; } IXFA_Notify* pNotify = m_pDocument->GetParser()->GetNotify(); if (!pNotify) { return; } IXFA_Doc* hDoc = pNotify->GetHDOC(); CXFA_NodeList* pList = pNotify->GetDocProvider()->Enumerate(hDoc); if (!pList) return; FXJSE_Value_Set(pArguments->GetReturnValue(), m_pDocument->GetScriptContext()->GetJSValueFromMap(pList)); }