bool CXFA_FFTextEdit::AcceptsFocusOnButtonDown(uint32_t dwFlags, const CFX_PointF& point, FWL_MouseCommand command) { if (command == FWL_MouseCommand::RightButtonDown && !m_pNode->IsOpenAccess()) return false; if (!PtInActiveRect(point)) return false; return true; }
FX_BOOL CXFA_FFImageEdit::OnLButtonDown(uint32_t dwFlags, FX_FLOAT fx, FX_FLOAT fy) { if (m_pDataAcc->GetAccess() != XFA_ATTRIBUTEENUM_Open) return FALSE; if (!PtInActiveRect(fx, fy)) return FALSE; SetButtonDown(TRUE); CFWL_MsgMouse ms; ms.m_dwCmd = FWL_MouseCommand::LeftButtonDown; ms.m_dwFlags = dwFlags; ms.m_fx = fx; ms.m_fy = fy; ms.m_pDstTarget = m_pNormalWidget->m_pIface; FWLToClient(ms.m_fx, ms.m_fy); TranslateFWLMessage(&ms); return TRUE; }
bool CXFA_FFTextEdit::OnLButtonDown(uint32_t dwFlags, FX_FLOAT fx, FX_FLOAT fy) { if (!PtInActiveRect(fx, fy)) { return false; } if (!IsFocused()) { m_dwStatus |= XFA_WidgetStatus_Focused; UpdateFWLData(); AddInvalidateRect(); } SetButtonDown(true); CFWL_MsgMouse ms; ms.m_dwCmd = FWL_MouseCommand::LeftButtonDown; ms.m_dwFlags = dwFlags; ms.m_fx = fx; ms.m_fy = fy; ms.m_pDstTarget = m_pNormalWidget->GetWidget(); FWLToClient(ms.m_fx, ms.m_fy); TranslateFWLMessage(&ms); return true; }
FX_BOOL CXFA_FFTextEdit::OnLButtonDown(FX_DWORD dwFlags, FX_FLOAT fx, FX_FLOAT fy) { if (!PtInActiveRect(fx, fy)) { return FALSE; } if (!IsFocused()) { m_dwStatus |= XFA_WIDGETSTATUS_Focused; UpdateFWLData(); AddInvalidateRect(); } SetButtonDown(TRUE); CFWL_MsgMouse ms; ms.m_dwCmd = FWL_MSGMOUSECMD_LButtonDown; ms.m_dwFlags = dwFlags; ms.m_fx = fx; ms.m_fy = fy; ms.m_pDstTarget = m_pNormalWidget->m_pIface; FWLToClient(ms.m_fx, ms.m_fy); TranslateFWLMessage(&ms); return TRUE; }
bool CXFA_FFTextEdit::OnRButtonDown(uint32_t dwFlags, FX_FLOAT fx, FX_FLOAT fy) { if (m_pDataAcc->GetAccess() != XFA_ATTRIBUTEENUM_Open) { return false; } if (!PtInActiveRect(fx, fy)) { return false; } if (!IsFocused()) { m_dwStatus |= XFA_WidgetStatus_Focused; UpdateFWLData(); AddInvalidateRect(); } SetButtonDown(true); CFWL_MsgMouse ms; ms.m_dwCmd = FWL_MouseCommand::RightButtonDown; ms.m_dwFlags = dwFlags; ms.m_fx = fx; ms.m_fy = fy; FWLToClient(ms.m_fx, ms.m_fy); TranslateFWLMessage(&ms); return true; }
FX_BOOL CXFA_FFTextEdit::OnRButtonDown(FX_DWORD dwFlags, FX_FLOAT fx, FX_FLOAT fy) { if (m_pDataAcc->GetAccess() != XFA_ATTRIBUTEENUM_Open) { return FALSE; } if (!PtInActiveRect(fx, fy)) { return FALSE; } if (!IsFocused()) { m_dwStatus |= XFA_WIDGETSTATUS_Focused; UpdateFWLData(); AddInvalidateRect(); } SetButtonDown(TRUE); CFWL_MsgMouse ms; ms.m_dwCmd = FWL_MSGMOUSECMD_RButtonDown; ms.m_dwFlags = dwFlags; ms.m_fx = fx; ms.m_fy = fy; FWLToClient(ms.m_fx, ms.m_fy); TranslateFWLMessage(&ms); return TRUE; }
FX_BOOL CXFA_FFField::OnRButtonDown(uint32_t dwFlags, FX_FLOAT fx, FX_FLOAT fy) { if (!m_pNormalWidget) { return FALSE; } if (m_pDataAcc->GetAccess() != XFA_ATTRIBUTEENUM_Open || !m_pDataAcc->GetDoc()->GetXFADoc()->IsInteractive()) { return FALSE; } if (!PtInActiveRect(fx, fy)) { return FALSE; } SetButtonDown(TRUE); CFWL_MsgMouse ms; ms.m_dwCmd = FWL_MouseCommand::RightButtonDown; ms.m_dwFlags = dwFlags; ms.m_fx = fx; ms.m_fy = fy; FWLToClient(ms.m_fx, ms.m_fy); ms.m_pDstTarget = m_pNormalWidget->m_pIface; TranslateFWLMessage(&ms); return TRUE; }