From bfa9a824a20f37c2dd7111012b46c929cf2ed8a0 Mon Sep 17 00:00:00 2001 From: Tom Sepez Date: Tue, 9 Jun 2015 13:24:12 -0700 Subject: Merge to XFA: Use stdint.h types throughout PDFium. Near-automatic merge, plus re-running scripts to update additional usage. R=thestig@chromium.org Review URL: https://codereview.chromium.org/1172793002 --- xfa/src/fwl/src/basewidget/fwl_barcodeimp.cpp | 8 +- xfa/src/fwl/src/basewidget/fwl_caretimp.cpp | 4 +- xfa/src/fwl/src/basewidget/fwl_checkboximp.cpp | 26 +-- xfa/src/fwl/src/basewidget/fwl_comboboximp.cpp | 88 ++++----- .../fwl/src/basewidget/fwl_datetimepickerimp.cpp | 52 +++--- xfa/src/fwl/src/basewidget/fwl_editimp.cpp | 204 ++++++++++----------- xfa/src/fwl/src/basewidget/fwl_formproxyimp.cpp | 2 +- xfa/src/fwl/src/basewidget/fwl_listboximp.cpp | 100 +++++----- .../fwl/src/basewidget/fwl_monthcalendarimp.cpp | 112 +++++------ xfa/src/fwl/src/basewidget/fwl_pushbuttonimp.cpp | 6 +- xfa/src/fwl/src/basewidget/fwl_scrollbarimp.cpp | 22 +-- xfa/src/fwl/src/basewidget/fwl_spinbuttonimp.cpp | 6 +- xfa/src/fwl/src/basewidget/fwl_tooltipctrlimp.cpp | 10 +- xfa/src/fwl/src/basewidget/fxmath_barcodeimp.cpp | 40 ++-- xfa/src/fwl/src/basewidget/include/fwl_caretimp.h | 4 +- .../fwl/src/basewidget/include/fwl_checkboximp.h | 8 +- .../fwl/src/basewidget/include/fwl_comboboximp.h | 50 ++--- .../src/basewidget/include/fwl_datetimepickerimp.h | 42 ++--- xfa/src/fwl/src/basewidget/include/fwl_editimp.h | 64 +++---- .../fwl/src/basewidget/include/fwl_formproxyimp.h | 2 +- .../fwl/src/basewidget/include/fwl_listboximp.h | 12 +- .../src/basewidget/include/fwl_monthcalendarimp.h | 68 +++---- .../fwl/src/basewidget/include/fwl_pushbuttonimp.h | 4 +- .../fwl/src/basewidget/include/fwl_scrollbarimp.h | 26 +-- .../fwl/src/basewidget/include/fwl_spinbuttonimp.h | 6 +- .../src/basewidget/include/fwl_tooltipctrlimp.h | 6 +- .../fwl/src/basewidget/include/fxmath_barcodeimp.h | 30 +-- xfa/src/fwl/src/core/fwl_appimp.cpp | 2 +- xfa/src/fwl/src/core/fwl_contentimp.cpp | 4 +- xfa/src/fwl/src/core/fwl_formimp.cpp | 12 +- xfa/src/fwl/src/core/fwl_gridimp.cpp | 166 ++++++++--------- xfa/src/fwl/src/core/fwl_noteimp.cpp | 70 +++---- xfa/src/fwl/src/core/fwl_sdadapterimp.cpp | 10 +- xfa/src/fwl/src/core/fwl_threadimp.cpp | 12 +- xfa/src/fwl/src/core/fwl_timerimp.cpp | 2 +- xfa/src/fwl/src/core/fwl_widgetimp.cpp | 18 +- xfa/src/fwl/src/core/fwl_widgetmgrimp.cpp | 38 ++-- xfa/src/fwl/src/core/include/fwl_appimp.h | 2 +- xfa/src/fwl/src/core/include/fwl_contentimp.h | 2 +- xfa/src/fwl/src/core/include/fwl_formimp.h | 14 +- xfa/src/fwl/src/core/include/fwl_gridimp.h | 34 ++-- xfa/src/fwl/src/core/include/fwl_noteimp.h | 18 +- xfa/src/fwl/src/core/include/fwl_threadimp.h | 2 +- xfa/src/fwl/src/core/include/fwl_widgetimp.h | 14 +- xfa/src/fwl/src/core/include/fwl_widgetmgrimp.h | 20 +- xfa/src/fwl/src/lightwidget/app.cpp | 2 +- xfa/src/fwl/src/lightwidget/checkbox.cpp | 4 +- xfa/src/fwl/src/lightwidget/combobox.cpp | 48 ++--- xfa/src/fwl/src/lightwidget/datetimepicker.cpp | 14 +- xfa/src/fwl/src/lightwidget/edit.cpp | 32 ++-- xfa/src/fwl/src/lightwidget/listbox.cpp | 42 ++--- xfa/src/fwl/src/lightwidget/picturebox.cpp | 12 +- xfa/src/fwl/src/lightwidget/theme.cpp | 24 +-- xfa/src/fwl/src/lightwidget/tooltipctrl.cpp | 12 +- xfa/src/fwl/src/lightwidget/widget.cpp | 4 +- xfa/src/fwl/src/theme/checkboxtp.cpp | 10 +- xfa/src/fwl/src/theme/formtp.cpp | 22 +-- xfa/src/fwl/src/theme/pushbuttontp.cpp | 4 +- xfa/src/fwl/src/theme/widgettp.cpp | 24 +-- 59 files changed, 848 insertions(+), 848 deletions(-) (limited to 'xfa/src/fwl') diff --git a/xfa/src/fwl/src/basewidget/fwl_barcodeimp.cpp b/xfa/src/fwl/src/basewidget/fwl_barcodeimp.cpp index 8ac141a686..cc7ffd9f54 100644 --- a/xfa/src/fwl/src/basewidget/fwl_barcodeimp.cpp +++ b/xfa/src/fwl/src/basewidget/fwl_barcodeimp.cpp @@ -113,7 +113,7 @@ FWL_ERR CFWL_BarcodeImp::DrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *p if (pMatrix) { mt.Concat(*pMatrix); } - FX_INT32 errorCode = 0; + int32_t errorCode = 0; _FWL_RETURN_VALUE_IF_FAIL(m_pBarcodeEngine->RenderDevice(pGraphics->GetRenderDevice(), pMatrix, errorCode), FWL_ERR_Indefinite); return FWL_ERR_Succeeded; } @@ -147,8 +147,8 @@ void CFWL_BarcodeImp::GenerateBarcodeImageCache() if(pFontColor) { m_pBarcodeEngine->SetFontColor(*pFontColor); } - m_pBarcodeEngine->SetHeight(FX_INT32(m_rtClient.height)); - m_pBarcodeEngine->SetWidth(FX_INT32(m_rtClient.width)); + m_pBarcodeEngine->SetHeight(int32_t(m_rtClient.height)); + m_pBarcodeEngine->SetWidth(int32_t(m_rtClient.width)); FX_DWORD dwAttributeMask = pData->GetBarcodeAttributeMask(); if (dwAttributeMask & FWL_BCDATTRIBUTE_CHARENCODING) { m_pBarcodeEngine->SetCharEncoding (pData->GetCharEncoding()); @@ -189,7 +189,7 @@ void CFWL_BarcodeImp::GenerateBarcodeImageCache() if (dwAttributeMask & FWL_BCDATTRIBUTE_TRUNCATED) { m_pBarcodeEngine->SetTruncated (pData->GetTruncated()); } - FX_INT32 errorCode = 0; + int32_t errorCode = 0; m_dwStatus = m_pBarcodeEngine->Encode(wsText, TRUE, errorCode) ? XFA_BCS_EncodeSuccess : 0; } void CFWL_BarcodeImp::CreateBarcodeEngine() diff --git a/xfa/src/fwl/src/basewidget/fwl_caretimp.cpp b/xfa/src/fwl/src/basewidget/fwl_caretimp.cpp index f8c7d09eb2..b0307e883f 100644 --- a/xfa/src/fwl/src/basewidget/fwl_caretimp.cpp +++ b/xfa/src/fwl/src/basewidget/fwl_caretimp.cpp @@ -165,7 +165,7 @@ CFWL_CaretImp::CFWL_CaretTimer::CFWL_CaretTimer(CFWL_CaretImp *m_pCaret) { this->m_pCaret = m_pCaret; } -FX_INT32 CFWL_CaretImp::CFWL_CaretTimer::Run(FWL_HTIMER hTimer) +int32_t CFWL_CaretImp::CFWL_CaretTimer::Run(FWL_HTIMER hTimer) { if (m_pCaret->GetStates() & FWL_STATE_CAT_HightLight) { m_pCaret->SetStates(FWL_STATE_CAT_HightLight, FALSE); @@ -182,7 +182,7 @@ CFWL_CaretImpDelegate::CFWL_CaretImpDelegate(CFWL_CaretImp *pOwner) : m_pOwner(pOwner) { } -FX_INT32 CFWL_CaretImpDelegate::OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_CaretImpDelegate::OnProcessMessage(CFWL_Message *pMessage) { return 1; } diff --git a/xfa/src/fwl/src/basewidget/fwl_checkboximp.cpp b/xfa/src/fwl/src/basewidget/fwl_checkboximp.cpp index 89311b39f2..1ba0851bb6 100644 --- a/xfa/src/fwl/src/basewidget/fwl_checkboximp.cpp +++ b/xfa/src/fwl/src/basewidget/fwl_checkboximp.cpp @@ -38,11 +38,11 @@ FWL_ERR IFWL_CheckBox::Initialize(const CFWL_WidgetImpProperties &properties, IF ((CFWL_CheckBoxImp*)m_pData)->SetInterface(this); return ((CFWL_CheckBoxImp*)m_pData)->Initialize(); } -FX_INT32 IFWL_CheckBox::GetCheckState() +int32_t IFWL_CheckBox::GetCheckState() { return ((CFWL_CheckBoxImp*)m_pData)->GetCheckState(); } -FWL_ERR IFWL_CheckBox::SetCheckState(FX_INT32 iCheck) +FWL_ERR IFWL_CheckBox::SetCheckState(int32_t iCheck) { return ((CFWL_CheckBoxImp*)m_pData)->SetCheckState(iCheck); } @@ -174,7 +174,7 @@ FWL_ERR CFWL_CheckBoxImp::DrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix * if (HasEdge()) { DrawEdge(pGraphics, FWL_PART_CKB_Edge, pTheme, pMatrix); } - FX_INT32 dwStates = GetPartStates(); + int32_t dwStates = GetPartStates(); { CFWL_ThemeBackground param; param.m_pWidget = m_pInterface; @@ -197,7 +197,7 @@ FWL_ERR CFWL_CheckBoxImp::DrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix * { CFX_WideString wsCaption; m_pProperties->m_pDataProvider->GetCaption(m_pInterface, wsCaption); - FX_INT32 iLen = wsCaption.GetLength(); + int32_t iLen = wsCaption.GetLength(); _FWL_RETURN_VALUE_IF_FAIL(iLen > 0, FWL_ERR_Indefinite); CFWL_ThemeText textParam; textParam.m_pWidget = m_pInterface; @@ -215,7 +215,7 @@ FWL_ERR CFWL_CheckBoxImp::DrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix * } return FWL_ERR_Succeeded; } -FX_INT32 CFWL_CheckBoxImp::GetCheckState() +int32_t CFWL_CheckBoxImp::GetCheckState() { if ((m_pProperties->m_dwStyleExes & FWL_STYLEEXT_CKB_3State) && ((m_pProperties->m_dwStates & FWL_STATE_CKB_CheckMask) == FWL_STATE_CKB_Neutral)) { @@ -226,7 +226,7 @@ FX_INT32 CFWL_CheckBoxImp::GetCheckState() } return 0; } -FWL_ERR CFWL_CheckBoxImp::SetCheckState(FX_INT32 iCheck) +FWL_ERR CFWL_CheckBoxImp::SetCheckState(int32_t iCheck) { m_pProperties->m_dwStates &= ~FWL_STATE_CKB_CheckMask; switch(iCheck) { @@ -251,8 +251,8 @@ FWL_ERR CFWL_CheckBoxImp::SetCheckState(FX_INT32 iCheck) } void CFWL_CheckBoxImp::Layout() { - FX_INT32 width = FX_INT32(m_pProperties->m_rtWidget.width + 0.5f); - FX_INT32 height = FX_INT32(m_pProperties->m_rtWidget.height + 0.5f); + int32_t width = int32_t(m_pProperties->m_rtWidget.width + 0.5f); + int32_t height = int32_t(m_pProperties->m_rtWidget.height + 0.5f); m_pProperties->m_rtWidget.width = (FX_FLOAT)width; m_pProperties->m_rtWidget.height = (FX_FLOAT)height; GetClientRect(m_rtClient); @@ -322,7 +322,7 @@ void CFWL_CheckBoxImp::Layout() } FX_DWORD CFWL_CheckBoxImp::GetPartStates() { - FX_INT32 dwStates = FWL_PARTSTATE_CKB_UnChecked; + int32_t dwStates = FWL_PARTSTATE_CKB_UnChecked; if ((m_pProperties->m_dwStates & FWL_STATE_CKB_CheckMask) == FWL_STATE_CKB_Neutral) { dwStates = FWL_PARTSTATE_CKB_Neutral; } else if ((m_pProperties->m_dwStates & FWL_STATE_CKB_CheckMask) == FWL_STATE_CKB_Checked) { @@ -406,8 +406,8 @@ void CFWL_CheckBoxImp::NextStates() CFX_PtrArray radioarr; pWidgetMgr->GetSameGroupRadioButton(m_pInterface, radioarr); IFWL_CheckBox *pCheckBox = NULL; - FX_INT32 iCount = radioarr.GetSize(); - for (FX_INT32 i = 0; i < iCount; i++) { + int32_t iCount = radioarr.GetSize(); + for (int32_t i = 0; i < iCount; i++) { pCheckBox = (IFWL_CheckBox *)radioarr[i]; if (pCheckBox != m_pInterface && pCheckBox->GetStates() & FWL_STATE_CKB_Checked) { pCheckBox->SetCheckState(0); @@ -449,11 +449,11 @@ CFWL_CheckBoxImpDelegate::CFWL_CheckBoxImpDelegate(CFWL_CheckBoxImp *pOwner) : m_pOwner(pOwner) { } -FX_INT32 CFWL_CheckBoxImpDelegate::OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_CheckBoxImpDelegate::OnProcessMessage(CFWL_Message *pMessage) { _FWL_RETURN_VALUE_IF_FAIL(pMessage, 0); FX_DWORD dwMsgCode = pMessage->GetClassID(); - FX_INT32 iRet = 1; + int32_t iRet = 1; switch (dwMsgCode) { case FWL_MSGHASH_Activate: { OnActivate(pMessage); diff --git a/xfa/src/fwl/src/basewidget/fwl_comboboximp.cpp b/xfa/src/fwl/src/basewidget/fwl_comboboximp.cpp index 0200f92eaa..5658f87e13 100644 --- a/xfa/src/fwl/src/basewidget/fwl_comboboximp.cpp +++ b/xfa/src/fwl/src/basewidget/fwl_comboboximp.cpp @@ -45,11 +45,11 @@ FWL_ERR IFWL_ComboBox::Initialize(const CFWL_WidgetImpProperties &properties, IF ((CFWL_ComboBoxImp*)m_pData)->SetInterface(this); return ((CFWL_ComboBoxImp*)m_pData)->Initialize(); } -FX_INT32 IFWL_ComboBox::GetCurSel() +int32_t IFWL_ComboBox::GetCurSel() { return ((CFWL_ComboBoxImp*)m_pData)->GetCurSel(); } -FWL_ERR IFWL_ComboBox::SetCurSel(FX_INT32 iSel) +FWL_ERR IFWL_ComboBox::SetCurSel(int32_t iSel) { return ((CFWL_ComboBoxImp*)m_pData)->SetCurSel(iSel); } @@ -57,31 +57,31 @@ FWL_ERR IFWL_ComboBox::SetEditText(const CFX_WideString &wsText) { return ((CFWL_ComboBoxImp*)m_pData)->SetEditText(wsText); } -FX_INT32 IFWL_ComboBox::GetEditTextLength() const +int32_t IFWL_ComboBox::GetEditTextLength() const { return ((CFWL_ComboBoxImp*)m_pData)->GetEditTextLength(); } -FWL_ERR IFWL_ComboBox::GetEditText(CFX_WideString &wsText, FX_INT32 nStart, FX_INT32 nCount) const +FWL_ERR IFWL_ComboBox::GetEditText(CFX_WideString &wsText, int32_t nStart, int32_t nCount) const { return ((CFWL_ComboBoxImp*)m_pData)->GetEditText(wsText, nStart, nCount); } -FWL_ERR IFWL_ComboBox::SetEditSelRange(FX_INT32 nStart, FX_INT32 nCount) +FWL_ERR IFWL_ComboBox::SetEditSelRange(int32_t nStart, int32_t nCount) { return ((CFWL_ComboBoxImp*)m_pData)->SetEditSelRange(nStart, nCount); } -FX_INT32 IFWL_ComboBox::GetEditSelRange(FX_INT32 nIndex, FX_INT32 &nStart) +int32_t IFWL_ComboBox::GetEditSelRange(int32_t nIndex, int32_t &nStart) { return ((CFWL_ComboBoxImp*)m_pData)->GetEditSelRange(nIndex, nStart); } -FX_INT32 IFWL_ComboBox::GetEditLimit() +int32_t IFWL_ComboBox::GetEditLimit() { return ((CFWL_ComboBoxImp*)m_pData)->GetEditLimit(); } -FWL_ERR IFWL_ComboBox::SetEditLimit(FX_INT32 nLimit) +FWL_ERR IFWL_ComboBox::SetEditLimit(int32_t nLimit) { return ((CFWL_ComboBoxImp*)m_pData)->SetEditLimit(nLimit); } -FWL_ERR IFWL_ComboBox::EditDoClipboard(FX_INT32 iCmd) +FWL_ERR IFWL_ComboBox::EditDoClipboard(int32_t iCmd) { return ((CFWL_ComboBoxImp*)m_pData)->EditDoClipboard(iCmd); } @@ -185,7 +185,7 @@ CFWL_ComboEditDelegate::CFWL_ComboEditDelegate(CFWL_ComboEdit *pOwner) , m_pOwner(pOwner) { } -FX_INT32 CFWL_ComboEditDelegate::OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_ComboEditDelegate::OnProcessMessage(CFWL_Message *pMessage) { _FWL_RETURN_VALUE_IF_FAIL(pMessage, 0); FX_DWORD dwMsgCode = pMessage->GetClassID(); @@ -276,15 +276,15 @@ FWL_ERR CFWL_ComboList::Finalize() } return CFWL_ListBoxImp::Finalize(); } -FX_INT32 CFWL_ComboList::MatchItem(const CFX_WideString &wsMatch) +int32_t CFWL_ComboList::MatchItem(const CFX_WideString &wsMatch) { if (wsMatch.IsEmpty()) { return -1; } _FWL_RETURN_VALUE_IF_FAIL(m_pProperties->m_pDataProvider, -1); IFWL_ListBoxDP *pData = (IFWL_ListBoxDP*)m_pProperties->m_pDataProvider; - FX_INT32 iCount = pData->CountItems(m_pInterface); - for (FX_INT32 i = 0; i < iCount; i ++) { + int32_t iCount = pData->CountItems(m_pInterface); + for (int32_t i = 0; i < iCount; i ++) { FWL_HLISTITEM hItem = pData->GetItem(m_pInterface, i); CFX_WideString wsText; pData->GetItemText(m_pInterface, hItem, wsText); @@ -295,7 +295,7 @@ FX_INT32 CFWL_ComboList::MatchItem(const CFX_WideString &wsMatch) } return -1; } -void CFWL_ComboList::ChangeSelected(FX_INT32 iSel) +void CFWL_ComboList::ChangeSelected(int32_t iSel) { _FWL_RETURN_IF_FAIL(m_pProperties->m_pDataProvider); IFWL_ListBoxDP *pData = (IFWL_ListBoxDP*)m_pProperties->m_pDataProvider; @@ -303,7 +303,7 @@ void CFWL_ComboList::ChangeSelected(FX_INT32 iSel) CFX_RectF rtInvalidate; rtInvalidate.Reset(); FWL_HLISTITEM hOld = GetSelItem(0); - FX_INT32 iOld = pData->GetItemIndex(m_pInterface, hOld); + int32_t iOld = pData->GetItemIndex(m_pInterface, hOld); if (iOld == iSel) { return; } else if (iOld > -1) { @@ -321,13 +321,13 @@ void CFWL_ComboList::ChangeSelected(FX_INT32 iSel) Repaint(&rtInvalidate); } } -FX_INT32 CFWL_ComboList::CountItems() +int32_t CFWL_ComboList::CountItems() { _FWL_RETURN_VALUE_IF_FAIL(m_pProperties->m_pDataProvider, 0); IFWL_ListBoxDP *pData = (IFWL_ListBoxDP*)m_pProperties->m_pDataProvider; return pData->CountItems(m_pInterface); } -void CFWL_ComboList::GetItemRect(FX_INT32 nIndex, CFX_RectF &rtItem) +void CFWL_ComboList::GetItemRect(int32_t nIndex, CFX_RectF &rtItem) { IFWL_ListBoxDP *pData = (IFWL_ListBoxDP*)m_pProperties->m_pDataProvider; FWL_HLISTITEM hItem = pData->GetItem(m_pInterface, nIndex); @@ -349,7 +349,7 @@ CFWL_ComboListDelegate::CFWL_ComboListDelegate(CFWL_ComboList *pOwner) , m_pOwner(pOwner) { } -FX_INT32 CFWL_ComboListDelegate::OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_ComboListDelegate::OnProcessMessage(CFWL_Message *pMessage) { _FWL_RETURN_VALUE_IF_FAIL(pMessage, 0); FX_DWORD dwHashCode = pMessage->GetClassID(); @@ -407,7 +407,7 @@ void CFWL_ComboListDelegate::OnDropListFocusChanged(CFWL_Message *pMsg, FX_BOOL } } } -FX_INT32 CFWL_ComboListDelegate::OnDropListMouseMove(CFWL_MsgMouse *pMsg) +int32_t CFWL_ComboListDelegate::OnDropListMouseMove(CFWL_MsgMouse *pMsg) { if (m_pOwner->m_rtClient.Contains(pMsg->m_fx, pMsg->m_fy)) { if (m_pOwner->m_bNotifyOwner) { @@ -424,7 +424,7 @@ FX_INT32 CFWL_ComboListDelegate::OnDropListMouseMove(CFWL_MsgMouse *pMsg) if (hItem) { _FWL_RETURN_VALUE_IF_FAIL(m_pOwner->m_pProperties->m_pDataProvider, 0); IFWL_ListBoxDP *pData = (IFWL_ListBoxDP*)m_pOwner->m_pProperties->m_pDataProvider; - FX_INT32 iSel = pData->GetItemIndex(m_pOwner->m_pInterface, hItem); + int32_t iSel = pData->GetItemIndex(m_pOwner->m_pInterface, hItem); CFWL_EvtCmbHoverChanged event; event.m_pSrcTarget = m_pOwner->m_pOuter; event.m_iCurHover = iSel; @@ -438,7 +438,7 @@ FX_INT32 CFWL_ComboListDelegate::OnDropListMouseMove(CFWL_MsgMouse *pMsg) } return 1; } -FX_INT32 CFWL_ComboListDelegate::OnDropListLButtonDown(CFWL_MsgMouse *pMsg) +int32_t CFWL_ComboListDelegate::OnDropListLButtonDown(CFWL_MsgMouse *pMsg) { if (m_pOwner->m_rtClient.Contains(pMsg->m_fx, pMsg->m_fy)) { return 0; @@ -447,7 +447,7 @@ FX_INT32 CFWL_ComboListDelegate::OnDropListLButtonDown(CFWL_MsgMouse *pMsg) pOuter->ShowDropList(FALSE); return 1; } -FX_INT32 CFWL_ComboListDelegate::OnDropListLButtonUp(CFWL_MsgMouse *pMsg) +int32_t CFWL_ComboListDelegate::OnDropListLButtonUp(CFWL_MsgMouse *pMsg) { CFWL_ComboBoxImp *pOuter = (CFWL_ComboBoxImp*)((IFWL_TargetData*)m_pOwner->m_pOuter)->GetData(); if (m_pOwner->m_bNotifyOwner) { @@ -469,7 +469,7 @@ FX_INT32 CFWL_ComboListDelegate::OnDropListLButtonUp(CFWL_MsgMouse *pMsg) } return 1; } -FX_INT32 CFWL_ComboListDelegate::OnDropListKey(CFWL_MsgKey *pKey) +int32_t CFWL_ComboListDelegate::OnDropListKey(CFWL_MsgKey *pKey) { CFWL_ComboBoxImp *pOuter = (CFWL_ComboBoxImp*)((IFWL_TargetData*)m_pOwner->m_pOuter)->GetData(); FX_BOOL bPropagate = FALSE; @@ -783,13 +783,13 @@ FWL_ERR CFWL_ComboBoxImp::SetThemeProvider(IFWL_ThemeProvider *pThemeProvider) } return FWL_ERR_Succeeded; } -FX_INT32 CFWL_ComboBoxImp::GetCurSel() +int32_t CFWL_ComboBoxImp::GetCurSel() { return m_iCurSel; } -FWL_ERR CFWL_ComboBoxImp::SetCurSel(FX_INT32 iSel) +FWL_ERR CFWL_ComboBoxImp::SetCurSel(int32_t iSel) { - FX_INT32 iCount = ((CFWL_ComboList*)((IFWL_TargetData*)m_pListBox)->GetData())->CountItems(); + int32_t iCount = ((CFWL_ComboList*)((IFWL_TargetData*)m_pListBox)->GetData())->CountItems(); FX_BOOL bClearSel = iSel < 0 || iSel >= iCount; FX_BOOL bDropDown = IsDropDownStyle(); if (bDropDown && m_pEdit) { @@ -824,12 +824,12 @@ FWL_ERR CFWL_ComboBoxImp::SetEditText(const CFX_WideString &wsText) m_pEdit->SetText(wsText); return m_pEdit->Update(); } -FX_INT32 CFWL_ComboBoxImp::GetEditTextLength() const +int32_t CFWL_ComboBoxImp::GetEditTextLength() const { _FWL_RETURN_VALUE_IF_FAIL(m_pEdit, -1); return m_pEdit->GetTextLength(); } -FWL_ERR CFWL_ComboBoxImp::GetEditText(CFX_WideString &wsText, FX_INT32 nStart , FX_INT32 nCount ) const +FWL_ERR CFWL_ComboBoxImp::GetEditText(CFX_WideString &wsText, int32_t nStart , int32_t nCount ) const { if (m_pEdit) { return m_pEdit->GetText(wsText, nStart, nCount); @@ -840,29 +840,29 @@ FWL_ERR CFWL_ComboBoxImp::GetEditText(CFX_WideString &wsText, FX_INT32 nStart , } return FWL_ERR_Indefinite; } -FWL_ERR CFWL_ComboBoxImp::SetEditSelRange(FX_INT32 nStart, FX_INT32 nCount ) +FWL_ERR CFWL_ComboBoxImp::SetEditSelRange(int32_t nStart, int32_t nCount ) { _FWL_RETURN_VALUE_IF_FAIL(m_pEdit, FWL_ERR_Indefinite); ((CFWL_ComboEdit*)((IFWL_TargetData*)m_pEdit)->GetData())->ClearSelected(); m_pEdit->AddSelRange(nStart, nCount); return FWL_ERR_Succeeded; } -FX_INT32 CFWL_ComboBoxImp::GetEditSelRange(FX_INT32 nIndex, FX_INT32 &nStart) +int32_t CFWL_ComboBoxImp::GetEditSelRange(int32_t nIndex, int32_t &nStart) { _FWL_RETURN_VALUE_IF_FAIL(m_pEdit, -1); return m_pEdit->GetSelRange(nIndex, nStart); } -FX_INT32 CFWL_ComboBoxImp::GetEditLimit() +int32_t CFWL_ComboBoxImp::GetEditLimit() { _FWL_RETURN_VALUE_IF_FAIL(m_pEdit, -1); return m_pEdit->GetLimit(); } -FWL_ERR CFWL_ComboBoxImp::SetEditLimit(FX_INT32 nLimit) +FWL_ERR CFWL_ComboBoxImp::SetEditLimit(int32_t nLimit) { _FWL_RETURN_VALUE_IF_FAIL(m_pEdit, FWL_ERR_Indefinite); return m_pEdit->SetLimit(nLimit); } -FWL_ERR CFWL_ComboBoxImp::EditDoClipboard(FX_INT32 iCmd) +FWL_ERR CFWL_ComboBoxImp::EditDoClipboard(int32_t iCmd) { _FWL_RETURN_VALUE_IF_FAIL(m_pEdit, FWL_ERR_Indefinite); return m_pEdit->DoClipboard(iCmd); @@ -1080,7 +1080,7 @@ void CFWL_ComboBoxImp::MatchEditText() { CFX_WideString wsText; m_pEdit->GetText(wsText); - FX_INT32 iMatch = ((CFWL_ComboList*)((IFWL_TargetData*)m_pListBox)->GetData())->MatchItem(wsText); + int32_t iMatch = ((CFWL_ComboList*)((IFWL_TargetData*)m_pListBox)->GetData())->MatchItem(wsText); if (iMatch != m_iCurSel) { ((CFWL_ComboList*)((IFWL_TargetData*)m_pListBox)->GetData())->ChangeSelected(iMatch); if (iMatch >= 0) { @@ -1091,7 +1091,7 @@ void CFWL_ComboBoxImp::MatchEditText() } m_iCurSel = iMatch; } -void CFWL_ComboBoxImp::SynchrEditText(FX_INT32 iListItem) +void CFWL_ComboBoxImp::SynchrEditText(int32_t iListItem) { CFX_WideString wsText; IFWL_ComboBoxDP *pData = (IFWL_ComboBoxDP *)m_pProperties->m_pDataProvider; @@ -1301,7 +1301,7 @@ void CFWL_ComboBoxImp::DisForm_ShowDropList(FX_BOOL bActivate) preEvent.m_pSrcTarget = m_pInterface; DispatchEvent(&preEvent); CFWL_ComboList* pComboList = (CFWL_ComboList*)(((IFWL_TargetData*)m_pListBox)->GetData()); - FX_INT32 iItems = pComboList->CountItems(); + int32_t iItems = pComboList->CountItems(); if (iItems < 1) { return; } @@ -1482,7 +1482,7 @@ CFWL_ComboBoxImpDelegate::CFWL_ComboBoxImpDelegate(CFWL_ComboBoxImp *pOwner) : m_pOwner(pOwner) { } -FX_INT32 CFWL_ComboBoxImpDelegate::OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_ComboBoxImpDelegate::OnProcessMessage(CFWL_Message *pMessage) { if (m_pOwner->m_pWidgetMgr->IsFormDisabled()) { return DisForm_OnProcessMessage(pMessage); @@ -1620,7 +1620,7 @@ void CFWL_ComboBoxImpDelegate::OnLButtonUp(CFWL_MsgMouse *pMsg) } void CFWL_ComboBoxImpDelegate::OnMouseMove(CFWL_MsgMouse *pMsg) { - FX_INT32 iOldState = m_pOwner->m_iBtnState; + int32_t iOldState = m_pOwner->m_iBtnState; if (m_pOwner->m_rtBtn.Contains(pMsg->m_fx, pMsg->m_fy)) { m_pOwner->m_iBtnState = m_pOwner->m_bLButtonDown ? FWL_PARTSTATE_CMB_Pressed : FWL_PARTSTATE_CMB_Hovered; } else { @@ -1657,12 +1657,12 @@ void CFWL_ComboBoxImpDelegate::DoSubCtrlKey(CFWL_MsgKey *pMsg) FX_BOOL bUp = dwKeyCode == FWL_VKEY_Up; FX_BOOL bDown = dwKeyCode == FWL_VKEY_Down; if (bUp || bDown) { - FX_INT32 iCount = ((CFWL_ComboList*)((IFWL_TargetData*)m_pOwner->m_pListBox)->GetData())->CountItems(); + int32_t iCount = ((CFWL_ComboList*)((IFWL_TargetData*)m_pOwner->m_pListBox)->GetData())->CountItems(); if (iCount < 1) { return; } FX_BOOL bMatchEqual = FALSE; - FX_INT32 iCurSel = m_pOwner->m_iCurSel; + int32_t iCurSel = m_pOwner->m_iCurSel; FX_BOOL bDropDown = m_pOwner->IsDropDownStyle(); if (bDropDown && m_pOwner->m_pEdit) { CFX_WideString wsText; @@ -1702,7 +1702,7 @@ void CFWL_ComboBoxImpDelegate::DoSubCtrlKey(CFWL_MsgKey *pMsg) pDelegate->OnProcessMessage(pMsg); } } -FX_INT32 CFWL_ComboBoxImpDelegate::DisForm_OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_ComboBoxImpDelegate::DisForm_OnProcessMessage(CFWL_Message *pMessage) { _FWL_RETURN_VALUE_IF_FAIL(pMessage, 0); FX_DWORD dwMsgCode = pMessage->GetClassID(); @@ -1810,12 +1810,12 @@ void CFWL_ComboBoxImpDelegate::DisForm_OnKey(CFWL_MsgKey *pMsg) FX_BOOL bDown = dwKeyCode == FWL_VKEY_Down; if (bUp || bDown) { CFWL_ComboList* pComboList = ((CFWL_ComboList*)((IFWL_TargetData*)(m_pOwner->m_pListBox))->GetData()); - FX_INT32 iCount = pComboList->CountItems(); + int32_t iCount = pComboList->CountItems(); if (iCount < 1) { return; } FX_BOOL bMatchEqual = FALSE; - FX_INT32 iCurSel = m_pOwner->m_iCurSel; + int32_t iCurSel = m_pOwner->m_iCurSel; if (m_pOwner->m_pEdit) { CFX_WideString wsText; m_pOwner->m_pEdit->GetText(wsText); @@ -1856,7 +1856,7 @@ CFWL_ComboProxyImpDelegate::CFWL_ComboProxyImpDelegate(IFWL_Form *pForm, CFWL_Co , m_fStartPos(0) { } -FX_INT32 CFWL_ComboProxyImpDelegate::OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_ComboProxyImpDelegate::OnProcessMessage(CFWL_Message *pMessage) { _FWL_RETURN_VALUE_IF_FAIL(pMessage, 0); FX_DWORD dwMsgCode = pMessage->GetClassID(); diff --git a/xfa/src/fwl/src/basewidget/fwl_datetimepickerimp.cpp b/xfa/src/fwl/src/basewidget/fwl_datetimepickerimp.cpp index b3e3b45dae..c9f3367114 100644 --- a/xfa/src/fwl/src/basewidget/fwl_datetimepickerimp.cpp +++ b/xfa/src/fwl/src/basewidget/fwl_datetimepickerimp.cpp @@ -62,19 +62,19 @@ FWL_ERR IFWL_DateTimePicker::Initialize(const CFWL_WidgetImpProperties &properti ((CFWL_DateTimePickerImp*)m_pData)->SetInterface(this); return ((CFWL_DateTimePickerImp*)m_pData)->Initialize(); } -FX_INT32 IFWL_DateTimePicker::CountSelRanges() +int32_t IFWL_DateTimePicker::CountSelRanges() { return ((CFWL_DateTimePickerImp*)m_pData)->GetDataTimeEdit()->CountSelRanges(); } -FX_INT32 IFWL_DateTimePicker::GetSelRange(FX_INT32 nIndex, FX_INT32 &nStart) +int32_t IFWL_DateTimePicker::GetSelRange(int32_t nIndex, int32_t &nStart) { return ((CFWL_DateTimePickerImp*)m_pData)->GetDataTimeEdit()->GetSelRange(nIndex, nStart); } -FWL_ERR IFWL_DateTimePicker::GetCurSel(FX_INT32 &iYear, FX_INT32 &iMonth, FX_INT32 &iDay) +FWL_ERR IFWL_DateTimePicker::GetCurSel(int32_t &iYear, int32_t &iMonth, int32_t &iDay) { return ((CFWL_DateTimePickerImp*)m_pData)->GetCurSel(iYear, iMonth, iDay); } -FWL_ERR IFWL_DateTimePicker::SetCurSel(FX_INT32 iYear, FX_INT32 iMonth, FX_INT32 iDay) +FWL_ERR IFWL_DateTimePicker::SetCurSel(int32_t iYear, int32_t iMonth, int32_t iDay) { return ((CFWL_DateTimePickerImp*)m_pData)->SetCurSel(iYear, iMonth, iDay); } @@ -82,7 +82,7 @@ FWL_ERR IFWL_DateTimePicker::SetEditText(const CFX_WideString &wsText) { return ((CFWL_DateTimePickerImp*)m_pData)->SetEditText(wsText); } -FWL_ERR IFWL_DateTimePicker::GetEditText(CFX_WideString &wsText, FX_INT32 nStart, FX_INT32 nCount) const +FWL_ERR IFWL_DateTimePicker::GetEditText(CFX_WideString &wsText, int32_t nStart, int32_t nCount) const { return ((CFWL_DateTimePickerImp*)m_pData)->GetEditText(wsText, nStart, nCount); } @@ -142,7 +142,7 @@ FWL_ERR IFWL_DateTimePicker::GetBBox(CFX_RectF &rect) { return ((CFWL_DateTimePickerImp*)m_pData)->GetBBox(rect); } -FWL_ERR IFWL_DateTimePicker::SetEditLimit(FX_INT32 nLimit) +FWL_ERR IFWL_DateTimePicker::SetEditLimit(int32_t nLimit) { return ((CFWL_DateTimePickerImp*)m_pData)->SetEditLimit(nLimit); } @@ -173,7 +173,7 @@ CFWL_DateTimeEditDelegate::CFWL_DateTimeEditDelegate(CFWL_DateTimeEdit *pOwner) , m_pOwner(pOwner) { } -FX_INT32 CFWL_DateTimeEditDelegate::OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_DateTimeEditDelegate::OnProcessMessage(CFWL_Message *pMessage) { if (m_pOwner->m_pWidgetMgr->IsFormDisabled()) { return DisForm_OnProcessMessage(pMessage); @@ -186,7 +186,7 @@ FX_INT32 CFWL_DateTimeEditDelegate::OnProcessMessage(CFWL_Message *pMessage) } return 1; } -FX_INT32 CFWL_DateTimeEditDelegate::DisForm_OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_DateTimeEditDelegate::DisForm_OnProcessMessage(CFWL_Message *pMessage) { FX_DWORD dwHashCode = pMessage->GetClassID(); if (m_pOwner->m_pWidgetMgr->IsFormDisabled()) { @@ -238,7 +238,7 @@ CFWL_DateTimeCalendarDelegate::CFWL_DateTimeCalendarDelegate(CFWL_DateTimeCalend { m_bFlag = FALSE; } -FX_INT32 CFWL_DateTimeCalendarDelegate::OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_DateTimeCalendarDelegate::OnProcessMessage(CFWL_Message *pMessage) { FX_DWORD dwCode = pMessage->GetClassID(); if (dwCode == FWL_MSGHASH_SetFocus || dwCode == FWL_MSGHASH_KillFocus) { @@ -298,11 +298,11 @@ void CFWL_DateTimeCalendarDelegate::OnLButtonUpEx(CFWL_MsgMouse *pMsg) if (m_pOwner->m_rtToday.Contains(pMsg->m_fx, pMsg->m_fy)) { return; } - FX_INT32 iOldSel = 0; + int32_t iOldSel = 0; if (m_pOwner->m_arrSelDays.GetSize() > 0) { iOldSel = m_pOwner->m_arrSelDays[0]; } - FX_INT32 iCurSel = m_pOwner->GetDayAtPoint(pMsg->m_fx, pMsg->m_fy); + int32_t iCurSel = m_pOwner->GetDayAtPoint(pMsg->m_fx, pMsg->m_fy); CFX_RectF rt; IFWL_DateTimePicker *pIPicker = (IFWL_DateTimePicker *)m_pOwner->m_pOuter; CFWL_DateTimePickerImp *pPicker = (CFWL_DateTimePickerImp *)((IFWL_TargetData *)pIPicker)->GetData(); @@ -335,7 +335,7 @@ void CFWL_DateTimeCalendarDelegate::OnMouseMoveEx(CFWL_MsgMouse *pMsg) CFX_RectF rtInvalidate; rtInvalidate.Set(0, 0, 0, 0); if (m_pOwner->m_rtDates.Contains(pMsg->m_fx, pMsg->m_fy)) { - FX_INT32 iHover = m_pOwner->GetDayAtPoint(pMsg->m_fx, pMsg->m_fy); + int32_t iHover = m_pOwner->GetDayAtPoint(pMsg->m_fx, pMsg->m_fy); bRepaint = m_pOwner->m_iHovered != iHover; if (bRepaint) { if (m_pOwner->m_iHovered > 0) { @@ -366,7 +366,7 @@ void CFWL_DateTimeCalendarDelegate::OnMouseMoveEx(CFWL_MsgMouse *pMsg) m_pOwner->Repaint(&rtInvalidate); } } -FX_INT32 CFWL_DateTimeCalendarDelegate::DisForm_OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_DateTimeCalendarDelegate::DisForm_OnProcessMessage(CFWL_Message *pMessage) { if (pMessage->GetClassID() == FWL_MSGHASH_Mouse) { CFWL_MsgMouse *pMsg = (CFWL_MsgMouse*)pMessage; @@ -392,11 +392,11 @@ void CFWL_DateTimeCalendarDelegate::DisForm_OnLButtonUpEx(CFWL_MsgMouse *pMsg) if (m_pOwner->m_rtToday.Contains(pMsg->m_fx, pMsg->m_fy)) { return; } - FX_INT32 iOldSel = 0; + int32_t iOldSel = 0; if (m_pOwner->m_arrSelDays.GetSize() > 0) { iOldSel = m_pOwner->m_arrSelDays[0]; } - FX_INT32 iCurSel = m_pOwner->GetDayAtPoint(pMsg->m_fx, pMsg->m_fy); + int32_t iCurSel = m_pOwner->GetDayAtPoint(pMsg->m_fx, pMsg->m_fy); if (iCurSel > 0) { LPDATEINFO lpDatesInfo = (LPDATEINFO)m_pOwner->m_arrDates.GetAt(iCurSel - 1); CFX_RectF rtInvalidate(lpDatesInfo->rect); @@ -599,14 +599,14 @@ FWL_ERR CFWL_DateTimePickerImp::SetThemeProvider(IFWL_ThemeProvider *pTP) m_pMonthCal->SetThemeProvider(pTP); return FWL_ERR_Succeeded; } -FWL_ERR CFWL_DateTimePickerImp::GetCurSel(FX_INT32 &iYear, FX_INT32 &iMonth, FX_INT32 &iDay) +FWL_ERR CFWL_DateTimePickerImp::GetCurSel(int32_t &iYear, int32_t &iMonth, int32_t &iDay) { iYear = m_iYear; iMonth = m_iMonth; iDay = m_iDay; return FWL_ERR_Succeeded; } -FWL_ERR CFWL_DateTimePickerImp::SetCurSel(FX_INT32 iYear, FX_INT32 iMonth, FX_INT32 iDay) +FWL_ERR CFWL_DateTimePickerImp::SetCurSel(int32_t iYear, int32_t iMonth, int32_t iDay) { _FWL_RETURN_VALUE_IF_FAIL(iYear > 0 && iYear < 3000, FWL_ERR_Indefinite); _FWL_RETURN_VALUE_IF_FAIL(iMonth > 0 && iMonth < 13, FWL_ERR_Indefinite); @@ -620,14 +620,14 @@ FWL_ERR CFWL_DateTimePickerImp::SetCurSel(FX_INT32 iYear, FX_INT32 iMonth, FX_IN FWL_ERR CFWL_DateTimePickerImp::SetEditText(const CFX_WideString &wsText) { _FWL_RETURN_VALUE_IF_FAIL(m_pEdit, FWL_ERR_Indefinite); - FX_INT32 iRet = m_pEdit->SetText(wsText); + int32_t iRet = m_pEdit->SetText(wsText); Repaint(&m_rtClient); CFWL_Event_DtpEditChanged ev; ev.m_wsText = wsText; DispatchEvent(&ev); return iRet; } -FWL_ERR CFWL_DateTimePickerImp::GetEditText(CFX_WideString &wsText, FX_INT32 nStart, FX_INT32 nCount) const +FWL_ERR CFWL_DateTimePickerImp::GetEditText(CFX_WideString &wsText, int32_t nStart, int32_t nCount) const { if (m_pEdit) { return m_pEdit->GetText(wsText, nStart, nCount); @@ -652,7 +652,7 @@ FX_BOOL CFWL_DateTimePickerImp::Redo() } FX_BOOL CFWL_DateTimePickerImp::CanCopy() { - FX_INT32 nCount = m_pEdit->CountSelRanges(); + int32_t nCount = m_pEdit->CountSelRanges(); return nCount > 0; } FX_BOOL CFWL_DateTimePickerImp::CanCut() @@ -660,7 +660,7 @@ FX_BOOL CFWL_DateTimePickerImp::CanCut() if (m_pEdit->GetStylesEx() & FWL_STYLEEXT_EDT_ReadOnly) { return FALSE; } - FX_INT32 nCount = m_pEdit->CountSelRanges(); + int32_t nCount = m_pEdit->CountSelRanges(); return nCount > 0; } FX_BOOL CFWL_DateTimePickerImp::CanSelectAll() @@ -705,7 +705,7 @@ FWL_ERR CFWL_DateTimePickerImp::GetBBox(CFX_RectF &rect) } return FWL_ERR_Succeeded; } -FWL_ERR CFWL_DateTimePickerImp::SetEditLimit(FX_INT32 nLimit) +FWL_ERR CFWL_DateTimePickerImp::SetEditLimit(int32_t nLimit) { return m_pEdit->SetLimit(nLimit); } @@ -735,7 +735,7 @@ void CFWL_DateTimePickerImp::DrawDropDownButton(CFX_Graphics *pGraphics, IFWL_Th pTheme->DrawBackground(¶m); } } -void CFWL_DateTimePickerImp::FormatDateString(FX_INT32 iYear, FX_INT32 iMonth, FX_INT32 iDay, CFX_WideString &wsText) +void CFWL_DateTimePickerImp::FormatDateString(int32_t iYear, int32_t iMonth, int32_t iDay, CFX_WideString &wsText) { if ((m_pProperties->m_dwStyleExes & FWL_STYLEEXT_DTP_ShortDateFormat) == FWL_STYLEEXT_DTP_ShortDateFormat) { wsText.Format(FX_LPCWSTR(L"%d-%d-%d"), iYear, iMonth, iDay); @@ -823,7 +823,7 @@ void CFWL_DateTimePickerImp::ReSetEditAlignment() FWL_STYLEEXT_EDT_HAlignModeMask | FWL_STYLEEXT_EDT_VAlignMask); } -void CFWL_DateTimePickerImp::ProcessSelChanged(FX_INT32 iYear, FX_INT32 iMonth, FX_INT32 iDay) +void CFWL_DateTimePickerImp::ProcessSelChanged(int32_t iYear, int32_t iMonth, int32_t iDay) { m_iYear = iYear; m_iMonth = iMonth; @@ -1054,11 +1054,11 @@ CFWL_DateTimePickerImpDelegate::CFWL_DateTimePickerImpDelegate(CFWL_DateTimePick : m_pOwner(pOwner) { } -FX_INT32 CFWL_DateTimePickerImpDelegate::OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_DateTimePickerImpDelegate::OnProcessMessage(CFWL_Message *pMessage) { _FWL_RETURN_VALUE_IF_FAIL(pMessage, 0); FX_DWORD dwMsgCode = pMessage->GetClassID(); - FX_INT32 iRet = 1; + int32_t iRet = 1; switch (dwMsgCode) { case FWL_MSGHASH_SetFocus: case FWL_MSGHASH_KillFocus: { diff --git a/xfa/src/fwl/src/basewidget/fwl_editimp.cpp b/xfa/src/fwl/src/basewidget/fwl_editimp.cpp index c7bd922fc1..0afa1d5467 100644 --- a/xfa/src/fwl/src/basewidget/fwl_editimp.cpp +++ b/xfa/src/fwl/src/basewidget/fwl_editimp.cpp @@ -45,11 +45,11 @@ FWL_ERR IFWL_Edit::SetText(const CFX_WideString &wsText) { return ((CFWL_EditImp*)m_pData)->SetText(wsText); } -FX_INT32 IFWL_Edit::GetTextLength() const +int32_t IFWL_Edit::GetTextLength() const { return ((CFWL_EditImp*)m_pData)->GetTextLength(); } -FWL_ERR IFWL_Edit::GetText(CFX_WideString &wsText, FX_INT32 nStart, FX_INT32 nCount) const +FWL_ERR IFWL_Edit::GetText(CFX_WideString &wsText, int32_t nStart, int32_t nCount) const { return ((CFWL_EditImp*)m_pData)->GetText(wsText, nStart, nCount); } @@ -57,23 +57,23 @@ FWL_ERR IFWL_Edit::ClearText() { return ((CFWL_EditImp*)m_pData)->ClearText(); } -FX_INT32 IFWL_Edit::GetCaretPos() const +int32_t IFWL_Edit::GetCaretPos() const { return ((CFWL_EditImp*)m_pData)->GetCaretPos(); } -FX_INT32 IFWL_Edit::SetCaretPos(FX_INT32 nIndex, FX_BOOL bBefore) +int32_t IFWL_Edit::SetCaretPos(int32_t nIndex, FX_BOOL bBefore) { return ((CFWL_EditImp*)m_pData)->SetCaretPos(nIndex, bBefore); } -FWL_ERR IFWL_Edit::AddSelRange(FX_INT32 nStart, FX_INT32 nCount) +FWL_ERR IFWL_Edit::AddSelRange(int32_t nStart, int32_t nCount) { return ((CFWL_EditImp*)m_pData)->AddSelRange(nStart, nCount); } -FX_INT32 IFWL_Edit::CountSelRanges() +int32_t IFWL_Edit::CountSelRanges() { return ((CFWL_EditImp*)m_pData)->CountSelRanges(); } -FX_INT32 IFWL_Edit::GetSelRange(FX_INT32 nIndex, FX_INT32 &nStart) +int32_t IFWL_Edit::GetSelRange(int32_t nIndex, int32_t &nStart) { return ((CFWL_EditImp*)m_pData)->GetSelRange(nIndex, nStart); } @@ -81,11 +81,11 @@ FWL_ERR IFWL_Edit::ClearSelections() { return ((CFWL_EditImp*)m_pData)->ClearSelections(); } -FX_INT32 IFWL_Edit::GetLimit() +int32_t IFWL_Edit::GetLimit() { return ((CFWL_EditImp*)m_pData)->GetLimit(); } -FWL_ERR IFWL_Edit::SetLimit(FX_INT32 nLimit) +FWL_ERR IFWL_Edit::SetLimit(int32_t nLimit) { return ((CFWL_EditImp*)m_pData)->SetLimit(nLimit); } @@ -97,7 +97,7 @@ FWL_ERR IFWL_Edit::SetFormatString(const CFX_WideString &wsFormat) { return ((CFWL_EditImp*)m_pData)->SetFormatString(wsFormat); } -FWL_ERR IFWL_Edit::Insert(FX_INT32 nStart, FX_LPCWSTR lpText, FX_INT32 nLen) +FWL_ERR IFWL_Edit::Insert(int32_t nStart, FX_LPCWSTR lpText, int32_t nLen) { return ((CFWL_EditImp*)m_pData)->Insert(nStart, lpText, nLen); } @@ -105,7 +105,7 @@ FWL_ERR IFWL_Edit::DeleteSelections() { return ((CFWL_EditImp*)m_pData)->DeleteSelections(); } -FWL_ERR IFWL_Edit::DeleteRange(FX_INT32 nStart, FX_INT32 nCount) +FWL_ERR IFWL_Edit::DeleteRange(int32_t nStart, int32_t nCount) { return ((CFWL_EditImp*)m_pData)->DeleteRange(nStart, nCount); } @@ -113,11 +113,11 @@ FWL_ERR IFWL_Edit::ReplaceSelections(const CFX_WideStringC &wsReplace) { return ((CFWL_EditImp*)m_pData)->ReplaceSelections(wsReplace); } -FWL_ERR IFWL_Edit::Replace(FX_INT32 nStart, FX_INT32 nLen, const CFX_WideStringC &wsReplace) +FWL_ERR IFWL_Edit::Replace(int32_t nStart, int32_t nLen, const CFX_WideStringC &wsReplace) { return ((CFWL_EditImp*)m_pData)->Replace(nStart, nLen, wsReplace); } -FWL_ERR IFWL_Edit::DoClipboard(FX_INT32 iCmd) +FWL_ERR IFWL_Edit::DoClipboard(int32_t iCmd) { return ((CFWL_EditImp*)m_pData)->DoClipboard(iCmd); } @@ -169,7 +169,7 @@ FWL_ERR IFWL_Edit::SetOuter(IFWL_Widget *pOuter) { return ((CFWL_EditImp*)m_pData)->SetOuter(pOuter); } -FWL_ERR IFWL_Edit::SetNumberRange(FX_INT32 iMin, FX_INT32 iMax) +FWL_ERR IFWL_Edit::SetNumberRange(int32_t iMin, int32_t iMax) { return ((CFWL_EditImp*)m_pData)->SetNumberRange(iMin, iMax); } @@ -313,7 +313,7 @@ FWL_ERR CFWL_EditImp::GetWidgetRect(CFX_RectF &rect, FX_BOOL bAutoSize ) if (bAutoSize) { rect.Set(0, 0, 0, 0); if (m_pEdtEngine) { - FX_INT32 iTextLen = m_pEdtEngine->GetTextLength(); + int32_t iTextLen = m_pEdtEngine->GetTextLength(); if (iTextLen > 0) { CFX_WideString wsText; m_pEdtEngine->GetText(wsText, 0); @@ -398,12 +398,12 @@ static void AddSquigglyPath(CFX_Path& PathData, FX_FLOAT fStartX, FX_FLOAT fEndX { PathData.MoveTo(fStartX, fY); FX_FLOAT fx; - FX_INT32 i; + int32_t i; for (i = 1, fx = fStartX + fStep; fx < fEndX; fx += fStep, i++) { PathData.LineTo(fx, fY + (i & 1)*fStep); } } -void CFWL_EditImp::AddSpellCheckObj(CFX_Path& PathData, FX_INT32 nStart, FX_INT32 nCount, FX_FLOAT fOffSetX, FX_FLOAT fOffSetY) +void CFWL_EditImp::AddSpellCheckObj(CFX_Path& PathData, int32_t nStart, int32_t nCount, FX_FLOAT fOffSetX, FX_FLOAT fOffSetY) { FX_FLOAT fStartX = 0.0f; FX_FLOAT fEndX = 0.0f; @@ -424,14 +424,14 @@ void CFWL_EditImp::AddSpellCheckObj(CFX_Path& PathData, FX_INT32 nStart, FX_INT3 AddSquigglyPath(PathData, fStartX, fEndX, fY, fStep); } } -FX_INT32 CFWL_EditImp::GetWordAtPoint(CFX_PointF pointf, FX_INT32& nCount) +int32_t CFWL_EditImp::GetWordAtPoint(CFX_PointF pointf, int32_t& nCount) { return 0; } FX_BOOL CFWL_EditImp::GetSuggestWords(CFX_PointF pointf, CFX_ByteStringArray &sSuggest) { - FX_INT32 nWordCount = 0; - FX_INT32 nWordStart = GetWordAtPoint(pointf, nWordCount); + int32_t nWordCount = 0; + int32_t nWordStart = GetWordAtPoint(pointf, nWordCount); if (nWordCount < 1) { return FALSE; } @@ -465,8 +465,8 @@ FX_BOOL CFWL_EditImp::GetSuggestWords(CFX_PointF pointf, CFX_ByteStringArray &sS } FX_BOOL CFWL_EditImp::ReplaceSpellCheckWord(CFX_PointF pointf, FX_BSTR bsReplace) { - FX_INT32 nWordCount = 0; - FX_INT32 nWordStart = GetWordAtPoint(pointf, nWordCount); + int32_t nWordCount = 0; + int32_t nWordStart = GetWordAtPoint(pointf, nWordCount); if (nWordCount < 1) { return FALSE; } @@ -478,10 +478,10 @@ FX_BOOL CFWL_EditImp::ReplaceSpellCheckWord(CFX_PointF pointf, FX_BSTR bsReplace break; } } - FX_INT32 nDestLen = bsReplace.GetLength(); + int32_t nDestLen = bsReplace.GetLength(); CFX_WideString wsDest; FX_LPWSTR pBuffer = wsDest.GetBuffer(nDestLen); - for (FX_INT32 i = 0; i < nDestLen; i++) { + for (int32_t i = 0; i < nDestLen; i++) { pBuffer[i] = bsReplace[i]; } wsDest.ReleaseBuffer(nDestLen); @@ -502,12 +502,12 @@ void CFWL_EditImp::DrawSpellCheck(CFX_Graphics *pGraphics, const CFX_Matrix *pMa CFX_ByteString sLatinWord; CFX_Path pathSpell; pathSpell.Create(); - FX_INT32 nStart = 0; + int32_t nStart = 0; FX_FLOAT fOffSetX = m_rtEngine.left - m_fScrollOffsetX; FX_FLOAT fOffSetY = m_rtEngine.top - m_fScrollOffsetY + m_fVAlignOffset; CFX_WideString wsSpell; this->GetText(wsSpell); - FX_INT32 nContentLen = wsSpell.GetLength(); + int32_t nContentLen = wsSpell.GetLength(); for (int i = 0; i < nContentLen; i++) { if (FX_EDIT_ISLATINWORD(wsSpell[i])) { if (sLatinWord.IsEmpty()) { @@ -590,12 +590,12 @@ FWL_ERR CFWL_EditImp::SetText(const CFX_WideString &wsText) m_pEdtEngine->SetText(wsText); return FWL_ERR_Succeeded; } -FX_INT32 CFWL_EditImp::GetTextLength() const +int32_t CFWL_EditImp::GetTextLength() const { _FWL_RETURN_VALUE_IF_FAIL(m_pEdtEngine, -1); return m_pEdtEngine->GetTextLength(); } -FWL_ERR CFWL_EditImp::GetText(CFX_WideString &wsText, FX_INT32 nStart , FX_INT32 nCount ) const +FWL_ERR CFWL_EditImp::GetText(CFX_WideString &wsText, int32_t nStart , int32_t nCount ) const { _FWL_RETURN_VALUE_IF_FAIL(m_pEdtEngine, FWL_ERR_Succeeded); m_pEdtEngine->GetText(wsText, nStart, nCount); @@ -607,29 +607,29 @@ FWL_ERR CFWL_EditImp::ClearText() m_pEdtEngine->ClearText(); return FWL_ERR_Succeeded; } -FX_INT32 CFWL_EditImp::GetCaretPos() const +int32_t CFWL_EditImp::GetCaretPos() const { _FWL_RETURN_VALUE_IF_FAIL(m_pEdtEngine, -1); return m_pEdtEngine->GetCaretPos(); } -FX_INT32 CFWL_EditImp::SetCaretPos(FX_INT32 nIndex, FX_BOOL bBefore ) +int32_t CFWL_EditImp::SetCaretPos(int32_t nIndex, FX_BOOL bBefore ) { _FWL_RETURN_VALUE_IF_FAIL(m_pEdtEngine, -1); return m_pEdtEngine->SetCaretPos(nIndex, bBefore); } -FWL_ERR CFWL_EditImp::AddSelRange(FX_INT32 nStart, FX_INT32 nCount ) +FWL_ERR CFWL_EditImp::AddSelRange(int32_t nStart, int32_t nCount ) { _FWL_RETURN_VALUE_IF_FAIL(m_pEdtEngine, FWL_ERR_Succeeded); m_pEdtEngine->AddSelRange(nStart, nCount); return FWL_ERR_Succeeded; } -FX_INT32 CFWL_EditImp::CountSelRanges() +int32_t CFWL_EditImp::CountSelRanges() { _FWL_RETURN_VALUE_IF_FAIL(m_pEdtEngine, 0); return m_pEdtEngine->CountSelRanges(); return FWL_ERR_Succeeded; } -FX_INT32 CFWL_EditImp::GetSelRange(FX_INT32 nIndex, FX_INT32 &nStart) +int32_t CFWL_EditImp::GetSelRange(int32_t nIndex, int32_t &nStart) { _FWL_RETURN_VALUE_IF_FAIL(m_pEdtEngine, -1); return m_pEdtEngine->GetSelRange(nIndex, nStart); @@ -640,11 +640,11 @@ FWL_ERR CFWL_EditImp::ClearSelections() m_pEdtEngine->ClearSelection(); return FWL_ERR_Succeeded; } -FX_INT32 CFWL_EditImp::GetLimit() +int32_t CFWL_EditImp::GetLimit() { return m_nLimit; } -FWL_ERR CFWL_EditImp::SetLimit(FX_INT32 nLimit) +FWL_ERR CFWL_EditImp::SetLimit(int32_t nLimit) { m_nLimit = nLimit; _FWL_RETURN_VALUE_IF_FAIL(m_pEdtEngine, FWL_ERR_Succeeded); @@ -663,7 +663,7 @@ FWL_ERR CFWL_EditImp::SetFormatString(const CFX_WideString &wsFormat) m_pEdtEngine->SetFormatBlock(0, wsFormat); return FWL_ERR_Succeeded; } -FWL_ERR CFWL_EditImp::Insert(FX_INT32 nStart, FX_LPCWSTR lpText, FX_INT32 nLen) +FWL_ERR CFWL_EditImp::Insert(int32_t nStart, FX_LPCWSTR lpText, int32_t nLen) { _FWL_RETURN_VALUE_IF_FAIL(m_pEdtEngine, FWL_ERR_Succeeded); if ( (m_pProperties->m_dwStyleExes & FWL_STYLEEXT_EDT_ReadOnly) @@ -676,13 +676,13 @@ FWL_ERR CFWL_EditImp::Insert(FX_INT32 nStart, FX_LPCWSTR lpText, FX_INT32 nLen) FWL_ERR CFWL_EditImp::DeleteSelections() { _FWL_RETURN_VALUE_IF_FAIL(m_pEdtEngine, FWL_ERR_Succeeded); - FX_INT32 iCount = m_pEdtEngine->CountSelRanges(); + int32_t iCount = m_pEdtEngine->CountSelRanges(); if (iCount > 0) { m_pEdtEngine->Delete(-1); } return FWL_ERR_Succeeded; } -FWL_ERR CFWL_EditImp::DeleteRange(FX_INT32 nStart, FX_INT32 nCount ) +FWL_ERR CFWL_EditImp::DeleteRange(int32_t nStart, int32_t nCount ) { _FWL_RETURN_VALUE_IF_FAIL(m_pEdtEngine, FWL_ERR_Succeeded); m_pEdtEngine->DeleteRange(nStart, nCount); @@ -691,21 +691,21 @@ FWL_ERR CFWL_EditImp::DeleteRange(FX_INT32 nStart, FX_INT32 nCount ) FWL_ERR CFWL_EditImp::ReplaceSelections(const CFX_WideStringC &wsReplace) { _FWL_RETURN_VALUE_IF_FAIL(m_pEdtEngine, FWL_ERR_Succeeded); - FX_INT32 iCount = m_pEdtEngine->CountSelRanges(); + int32_t iCount = m_pEdtEngine->CountSelRanges(); for (int i = 0; i < iCount; i ++) { - FX_INT32 nStart; - FX_INT32 nCount = m_pEdtEngine->GetSelRange(i, nStart); + int32_t nStart; + int32_t nCount = m_pEdtEngine->GetSelRange(i, nStart); m_pEdtEngine->Replace(nStart, nCount, wsReplace); } return FWL_ERR_Succeeded; } -FWL_ERR CFWL_EditImp::Replace(FX_INT32 nStart, FX_INT32 nLen, const CFX_WideStringC &wsReplace) +FWL_ERR CFWL_EditImp::Replace(int32_t nStart, int32_t nLen, const CFX_WideStringC &wsReplace) { _FWL_RETURN_VALUE_IF_FAIL(m_pEdtEngine, FWL_ERR_Succeeded); m_pEdtEngine->Replace(nStart, nLen, wsReplace); return FWL_ERR_Succeeded; } -FWL_ERR CFWL_EditImp::DoClipboard(FX_INT32 iCmd) +FWL_ERR CFWL_EditImp::DoClipboard(int32_t iCmd) { _FWL_RETURN_VALUE_IF_FAIL(m_pEdtEngine, FWL_ERR_Succeeded); if ( (m_pProperties->m_dwStyleExes & FWL_STYLEEXT_EDT_ReadOnly) @@ -719,8 +719,8 @@ FWL_ERR CFWL_EditImp::DoClipboard(FX_INT32 iCmd) CFX_WideString wsText; switch(iCmd) { case 1: { - FX_INT32 nStart; - FX_INT32 nCount = m_pEdtEngine->GetSelRange(0, nStart); + int32_t nStart; + int32_t nCount = m_pEdtEngine->GetSelRange(0, nStart); if (nCount < 1) { break; } @@ -729,8 +729,8 @@ FWL_ERR CFWL_EditImp::DoClipboard(FX_INT32 iCmd) break; } case 2: { - FX_INT32 nStart; - FX_INT32 nCount = m_pEdtEngine->GetSelRange(0, nStart); + int32_t nStart; + int32_t nCount = m_pEdtEngine->GetSelRange(0, nStart); if (nCount < 1) { break; } @@ -742,7 +742,7 @@ FWL_ERR CFWL_EditImp::DoClipboard(FX_INT32 iCmd) } case 3: { pClipBorder->GetStringData(wsText); - FX_INT32 iLen = wsText.GetLength(); + int32_t iLen = wsText.GetLength(); if (iLen < 0) { break; } @@ -753,7 +753,7 @@ FWL_ERR CFWL_EditImp::DoClipboard(FX_INT32 iCmd) iLen --; wsText = wsText.Left(iLen); } - FX_INT32 nPos = m_pEdtEngine->GetCaretPos(); + int32_t nPos = m_pEdtEngine->GetCaretPos(); m_pEdtEngine->Insert(nPos, wsText, iLen); break; } @@ -765,14 +765,14 @@ FWL_ERR CFWL_EditImp::DoClipboard(FX_INT32 iCmd) FX_BOOL CFWL_EditImp::Copy(CFX_WideString &wsCopy) { _FWL_RETURN_VALUE_IF_FAIL(m_pEdtEngine, FALSE); - FX_INT32 nCount = m_pEdtEngine->CountSelRanges(); + int32_t nCount = m_pEdtEngine->CountSelRanges(); if (nCount == 0) { return FALSE; } wsCopy.Empty(); CFX_WideString wsTemp; - FX_INT32 nStart, nLength; - for (FX_INT32 i = 0; i < nCount; i ++) { + int32_t nStart, nLength; + for (int32_t i = 0; i < nCount; i ++) { nLength = m_pEdtEngine->GetSelRange(i, nStart); m_pEdtEngine->GetText(wsTemp, nStart, nLength); wsCopy += wsTemp; @@ -783,14 +783,14 @@ FX_BOOL CFWL_EditImp::Copy(CFX_WideString &wsCopy) FX_BOOL CFWL_EditImp::Cut(CFX_WideString &wsCut) { _FWL_RETURN_VALUE_IF_FAIL(m_pEdtEngine, FALSE); - FX_INT32 nCount = m_pEdtEngine->CountSelRanges(); + int32_t nCount = m_pEdtEngine->CountSelRanges(); if (nCount == 0) { return FALSE; } wsCut.Empty(); CFX_WideString wsTemp; - FX_INT32 nStart, nLength; - for (FX_INT32 i = 0; i < nCount; i ++) { + int32_t nStart, nLength; + for (int32_t i = 0; i < nCount; i ++) { nLength = m_pEdtEngine->GetSelRange(i, nStart); m_pEdtEngine->GetText(wsTemp, nStart, nLength); wsCut += wsTemp; @@ -802,8 +802,8 @@ FX_BOOL CFWL_EditImp::Cut(CFX_WideString &wsCut) FX_BOOL CFWL_EditImp::Paste(const CFX_WideString &wsPaste) { _FWL_RETURN_VALUE_IF_FAIL(m_pEdtEngine, FALSE); - FX_INT32 nCaret = m_pEdtEngine->GetCaretPos(); - FX_INT32 iError = m_pEdtEngine->Insert(nCaret, FX_LPCWSTR(wsPaste), wsPaste.GetLength()); + int32_t nCaret = m_pEdtEngine->GetCaretPos(); + int32_t iError = m_pEdtEngine->Insert(nCaret, FX_LPCWSTR(wsPaste), wsPaste.GetLength()); if (iError < 0) { ProcessInsertError(iError); return FALSE; @@ -813,7 +813,7 @@ FX_BOOL CFWL_EditImp::Paste(const CFX_WideString &wsPaste) FX_BOOL CFWL_EditImp::Delete() { _FWL_RETURN_VALUE_IF_FAIL(m_pEdtEngine, FALSE); - FX_INT32 nCount = m_pEdtEngine->CountSelRanges(); + int32_t nCount = m_pEdtEngine->CountSelRanges(); if (nCount < 1) { return FALSE; } @@ -873,14 +873,14 @@ FWL_ERR CFWL_EditImp::SetOuter(IFWL_Widget *pOuter) m_pOuter = pOuter; return FWL_ERR_Succeeded; } -FWL_ERR CFWL_EditImp::SetNumberRange(FX_INT32 iMin, FX_INT32 iMax) +FWL_ERR CFWL_EditImp::SetNumberRange(int32_t iMin, int32_t iMax) { m_iMin = iMin; m_iMax = iMax; m_bSetRange = TRUE; return FWL_ERR_Succeeded; } -void CFWL_EditImp::On_CaretChanged(IFDE_TxtEdtEngine *pEdit, FX_INT32 nPage, FX_BOOL bVisible ) +void CFWL_EditImp::On_CaretChanged(IFDE_TxtEdtEngine *pEdit, int32_t nPage, FX_BOOL bVisible ) { if (m_rtEngine.IsEmpty()) { return; @@ -973,7 +973,7 @@ void CFWL_EditImp::On_SelChanged(IFDE_TxtEdtEngine *pEdit) GetClientRect(rtTemp); Repaint(&rtTemp); } -FX_BOOL CFWL_EditImp::On_PageLoad(IFDE_TxtEdtEngine *pEdit, FX_INT32 nPageIndex, FX_INT32 nPurpose) +FX_BOOL CFWL_EditImp::On_PageLoad(IFDE_TxtEdtEngine *pEdit, int32_t nPageIndex, int32_t nPurpose) { IFDE_TxtEdtEngine *pEdtEngine = m_pEdtEngine; IFDE_TxtEdtPage *pPage = pEdtEngine->GetPage(nPageIndex); @@ -981,7 +981,7 @@ FX_BOOL CFWL_EditImp::On_PageLoad(IFDE_TxtEdtEngine *pEdit, FX_INT32 nPageIndex, pPage->LoadPage(); return TRUE; } -FX_BOOL CFWL_EditImp::On_PageUnload(IFDE_TxtEdtEngine *pEdit, FX_INT32 nPageIndex, FX_INT32 nPurpose) +FX_BOOL CFWL_EditImp::On_PageUnload(IFDE_TxtEdtEngine *pEdit, int32_t nPageIndex, int32_t nPurpose) { IFDE_TxtEdtEngine *pEdtEngine = m_pEdtEngine; IFDE_TxtEdtPage *pPage = pEdtEngine->GetPage(nPageIndex); @@ -1001,16 +1001,16 @@ void CFWL_EditImp::On_AddDoRecord(IFDE_TxtEdtEngine *pEdit, FX_BSTR bsDoRecord) evt.m_wsDoRecord = bsDoRecord; m_pDelegate->OnProcessEvent(&evt); } -FX_BOOL CFWL_EditImp::On_ValidateField(IFDE_TxtEdtEngine *pEdit, FX_INT32 nBlockIndex, FX_INT32 nFieldIndex, \ - const CFX_WideString &wsFieldText, FX_INT32 nCharIndex) +FX_BOOL CFWL_EditImp::On_ValidateField(IFDE_TxtEdtEngine *pEdit, int32_t nBlockIndex, int32_t nFieldIndex, \ + const CFX_WideString &wsFieldText, int32_t nCharIndex) { return TRUE; } -FX_BOOL CFWL_EditImp::On_ValidateBlock(IFDE_TxtEdtEngine *pEdit, FX_INT32 nBlockIndex) +FX_BOOL CFWL_EditImp::On_ValidateBlock(IFDE_TxtEdtEngine *pEdit, int32_t nBlockIndex) { return TRUE; } -FX_BOOL CFWL_EditImp::On_GetBlockFormatText(IFDE_TxtEdtEngine *pEdit, FX_INT32 nBlockIndex, CFX_WideString &wsBlockText) +FX_BOOL CFWL_EditImp::On_GetBlockFormatText(IFDE_TxtEdtEngine *pEdit, int32_t nBlockIndex, CFX_WideString &wsBlockText) { return FALSE; } @@ -1100,26 +1100,26 @@ void CFWL_EditImp::DrawContent(CFX_Graphics *pGraphics, IFWL_ThemeProvider *pThe bShowSel = (pForm->GetStates() & FWL_WGTSTATE_Deactivated) != FWL_WGTSTATE_Deactivated; } } - FX_INT32 nSelCount = m_pEdtEngine->CountSelRanges(); + int32_t nSelCount = m_pEdtEngine->CountSelRanges(); if (bShowSel && nSelCount > 0) { - FX_INT32 nPageCharStart = pPage->GetCharStart(); - FX_INT32 nPageCharCount = pPage->GetCharCount(); - FX_INT32 nPageCharEnd = nPageCharStart + nPageCharCount - 1; - FX_INT32 nCharCount; - FX_INT32 nCharStart; + int32_t nPageCharStart = pPage->GetCharStart(); + int32_t nPageCharCount = pPage->GetCharCount(); + int32_t nPageCharEnd = nPageCharStart + nPageCharCount - 1; + int32_t nCharCount; + int32_t nCharStart; CFX_RectFArray rectArr; - FX_INT32 i = 0; + int32_t i = 0; for (i = 0; i < nSelCount; i ++) { nCharCount = m_pEdtEngine->GetSelRange(i, nCharStart); - FX_INT32 nCharEnd = nCharStart + nCharCount - 1; + int32_t nCharEnd = nCharStart + nCharCount - 1; if (nCharEnd < nPageCharStart || nCharStart > nPageCharEnd) { continue; } - FX_INT32 nBgn = FX_MAX(nCharStart, nPageCharStart); - FX_INT32 nEnd = FX_MIN(nCharEnd, nPageCharEnd); + int32_t nBgn = FX_MAX(nCharStart, nPageCharStart); + int32_t nEnd = FX_MIN(nCharEnd, nPageCharEnd); pPage->CalcRangeRectArray(nBgn - nPageCharStart, nEnd - nBgn + 1, rectArr); } - FX_INT32 nCount = rectArr.GetSize(); + int32_t nCount = rectArr.GetSize(); CFX_Path path; path.Create(); for (i = 0; i < nCount; i ++) { @@ -1154,10 +1154,10 @@ void CFWL_EditImp::DrawContent(CFX_Graphics *pGraphics, IFWL_ThemeProvider *pThe pGraphics->RestoreGraphState(); CFX_Path path; path.Create(); - FX_INT32 iLimit = m_nLimit > 0 ? m_nLimit : 1; + int32_t iLimit = m_nLimit > 0 ? m_nLimit : 1; FX_FLOAT fStep = m_rtEngine.width / iLimit; FX_FLOAT fLeft = m_rtEngine.left + 1; - for (FX_INT32 i = 1; i < iLimit; i++) { + for (int32_t i = 1; i < iLimit; i++) { fLeft += fStep; path.AddLine(fLeft, m_rtClient.top, fLeft, m_rtClient.bottom()); } @@ -1276,7 +1276,7 @@ void CFWL_EditImp::UpdateEditParams() _FWL_RETURN_IF_FAIL(pFont); params.pFont = pFont; params.fFontSize = m_fFontSize; - params.nLineCount = (FX_INT32)(params.fPlateHeight / params.fLineSpace); + params.nLineCount = (int32_t)(params.fPlateHeight / params.fLineSpace); if (params.nLineCount <= 0) { params.nLineCount = 1; } @@ -1533,16 +1533,16 @@ FX_BOOL CFWL_EditImp::IsContentHeightOverflow() _FWL_RETURN_VALUE_IF_FAIL(pPage, FALSE); return pPage->GetContentsBox().height > m_rtEngine.height + 1.0f; } -FX_INT32 CFWL_EditImp::AddDoRecord(FX_BSTR bsDoRecord) +int32_t CFWL_EditImp::AddDoRecord(FX_BSTR bsDoRecord) { - FX_INT32 nCount = m_RecordArr.GetSize(); + int32_t nCount = m_RecordArr.GetSize(); if (m_iCurRecord == nCount - 1) { if (nCount == m_iMaxRecord) { m_RecordArr.RemoveAt(0); m_iCurRecord --; } } else { - for (FX_INT32 i = nCount - 1; i > m_iCurRecord; i --) { + for (int32_t i = nCount - 1; i > m_iCurRecord; i --) { m_RecordArr.RemoveAt(i); } } @@ -1731,13 +1731,13 @@ FX_BOOL CFWL_EditImp::ValidateNumberChar(FX_WCHAR cNum) } return TRUE; } - FX_INT32 caretPos = m_pEdtEngine->GetCaretPos(); - FX_INT32 iSel = CountSelRanges(); + int32_t caretPos = m_pEdtEngine->GetCaretPos(); + int32_t iSel = CountSelRanges(); if (iSel == 0) { if (cNum == L'0' && caretPos == 0) { return FALSE; } - FX_INT32 nLen = wsText.GetLength(); + int32_t nLen = wsText.GetLength(); CFX_WideString l = wsText.Mid(0, caretPos); CFX_WideString r = wsText.Mid(caretPos, nLen - caretPos); CFX_WideString wsNew = l + cNum + r; @@ -1770,7 +1770,7 @@ void CFWL_EditImp::ClearRecord() m_iCurRecord = -1; m_RecordArr.RemoveAll(); } -void CFWL_EditImp::ProcessInsertError(FX_INT32 iError) +void CFWL_EditImp::ProcessInsertError(int32_t iError) { switch (iError) { case -2: { @@ -1787,11 +1787,11 @@ CFWL_EditImpDelegate::CFWL_EditImpDelegate(CFWL_EditImp *pOwner) : m_pOwner(pOwner) { } -FX_INT32 CFWL_EditImpDelegate::OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_EditImpDelegate::OnProcessMessage(CFWL_Message *pMessage) { _FWL_RETURN_VALUE_IF_FAIL(pMessage, 0); FX_DWORD dwMsgCode = pMessage->GetClassID(); - FX_INT32 iRet = 1; + int32_t iRet = 1; switch (dwMsgCode) { case FWL_MSGHASH_Activate: { DoActivate((CFWL_MsgActivate*)pMessage); @@ -1895,7 +1895,7 @@ void CFWL_EditImpDelegate::DoButtonDown(CFWL_MsgMouse *pMsg) pt.Set(pMsg->m_fx, pMsg->m_fy); m_pOwner->DeviceToEngine(pt); FX_BOOL bBefore = TRUE; - FX_INT32 nIndex = pPage->GetCharIndex(pt, bBefore); + int32_t nIndex = pPage->GetCharIndex(pt, bBefore); if (nIndex < 0) { nIndex = 0; } @@ -1917,7 +1917,7 @@ void CFWL_EditImpDelegate::OnFocusChanged(CFWL_Message *pMsg, FX_BOOL bSet) m_pOwner->m_pProperties->m_dwStates &= ~FWL_WGTSTATE_Focused; m_pOwner->ShowCaret(FALSE); if (m_pOwner->m_pEdtEngine && (dwStyleEx & FWL_STYLEEXT_EDT_NoHideSel) == 0) { - FX_INT32 nSel = m_pOwner->CountSelRanges(); + int32_t nSel = m_pOwner->CountSelRanges(); if (nSel > 0) { m_pOwner->ClearSelections(); bRepaint = TRUE; @@ -1946,17 +1946,17 @@ void CFWL_EditImpDelegate::OnLButtonDown(CFWL_MsgMouse *pMsg) m_pOwner->m_bLButtonDown = TRUE; m_pOwner->SetGrab(TRUE); DoButtonDown(pMsg); - FX_INT32 nIndex = m_pOwner->m_pEdtEngine->GetCaretPos(); + int32_t nIndex = m_pOwner->m_pEdtEngine->GetCaretPos(); FX_BOOL bRepaint = FALSE; - FX_INT32 iCount = m_pOwner->m_pEdtEngine->CountSelRanges(); + int32_t iCount = m_pOwner->m_pEdtEngine->CountSelRanges(); if (iCount > 0) { m_pOwner->m_pEdtEngine->ClearSelection(); bRepaint = TRUE; } FX_BOOL bShift = pMsg->m_dwFlags & FWL_KEYFLAG_Shift; if (bShift && m_pOwner->m_nSelStart != nIndex) { - FX_INT32 iStart = FX_MIN(m_pOwner->m_nSelStart, nIndex); - FX_INT32 iEnd = FX_MAX(m_pOwner->m_nSelStart, nIndex); + int32_t iStart = FX_MIN(m_pOwner->m_nSelStart, nIndex); + int32_t iEnd = FX_MAX(m_pOwner->m_nSelStart, nIndex); m_pOwner->m_pEdtEngine->AddSelRange(iStart, iEnd - iStart); bRepaint = TRUE; } else { @@ -1981,8 +1981,8 @@ void CFWL_EditImpDelegate::OnButtonDblClk(CFWL_MsgMouse *pMsg) CFX_PointF pt; pt.Set(pMsg->m_fx, pMsg->m_fy); m_pOwner->DeviceToEngine(pt); - FX_INT32 nCount = 0; - FX_INT32 nIndex = pPage->SelectWord(pt, nCount); + int32_t nCount = 0; + int32_t nIndex = pPage->SelectWord(pt, nCount); if (nIndex < 0) { return; } @@ -2003,12 +2003,12 @@ void CFWL_EditImpDelegate::OnMouseMove(CFWL_MsgMouse *pMsg) pt.Set(pMsg->m_fx, pMsg->m_fy); m_pOwner->DeviceToEngine(pt); FX_BOOL bBefore = TRUE; - FX_INT32 nIndex = pPage->GetCharIndex(pt, bBefore); + int32_t nIndex = pPage->GetCharIndex(pt, bBefore); m_pOwner->m_pEdtEngine->SetCaretPos(nIndex, bBefore); nIndex = m_pOwner->m_pEdtEngine->GetCaretPos(); m_pOwner->m_pEdtEngine->ClearSelection(); if (nIndex != m_pOwner->m_nSelStart) { - FX_INT32 nLen = m_pOwner->m_pEdtEngine->GetTextLength(); + int32_t nLen = m_pOwner->m_pEdtEngine->GetTextLength(); if (m_pOwner->m_nSelStart >= nLen) { m_pOwner->m_nSelStart = nLen; } @@ -2063,7 +2063,7 @@ void CFWL_EditImpDelegate::OnKeyDown(CFWL_MsgKey *pMsg) || (m_pOwner->m_pProperties->m_dwStates & FWL_WGTSTATE_Disabled)) { break; } - FX_INT32 nCaret = m_pOwner->m_pEdtEngine->GetCaretPos(); + int32_t nCaret = m_pOwner->m_pEdtEngine->GetCaretPos(); #if (_FX_OS_==_FX_MACOSX_) m_pOwner->m_pEdtEngine->Delete(nCaret, TRUE); #else @@ -2111,9 +2111,9 @@ void CFWL_EditImpDelegate::OnChar(CFWL_MsgKey *pMsg) return; } _FWL_RETURN_IF_FAIL(m_pOwner->m_pEdtEngine); - FX_INT32 iError = 0; + int32_t iError = 0; FX_WCHAR c = (FX_WCHAR)pMsg->m_dwKeyCode; - FX_INT32 nCaret = m_pOwner->m_pEdtEngine->GetCaretPos(); + int32_t nCaret = m_pOwner->m_pEdtEngine->GetCaretPos(); switch (c) { case FWL_VKEY_Back: { m_pOwner->m_pEdtEngine->Delete(nCaret, TRUE); diff --git a/xfa/src/fwl/src/basewidget/fwl_formproxyimp.cpp b/xfa/src/fwl/src/basewidget/fwl_formproxyimp.cpp index ced1fbe6f9..66714fcec7 100644 --- a/xfa/src/fwl/src/basewidget/fwl_formproxyimp.cpp +++ b/xfa/src/fwl/src/basewidget/fwl_formproxyimp.cpp @@ -64,7 +64,7 @@ CFWL_FormProxyImpDelegate::CFWL_FormProxyImpDelegate(CFWL_FormProxyImp *pOwner) : m_pOwner(pOwner) { } -FX_INT32 CFWL_FormProxyImpDelegate::OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_FormProxyImpDelegate::OnProcessMessage(CFWL_Message *pMessage) { IFWL_WidgetDelegate *pDelegate = m_pOwner->m_pOuter->SetDelegate(NULL); return pDelegate->OnProcessMessage(pMessage); diff --git a/xfa/src/fwl/src/basewidget/fwl_listboximp.cpp b/xfa/src/fwl/src/basewidget/fwl_listboximp.cpp index bafb964ee6..8453f43f4b 100644 --- a/xfa/src/fwl/src/basewidget/fwl_listboximp.cpp +++ b/xfa/src/fwl/src/basewidget/fwl_listboximp.cpp @@ -38,15 +38,15 @@ FWL_ERR IFWL_ListBox::Initialize(const CFWL_WidgetImpProperties &properties, IFW ((CFWL_ListBoxImp*)m_pData)->SetInterface(this); return ((CFWL_ListBoxImp*)m_pData)->Initialize(); } -FX_INT32 IFWL_ListBox::CountSelItems() +int32_t IFWL_ListBox::CountSelItems() { return ((CFWL_ListBoxImp*)m_pData)->CountSelItems(); } -FWL_HLISTITEM IFWL_ListBox::GetSelItem(FX_INT32 nIndexSel) +FWL_HLISTITEM IFWL_ListBox::GetSelItem(int32_t nIndexSel) { return ((CFWL_ListBoxImp*)m_pData)->GetSelItem(nIndexSel); } -FX_INT32 IFWL_ListBox::GetSelIndex(FX_INT32 nIndex) +int32_t IFWL_ListBox::GetSelIndex(int32_t nIndex) { return ((CFWL_ListBoxImp*)m_pData)->GetSelIndex(nIndex); } @@ -244,13 +244,13 @@ FWL_ERR CFWL_ListBoxImp::SetThemeProvider(IFWL_ThemeProvider *pThemeProvider) m_pProperties->m_pThemeProvider = pThemeProvider; return FWL_ERR_Succeeded; } -FX_INT32 CFWL_ListBoxImp::CountSelItems() +int32_t CFWL_ListBoxImp::CountSelItems() { _FWL_RETURN_VALUE_IF_FAIL(m_pProperties->m_pDataProvider, 0); - FX_INT32 iRet = 0; + int32_t iRet = 0; IFWL_ListBoxDP *pData = (IFWL_ListBoxDP*)m_pProperties->m_pDataProvider; - FX_INT32 iCount = pData->CountItems(m_pInterface); - for (FX_INT32 i = 0; i < iCount; i ++) { + int32_t iCount = pData->CountItems(m_pInterface); + for (int32_t i = 0; i < iCount; i ++) { FWL_HLISTITEM hItem = pData->GetItem(m_pInterface, i); if (!hItem) { continue; @@ -262,13 +262,13 @@ FX_INT32 CFWL_ListBoxImp::CountSelItems() } return iRet; } -FWL_HLISTITEM CFWL_ListBoxImp::GetSelItem(FX_INT32 nIndexSel) +FWL_HLISTITEM CFWL_ListBoxImp::GetSelItem(int32_t nIndexSel) { _FWL_RETURN_VALUE_IF_FAIL(m_pProperties->m_pDataProvider, NULL); - FX_INT32 index = 0; + int32_t index = 0; IFWL_ListBoxDP *pData = (IFWL_ListBoxDP*)m_pProperties->m_pDataProvider; - FX_INT32 iCount = pData->CountItems(m_pInterface); - for (FX_INT32 i = 0; i < iCount; i ++) { + int32_t iCount = pData->CountItems(m_pInterface); + for (int32_t i = 0; i < iCount; i ++) { FWL_HLISTITEM hItem = pData->GetItem(m_pInterface, i); if (!hItem) { return NULL; @@ -284,13 +284,13 @@ FWL_HLISTITEM CFWL_ListBoxImp::GetSelItem(FX_INT32 nIndexSel) } return NULL; } -FX_INT32 CFWL_ListBoxImp::GetSelIndex(FX_INT32 nIndex) +int32_t CFWL_ListBoxImp::GetSelIndex(int32_t nIndex) { _FWL_RETURN_VALUE_IF_FAIL(m_pProperties->m_pDataProvider, -1); - FX_INT32 index = 0; + int32_t index = 0; IFWL_ListBoxDP *pData = (IFWL_ListBoxDP*)m_pProperties->m_pDataProvider; - FX_INT32 iCount = pData->CountItems(m_pInterface); - for (FX_INT32 i = 0; i < iCount; i ++) { + int32_t iCount = pData->CountItems(m_pInterface); + for (int32_t i = 0; i < iCount; i ++) { FWL_HLISTITEM hItem = pData->GetItem(m_pInterface, i); if (!hItem) { return -1; @@ -346,9 +346,9 @@ FWL_ERR* CFWL_ListBoxImp::Sort(IFWL_ListBoxCompare *pCom) { FWL_HLISTITEM hTemp; IFWL_ListBoxDP *pData = (IFWL_ListBoxDP*)m_pProperties->m_pDataProvider; - FX_INT32 sz = pData->CountItems(m_pInterface); - for (FX_INT32 i = 0; i < sz - 1; i++) { - for (FX_INT32 j = i + 1; j < sz; j++) { + int32_t sz = pData->CountItems(m_pInterface); + for (int32_t i = 0; i < sz - 1; i++) { + for (int32_t j = i + 1; j < sz; j++) { if (pCom->Compare(pData->GetItem(m_pInterface, i), pData->GetItem(m_pInterface, j)) > 0) { hTemp = pData->GetItem(m_pInterface, i); pData->SetItemIndex(m_pInterface, pData->GetItem(m_pInterface, j), i); @@ -371,14 +371,14 @@ FWL_HLISTITEM CFWL_ListBoxImp::GetItem(FWL_HLISTITEM hItem, FX_DWORD dwKeyCode) FX_BOOL bHome = dwKeyCode == FWL_VKEY_Home; FX_BOOL bEnd = dwKeyCode == FWL_VKEY_End; IFWL_ListBoxDP *pData = (IFWL_ListBoxDP*)m_pProperties->m_pDataProvider; - FX_INT32 iDstItem = -1; + int32_t iDstItem = -1; if (bUp || bDown) { - FX_INT32 index = pData->GetItemIndex(m_pInterface, hItem); + int32_t index = pData->GetItemIndex(m_pInterface, hItem); iDstItem = dwKeyCode == FWL_VKEY_Up ? index - 1 : index + 1; } else if (bHome) { iDstItem = 0; } else { - FX_INT32 iCount = pData->CountItems(m_pInterface); + int32_t iCount = pData->CountItems(m_pInterface); iDstItem = iCount - 1; } hRet = pData->GetItem(m_pInterface, iDstItem); @@ -392,16 +392,16 @@ FWL_HLISTITEM CFWL_ListBoxImp::GetItem(FWL_HLISTITEM hItem, FX_DWORD dwKeyCode) void CFWL_ListBoxImp::SetSelection(FWL_HLISTITEM hStart, FWL_HLISTITEM hEnd, FX_BOOL bSelected) { IFWL_ListBoxDP *pData = (IFWL_ListBoxDP*)m_pProperties->m_pDataProvider; - FX_INT32 iStart = pData->GetItemIndex(m_pInterface, hStart); - FX_INT32 iEnd = pData->GetItemIndex(m_pInterface, hEnd); + int32_t iStart = pData->GetItemIndex(m_pInterface, hStart); + int32_t iEnd = pData->GetItemIndex(m_pInterface, hEnd); if (iStart > iEnd) { - FX_INT32 iTemp = iStart; + int32_t iTemp = iStart; iStart = iEnd; iEnd = iTemp; } if (bSelected) { - FX_INT32 iCount = pData->CountItems(m_pInterface); - for (FX_INT32 i = 0; i < iCount; i++ ) { + int32_t iCount = pData->CountItems(m_pInterface); + for (int32_t i = 0; i < iCount; i++ ) { FWL_HLISTITEM hItem = pData->GetItem(m_pInterface, i); SetSelectionDirect(hItem, FALSE); } @@ -429,8 +429,8 @@ void CFWL_ListBoxImp::ClearSelection() { FX_BOOL bMulti = m_pProperties->m_dwStyleExes & FWL_STYLEEXT_LTB_MultiSelection; IFWL_ListBoxDP *pData = (IFWL_ListBoxDP*)m_pProperties->m_pDataProvider; - FX_INT32 iCount = pData->CountItems(m_pInterface); - for (FX_INT32 i = 0; i < iCount; i++ ) { + int32_t iCount = pData->CountItems(m_pInterface); + for (int32_t i = 0; i < iCount; i++ ) { FWL_HLISTITEM hItem = pData->GetItem(m_pInterface, i); FX_DWORD dwState = pData->GetItemStyles(m_pInterface, hItem); FX_BOOL bFindSel = dwState & FWL_ITEMSTATE_LTB_Selected; @@ -450,7 +450,7 @@ void CFWL_ListBoxImp::SelectAll() return; } IFWL_ListBoxDP *pData = (IFWL_ListBoxDP*)m_pProperties->m_pDataProvider; - FX_INT32 iCount = pData->CountItems(m_pInterface); + int32_t iCount = pData->CountItems(m_pInterface); if (iCount > 0) { FWL_HLISTITEM hItemStart = pData->GetItem(m_pInterface, 0); FWL_HLISTITEM hItemEnd = pData->GetItem(m_pInterface, iCount - 1); @@ -460,8 +460,8 @@ void CFWL_ListBoxImp::SelectAll() FWL_HLISTITEM CFWL_ListBoxImp::GetFocusedItem() { IFWL_ListBoxDP *pData = (IFWL_ListBoxDP*)m_pProperties->m_pDataProvider; - FX_INT32 iCount = pData->CountItems(m_pInterface); - for (FX_INT32 i = 0; i < iCount; i++) { + int32_t iCount = pData->CountItems(m_pInterface); + for (int32_t i = 0; i < iCount; i++) { FWL_HLISTITEM hItem = pData->GetItem(m_pInterface, i); _FWL_RETURN_VALUE_IF_FAIL(hItem, NULL); if (pData->GetItemStyles(m_pInterface, hItem) & FWL_ITEMSTATE_LTB_Focused) { @@ -499,8 +499,8 @@ FWL_HLISTITEM CFWL_ListBoxImp::GetItemAtPoint(FX_FLOAT fx, FX_FLOAT fy) fPosY = m_pVertScrollBar->GetPos(); } IFWL_ListBoxDP *pData = (IFWL_ListBoxDP*)m_pProperties->m_pDataProvider; - FX_INT32 nCount = pData->CountItems(m_pInterface); - for (FX_INT32 i = 0; i < nCount; i ++) { + int32_t nCount = pData->CountItems(m_pInterface); + for (int32_t i = 0; i < nCount; i ++) { FWL_HLISTITEM hItem = pData->GetItem(m_pInterface, i); if (!hItem) { continue; @@ -610,8 +610,8 @@ void CFWL_ListBoxImp::DrawItems(CFX_Graphics *pGraphics, IFWL_ThemeProvider *pTh } FX_BOOL bMultiCol = m_pProperties->m_dwStyleExes & FWL_STYLEEXT_LTB_MultiColumn; IFWL_ListBoxDP *pData = (IFWL_ListBoxDP*)m_pProperties->m_pDataProvider; - FX_INT32 iCount = pData->CountItems(m_pInterface); - for (FX_INT32 i = 0; i < iCount; i ++) { + int32_t iCount = pData->CountItems(m_pInterface); + for (int32_t i = 0; i < iCount; i ++) { FWL_HLISTITEM hItem = pData->GetItem(m_pInterface, i); if (!hItem) { continue; @@ -641,7 +641,7 @@ void CFWL_ListBoxImp::DrawItems(CFX_Graphics *pGraphics, IFWL_ThemeProvider *pTh } } } -void CFWL_ListBoxImp::DrawItem(CFX_Graphics *pGraphics, IFWL_ThemeProvider *pTheme, FWL_HLISTITEM hItem, FX_INT32 Index, const CFX_RectF &rtItem, const CFX_Matrix *pMatrix ) +void CFWL_ListBoxImp::DrawItem(CFX_Graphics *pGraphics, IFWL_ThemeProvider *pTheme, FWL_HLISTITEM hItem, int32_t Index, const CFX_RectF &rtItem, const CFX_Matrix *pMatrix ) { IFWL_ListBoxDP *pData = (IFWL_ListBoxDP*)m_pProperties->m_pDataProvider; FX_DWORD dwItemStyles = pData->GetItemStyles(m_pInterface, hItem); @@ -665,7 +665,7 @@ void CFWL_ListBoxImp::DrawItem(CFX_Graphics *pGraphics, IFWL_ThemeProvider *pThe param.m_pGraphics = pGraphics; param.m_matrix.Concat(*pMatrix); param.m_rtPart = rtItem; - param.m_dwData = (FX_DWORD)(FX_UINTPTR)(&itemData); + param.m_dwData = (FX_DWORD)(uintptr_t)(&itemData); CFX_RectF rtFocus(rtItem); param.m_pData = &rtFocus; if (m_pVertScrollBar && !m_pHorzScrollBar && (dwPartStates & FWL_PARTSTATE_LTB_Focused)) { @@ -688,7 +688,7 @@ void CFWL_ListBoxImp::DrawItem(CFX_Graphics *pGraphics, IFWL_ThemeProvider *pThe param.m_pGraphics = pGraphics; param.m_matrix.Concat(*pMatrix); param.m_rtPart = rtDIB; - param.m_dwData = (FX_DWORD)(FX_UINTPTR)(&itemData); + param.m_dwData = (FX_DWORD)(uintptr_t)(&itemData); param.m_pImage = pDib; pTheme->DrawBackground(¶m); } @@ -710,7 +710,7 @@ void CFWL_ListBoxImp::DrawItem(CFX_Graphics *pGraphics, IFWL_ThemeProvider *pThe } param.m_matrix.Concat(*pMatrix); param.m_rtPart = rtCheck; - param.m_dwData = (FX_DWORD)(FX_UINTPTR)(&itemData); + param.m_dwData = (FX_DWORD)(uintptr_t)(&itemData); pTheme->DrawBackground(¶m); } CFX_WideString wsText; @@ -733,7 +733,7 @@ void CFWL_ListBoxImp::DrawItem(CFX_Graphics *pGraphics, IFWL_ThemeProvider *pThe textParam.m_wsText = wsText; textParam.m_dwTTOStyles = m_dwTTOStyles; textParam.m_iTTOAlign = m_iTTOAligns; - textParam.m_dwData = (FX_DWORD)(FX_UINTPTR)(&itemData); + textParam.m_dwData = (FX_DWORD)(uintptr_t)(&itemData); pTheme->DrawText(&textParam); } } @@ -757,8 +757,8 @@ CFX_SizeF CFWL_ListBoxImp::CalcSize(FX_BOOL bAutoSize ) IFWL_ListBoxDP *pData = (IFWL_ListBoxDP*)m_pProperties->m_pDataProvider; if (!bAutoSize) { } - FX_INT32 iCount = pData->CountItems(m_pInterface); - for (FX_INT32 i = 0; i < iCount; i ++) { + int32_t iCount = pData->CountItems(m_pInterface); + for (int32_t i = 0; i < iCount; i ++) { FWL_HLISTITEM hItem = pData->GetItem(m_pInterface, i); CFWL_ThemePart itemPart; itemPart.m_pWidget = m_pInterface; @@ -795,8 +795,8 @@ CFX_SizeF CFWL_ListBoxImp::CalcSize(FX_BOOL bAutoSize ) if (bHasIcon) { fWidth += m_fItemHeight; } - FX_INT32 iCount = pData->CountItems(m_pInterface); - for (FX_INT32 i = 0; i < iCount; i ++) { + int32_t iCount = pData->CountItems(m_pInterface); + for (int32_t i = 0; i < iCount; i ++) { FWL_HLISTITEM htem = pData->GetItem(m_pInterface, i); GetItemSize(fs, htem, fWidth, m_fItemHeight, bAutoSize); } @@ -917,8 +917,8 @@ FX_FLOAT CFWL_ListBoxImp::GetMaxTextWidth() { FX_FLOAT fRet = 0.0f; IFWL_ListBoxDP *pData = (IFWL_ListBoxDP*)m_pProperties->m_pDataProvider; - FX_INT32 iCount = pData->CountItems(m_pInterface); - for (FX_INT32 i = 0; i < iCount; i ++) { + int32_t iCount = pData->CountItems(m_pInterface); + for (int32_t i = 0; i < iCount; i ++) { FWL_HLISTITEM hItem = pData->GetItem(m_pInterface, i); if (!hItem) { continue; @@ -974,8 +974,8 @@ void CFWL_ListBoxImp::ProcessSelChanged() CFWL_EvtLtbSelChanged selEvent; selEvent.m_pSrcTarget = m_pInterface; CFX_Int32Array arrSels; - FX_INT32 iCount = CountSelItems(); - for (FX_INT32 i = 0; i < iCount; i ++) { + int32_t iCount = CountSelItems(); + for (int32_t i = 0; i < iCount; i ++) { FWL_HLISTITEM item = GetSelItem(i); if (item == NULL) { continue; @@ -988,14 +988,14 @@ CFWL_ListBoxImpDelegate::CFWL_ListBoxImpDelegate(CFWL_ListBoxImp *pOwner) : m_pOwner(pOwner) { } -FX_INT32 CFWL_ListBoxImpDelegate::OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_ListBoxImpDelegate::OnProcessMessage(CFWL_Message *pMessage) { _FWL_RETURN_VALUE_IF_FAIL(pMessage, 0); if (!m_pOwner->IsEnabled()) { return 1; } FX_DWORD dwMsgCode = pMessage->GetClassID(); - FX_INT32 iRet = 1; + int32_t iRet = 1; switch (dwMsgCode) { case FWL_MSGHASH_SetFocus: case FWL_MSGHASH_KillFocus: { diff --git a/xfa/src/fwl/src/basewidget/fwl_monthcalendarimp.cpp b/xfa/src/fwl/src/basewidget/fwl_monthcalendarimp.cpp index 39085d6e85..aed47639b2 100644 --- a/xfa/src/fwl/src/basewidget/fwl_monthcalendarimp.cpp +++ b/xfa/src/fwl/src/basewidget/fwl_monthcalendarimp.cpp @@ -44,15 +44,15 @@ FWL_ERR IFWL_MonthCalendar::Initialize(const CFWL_WidgetImpProperties &propertie ((CFWL_MonthCalendarImp*)m_pData)->SetInterface(this); return ((CFWL_MonthCalendarImp*)m_pData)->Initialize(); } -FX_INT32 IFWL_MonthCalendar::CountSelect() +int32_t IFWL_MonthCalendar::CountSelect() { return ((CFWL_MonthCalendarImp*)m_pData)->CountSelect(); } -FX_BOOL IFWL_MonthCalendar::GetSelect(FX_INT32 &iYear, FX_INT32 &iMonth, FX_INT32 &iDay, FX_INT32 nIndex) +FX_BOOL IFWL_MonthCalendar::GetSelect(int32_t &iYear, int32_t &iMonth, int32_t &iDay, int32_t nIndex) { return ((CFWL_MonthCalendarImp*)m_pData)->GetSelect(iYear, iMonth, iDay, nIndex); } -FX_BOOL IFWL_MonthCalendar::SetSelect(FX_INT32 iYear, FX_INT32 iMonth, FX_INT32 iDay) +FX_BOOL IFWL_MonthCalendar::SetSelect(int32_t iYear, int32_t iMonth, int32_t iDay) { return ((CFWL_MonthCalendarImp*)m_pData)->SetSelect(iYear, iMonth, iDay); } @@ -204,11 +204,11 @@ FWL_ERR CFWL_MonthCalendarImp::DrawWidget(CFX_Graphics *pGraphics, const CFX_Mat } return FWL_ERR_Succeeded; } -FX_INT32 CFWL_MonthCalendarImp::CountSelect() +int32_t CFWL_MonthCalendarImp::CountSelect() { return m_arrSelDays.GetSize(); } -FX_BOOL CFWL_MonthCalendarImp::GetSelect(FX_INT32 &iYear, FX_INT32 &iMonth, FX_INT32 &iDay, FX_INT32 nIndex ) +FX_BOOL CFWL_MonthCalendarImp::GetSelect(int32_t &iYear, int32_t &iMonth, int32_t &iDay, int32_t nIndex ) { if (nIndex >= m_arrSelDays.GetSize()) { return FALSE; @@ -218,7 +218,7 @@ FX_BOOL CFWL_MonthCalendarImp::GetSelect(FX_INT32 &iYear, FX_INT32 &iMonth, FX_I iDay = m_arrSelDays[nIndex]; return TRUE; } -FX_BOOL CFWL_MonthCalendarImp::SetSelect(FX_INT32 iYear, FX_INT32 iMonth, FX_INT32 iDay) +FX_BOOL CFWL_MonthCalendarImp::SetSelect(int32_t iYear, int32_t iMonth, int32_t iDay) { ChangeToMonth(iYear, iMonth); return AddSelDay(iDay); @@ -282,8 +282,8 @@ void CFWL_MonthCalendarImp::DrawCaption(CFX_Graphics *pGraphics, IFWL_ThemeProvi textParam.m_iPart = FWL_PART_MCD_Caption; textParam.m_dwStates = FWL_PARTSTATE_MCD_Normal; textParam.m_pGraphics = pGraphics; - FX_INT32 iYear; - FX_INT32 iMonth; + int32_t iYear; + int32_t iMonth; iYear = m_iCurYear; iMonth = m_iCurMonth; CFX_WideString wsCation; @@ -321,8 +321,8 @@ void CFWL_MonthCalendarImp::DrawDatesInBK(CFX_Graphics *pGraphics, IFWL_ThemePro if (pMatrix) { params.m_matrix.Concat(*pMatrix); } - FX_INT32 iCount = m_arrDates.GetSize(); - for (FX_INT32 j = 0; j < iCount; j ++) { + int32_t iCount = m_arrDates.GetSize(); + for (int32_t j = 0; j < iCount; j ++) { LPDATEINFO pDataInfo = (LPDATEINFO)m_arrDates.GetAt(j); if (pDataInfo->dwStates & FWL_ITEMSTATE_MCD_Selected) { params.m_dwStates |= FWL_PARTSTATE_MCD_Selected; @@ -351,7 +351,7 @@ void CFWL_MonthCalendarImp::DrawWeek(CFX_Graphics *pGraphics, IFWL_ThemeProvider params.m_pGraphics = pGraphics; params.m_dwStates = FWL_PARTSTATE_MCD_Normal; params.m_iTTOAlign = FDE_TTOALIGNMENT_Center; - FX_INT32 iWeek; + int32_t iWeek; iWeek = m_pDateTime->GetDayOfWeek(); CFX_RectF rtDayOfWeek; const FX_WCHAR* pWeekDay[] = { @@ -361,7 +361,7 @@ void CFWL_MonthCalendarImp::DrawWeek(CFX_Graphics *pGraphics, IFWL_ThemeProvider if (pMatrix) { params.m_matrix.Concat(*pMatrix); } - for (FX_INT32 i = 0; i < 7; i++) { + for (int32_t i = 0; i < 7; i++) { rtDayOfWeek.Set(m_rtWeek.left + i * (m_szCell.x + MONTHCAL_HMARGIN * 2), m_rtWeek.top, m_szCell.x, @@ -388,13 +388,13 @@ void CFWL_MonthCalendarImp::DrawWeekNumber(CFX_Graphics *pGraphics, IFWL_ThemePr if (pMatrix) { params.m_matrix.Concat(*pMatrix); } - FX_INT32 iWeekNum = 0; - FX_INT32 iMonthNum = m_pDateTime->GetMonth(); - FX_INT32 iDayNum = FX_DaysInMonth(m_iCurYear, iMonthNum); - FX_INT32 iTemp = 0; + int32_t iWeekNum = 0; + int32_t iMonthNum = m_pDateTime->GetMonth(); + int32_t iDayNum = FX_DaysInMonth(m_iCurYear, iMonthNum); + int32_t iTemp = 0; FX_FLOAT fVStartPos = m_rtClient.top + m_fHeadHei + m_fHSepHei; FX_FLOAT fHStartPos = m_rtClient.left; - for (FX_INT32 i = 1; i <= iDayNum; i += 7) { + for (int32_t i = 1; i <= iDayNum; i += 7) { iTemp ++; iWeekNum = CalWeekNumber(m_iCurYear, iMonthNum, i); m_rtWeekNum.Set(fHStartPos, fVStartPos + m_fDateCellHei * iTemp, m_fWeekNumWid, m_fDateCellHei); @@ -453,8 +453,8 @@ void CFWL_MonthCalendarImp::DrawDatesIn(CFX_Graphics *pGraphics, IFWL_ThemeProvi if (pMatrix) { params.m_matrix.Concat(*pMatrix); } - FX_INT32 iCount = m_arrDates.GetSize(); - for (FX_INT32 j = 0; j < iCount; j ++) { + int32_t iCount = m_arrDates.GetSize(); + for (int32_t j = 0; j < iCount; j ++) { LPDATEINFO pDataInfo = (LPDATEINFO)m_arrDates.GetAt(j); params.m_wsText = pDataInfo->wsDay; params.m_rtPart = pDataInfo->rect; @@ -634,11 +634,11 @@ void CFWL_MonthCalendarImp::LayOut() void CFWL_MonthCalendarImp::CalDateItem() { FX_BOOL bNewWeek = FALSE; - FX_INT32 iWeekOfMonth = 0; + int32_t iWeekOfMonth = 0; FX_FLOAT fLeft = m_rtDates.left; FX_FLOAT fTop = m_rtDates.top; - FX_INT32 iCount = m_arrDates.GetSize(); - for (FX_INT32 i = 0; i < iCount; i ++) { + int32_t iCount = m_arrDates.GetSize(); + for (int32_t i = 0; i < iCount; i ++) { LPDATEINFO pDateInfo = (LPDATEINFO)m_arrDates.GetAt(i); if (bNewWeek) { iWeekOfMonth ++; @@ -694,30 +694,30 @@ void CFWL_MonthCalendarImp::GetCapValue() } m_fMCHei = *(FX_FLOAT*)pTheme->GetCapacity(&part, FWL_WGTCAPACITY_MC_HEIGHT); } -FX_INT32 CFWL_MonthCalendarImp::CalWeekNumber(FX_INT32 iYear, FX_INT32 iMonth, FX_INT32 iDay) +int32_t CFWL_MonthCalendarImp::CalWeekNumber(int32_t iYear, int32_t iMonth, int32_t iDay) { return 0; } -FX_BOOL CFWL_MonthCalendarImp::GetMinDate(FX_INT32 &iYear, FX_INT32 &iMonth, FX_INT32 &iDay) +FX_BOOL CFWL_MonthCalendarImp::GetMinDate(int32_t &iYear, int32_t &iMonth, int32_t &iDay) { iYear = m_dtMin.iYear; iMonth = m_dtMin.iMonth; iDay = m_dtMin.iDay; return TRUE; } -FX_BOOL CFWL_MonthCalendarImp::SetMinDate(FX_INT32 iYear, FX_INT32 iMonth, FX_INT32 iDay) +FX_BOOL CFWL_MonthCalendarImp::SetMinDate(int32_t iYear, int32_t iMonth, int32_t iDay) { m_dtMin = DATE(iYear, iMonth, iDay); return TRUE; } -FX_BOOL CFWL_MonthCalendarImp::GetMaxDate(FX_INT32 &iYear, FX_INT32 &iMonth, FX_INT32 &iDay) +FX_BOOL CFWL_MonthCalendarImp::GetMaxDate(int32_t &iYear, int32_t &iMonth, int32_t &iDay) { iYear = m_dtMax.iYear; iMonth = m_dtMax.iMonth; iDay = m_dtMax.iDay; return TRUE; } -FX_BOOL CFWL_MonthCalendarImp::SetMaxDate(FX_INT32 iYear, FX_INT32 iMonth, FX_INT32 iDay) +FX_BOOL CFWL_MonthCalendarImp::SetMaxDate(int32_t iYear, int32_t iMonth, int32_t iDay) { m_dtMax = DATE(iYear, iMonth, iDay); return TRUE; @@ -748,8 +748,8 @@ FX_BOOL CFWL_MonthCalendarImp::InitDate() } void CFWL_MonthCalendarImp::ClearDateItem() { - FX_INT32 iCount = m_arrDates.GetSize(); - for (FX_INT32 i = 0; i < iCount; i ++) { + int32_t iCount = m_arrDates.GetSize(); + for (int32_t i = 0; i < iCount; i ++) { LPDATEINFO pData = (LPDATEINFO)m_arrDates.GetAt(i); delete pData; } @@ -758,9 +758,9 @@ void CFWL_MonthCalendarImp::ClearDateItem() void CFWL_MonthCalendarImp::ReSetDateItem() { m_pDateTime->Set(m_iCurYear, m_iCurMonth, 1); - FX_INT32 iDays = FX_DaysInMonth(m_iCurYear, m_iCurMonth); - FX_INT32 iDayOfWeek = m_pDateTime->GetDayOfWeek(); - for (FX_INT32 i = 0; i < iDays; i ++) { + int32_t iDays = FX_DaysInMonth(m_iCurYear, m_iCurMonth); + int32_t iDayOfWeek = m_pDateTime->GetDayOfWeek(); + for (int32_t i = 0; i < iDays; i ++) { if (iDayOfWeek >= 7) { iDayOfWeek = 0; } @@ -782,7 +782,7 @@ void CFWL_MonthCalendarImp::ReSetDateItem() } FX_BOOL CFWL_MonthCalendarImp::NextMonth() { - FX_INT32 iYear = m_iCurYear, iMonth = m_iCurMonth; + int32_t iYear = m_iCurYear, iMonth = m_iCurMonth; if (iMonth >= 12) { iMonth = 1; iYear++; @@ -799,7 +799,7 @@ FX_BOOL CFWL_MonthCalendarImp::NextMonth() } FX_BOOL CFWL_MonthCalendarImp::PrevMonth() { - FX_INT32 iYear = m_iCurYear, iMonth = m_iCurMonth; + int32_t iYear = m_iCurYear, iMonth = m_iCurMonth; if (iMonth <= 1) { iMonth = 12; iYear --; @@ -814,7 +814,7 @@ FX_BOOL CFWL_MonthCalendarImp::PrevMonth() ChangeToMonth(m_iCurYear, m_iCurMonth); return TRUE; } -void CFWL_MonthCalendarImp::ChangeToMonth(FX_INT32 iYear, FX_INT32 iMonth) +void CFWL_MonthCalendarImp::ChangeToMonth(int32_t iYear, int32_t iMonth) { m_iCurYear = iYear; m_iCurMonth = iMonth; @@ -824,16 +824,16 @@ void CFWL_MonthCalendarImp::ChangeToMonth(FX_INT32 iYear, FX_INT32 iMonth) CalDateItem(); GetHeadText(m_iCurYear, m_iCurMonth, m_wsHead); } -FX_BOOL CFWL_MonthCalendarImp::RemoveSelDay(FX_INT32 iDay, FX_BOOL bAll) +FX_BOOL CFWL_MonthCalendarImp::RemoveSelDay(int32_t iDay, FX_BOOL bAll) { if (iDay == -1 && !bAll) { return FALSE; } if (bAll) { - FX_INT32 iCount = m_arrSelDays.GetSize(); - FX_INT32 iDatesCount = m_arrDates.GetSize(); - for (FX_INT32 i = 0; i < iCount; i ++) { - FX_INT32 iSelDay = m_arrSelDays.GetAt(i); + int32_t iCount = m_arrSelDays.GetSize(); + int32_t iDatesCount = m_arrDates.GetSize(); + for (int32_t i = 0; i < iCount; i ++) { + int32_t iSelDay = m_arrSelDays.GetAt(i); if (iSelDay <= iDatesCount) { LPDATEINFO pDateInfo = (LPDATEINFO)m_arrDates.GetAt(iSelDay - 1); pDateInfo->dwStates &= ~FWL_ITEMSTATE_MCD_Selected; @@ -841,12 +841,12 @@ FX_BOOL CFWL_MonthCalendarImp::RemoveSelDay(FX_INT32 iDay, FX_BOOL bAll) } m_arrSelDays.RemoveAll(); } else { - FX_INT32 index = m_arrSelDays.Find(iDay); + int32_t index = m_arrSelDays.Find(iDay); if (index == -1) { return FALSE; } - FX_INT32 iSelDay = m_arrSelDays.GetAt(iDay); - FX_INT32 iDatesCount = m_arrDates.GetSize(); + int32_t iSelDay = m_arrSelDays.GetAt(iDay); + int32_t iDatesCount = m_arrDates.GetSize(); if (iSelDay <= iDatesCount) { LPDATEINFO pDateInfo = (LPDATEINFO)m_arrDates.GetAt(iSelDay - 1); pDateInfo->dwStates &= ~FWL_ITEMSTATE_MCD_Selected; @@ -855,7 +855,7 @@ FX_BOOL CFWL_MonthCalendarImp::RemoveSelDay(FX_INT32 iDay, FX_BOOL bAll) } return TRUE; } -FX_BOOL CFWL_MonthCalendarImp::AddSelDay(FX_INT32 iDay) +FX_BOOL CFWL_MonthCalendarImp::AddSelDay(int32_t iDay) { FXSYS_assert(iDay > 0); if (m_pProperties->m_dwStyleExes & FWL_STYLEEXT_MCD_MultiSelect) { @@ -885,7 +885,7 @@ FX_BOOL CFWL_MonthCalendarImp::JumpToToday() } return TRUE; } -void CFWL_MonthCalendarImp::GetHeadText(FX_INT32 iYear, FX_INT32 iMonth, CFX_WideString &wsHead) +void CFWL_MonthCalendarImp::GetHeadText(int32_t iYear, int32_t iMonth, CFX_WideString &wsHead) { FXSYS_assert(iMonth > 0 && iMonth < 13); static FX_LPWSTR pMonth[] = { @@ -904,14 +904,14 @@ void CFWL_MonthCalendarImp::GetHeadText(FX_INT32 iYear, FX_INT32 iMonth, CFX_Wid }; wsHead.Format(FX_LPCWSTR(L"%s, %d"), pMonth[iMonth - 1], iYear); } -void CFWL_MonthCalendarImp::GetTodayText(FX_INT32 iYear, FX_INT32 iMonth, FX_INT32 iDay, CFX_WideString &wsToday) +void CFWL_MonthCalendarImp::GetTodayText(int32_t iYear, int32_t iMonth, int32_t iDay, CFX_WideString &wsToday) { wsToday.Format(FX_LPCWSTR(L", %d/%d/%d"), iDay, iMonth, iYear); } -FX_INT32 CFWL_MonthCalendarImp::GetDayAtPoint(FX_FLOAT x, FX_FLOAT y) +int32_t CFWL_MonthCalendarImp::GetDayAtPoint(FX_FLOAT x, FX_FLOAT y) { - FX_INT32 iCount = m_arrDates.GetSize(); - for (FX_INT32 i = 0; i < iCount; i++) { + int32_t iCount = m_arrDates.GetSize(); + for (int32_t i = 0; i < iCount; i++) { LPDATEINFO pDateInfo = (LPDATEINFO)m_arrDates.GetAt(i); if (pDateInfo->rect.Contains(x, y)) { return ++i; @@ -919,7 +919,7 @@ FX_INT32 CFWL_MonthCalendarImp::GetDayAtPoint(FX_FLOAT x, FX_FLOAT y) } return -1; } -FX_BOOL CFWL_MonthCalendarImp::GetDayRect(FX_INT32 iDay, CFX_RectF &rtDay) +FX_BOOL CFWL_MonthCalendarImp::GetDayRect(int32_t iDay, CFX_RectF &rtDay) { if (iDay <= 0 || iDay > m_arrDates.GetSize()) { return FALSE; @@ -933,11 +933,11 @@ CFWL_MonthCalendarImpDelegate::CFWL_MonthCalendarImpDelegate(CFWL_MonthCalendarI : m_pOwner(pOwner) { } -FX_INT32 CFWL_MonthCalendarImpDelegate::OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_MonthCalendarImpDelegate::OnProcessMessage(CFWL_Message *pMessage) { _FWL_RETURN_VALUE_IF_FAIL(pMessage, 0); FX_DWORD dwMsgCode = pMessage->GetClassID(); - FX_INT32 iRet = 1; + int32_t iRet = 1; switch (dwMsgCode) { case FWL_MSGHASH_SetFocus: case FWL_MSGHASH_KillFocus: { @@ -1016,13 +1016,13 @@ void CFWL_MonthCalendarImpDelegate::OnLButtonDown(CFWL_MsgMouse *pMsg) } else { if (m_pOwner->m_pProperties->m_dwStyleExes & FWL_STYLEEXT_MCD_MultiSelect) { } else { - FX_INT32 iOldSel = 0; + int32_t iOldSel = 0; if (m_pOwner->m_arrSelDays.GetSize() > 0) { iOldSel = m_pOwner->m_arrSelDays[0]; } else { return; } - FX_INT32 iCurSel = m_pOwner->GetDayAtPoint(pMsg->m_fx, pMsg->m_fy); + int32_t iCurSel = m_pOwner->GetDayAtPoint(pMsg->m_fx, pMsg->m_fy); FX_BOOL bSelChanged = iCurSel > 0 && iCurSel != iOldSel; if (bSelChanged) { LPDATEINFO lpDatesInfo = (LPDATEINFO)m_pOwner->m_arrDates.GetAt(iCurSel - 1); @@ -1056,7 +1056,7 @@ void CFWL_MonthCalendarImpDelegate::OnLButtonUp(CFWL_MsgMouse *pMsg) m_pOwner->m_iRBtnPartStates = 0; m_pOwner->Repaint(&m_pOwner->m_rtRBtn); } else if (m_pOwner->m_rtDates.Contains(pMsg->m_fx, pMsg->m_fy)) { - FX_INT32 iDay = m_pOwner->GetDayAtPoint(pMsg->m_fx, pMsg->m_fy); + int32_t iDay = m_pOwner->GetDayAtPoint(pMsg->m_fx, pMsg->m_fy); if (iDay != -1) { m_pOwner->AddSelDay(iDay); } @@ -1071,7 +1071,7 @@ void CFWL_MonthCalendarImpDelegate::OnMouseMove(CFWL_MsgMouse *pMsg) CFX_RectF rtInvalidate; rtInvalidate.Set(0, 0, 0, 0); if (m_pOwner->m_rtDates.Contains(pMsg->m_fx, pMsg->m_fy)) { - FX_INT32 iHover = m_pOwner->GetDayAtPoint(pMsg->m_fx, pMsg->m_fy); + int32_t iHover = m_pOwner->GetDayAtPoint(pMsg->m_fx, pMsg->m_fy); bRepaint = m_pOwner->m_iHovered != iHover; if (bRepaint) { if (m_pOwner->m_iHovered > 0) { diff --git a/xfa/src/fwl/src/basewidget/fwl_pushbuttonimp.cpp b/xfa/src/fwl/src/basewidget/fwl_pushbuttonimp.cpp index b3228e41f2..364e497123 100644 --- a/xfa/src/fwl/src/basewidget/fwl_pushbuttonimp.cpp +++ b/xfa/src/fwl/src/basewidget/fwl_pushbuttonimp.cpp @@ -92,7 +92,7 @@ FWL_ERR CFWL_PushButtonImp::GetWidgetRect(CFX_RectF &rect, FX_BOOL bAutoSize ) if (pData) { pData->GetCaption(m_pInterface, wsCaption); } - FX_INT32 iLen = wsCaption.GetLength(); + int32_t iLen = wsCaption.GetLength(); if (iLen > 0) { CFX_SizeF sz = CalcTextSize(wsCaption, m_pProperties->m_pThemeProvider); rect.Set(0, 0, sz.x, sz.y); @@ -382,13 +382,13 @@ CFWL_PushButtonImpDelegate::CFWL_PushButtonImpDelegate(CFWL_PushButtonImp *pOwne : m_pOwner(pOwner) { } -FX_INT32 CFWL_PushButtonImpDelegate::OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_PushButtonImpDelegate::OnProcessMessage(CFWL_Message *pMessage) { _FWL_RETURN_VALUE_IF_FAIL(pMessage, 0); if (!m_pOwner->IsEnabled()) { return 1; } - FX_INT32 iRet = 1; + int32_t iRet = 1; FX_DWORD dwMsgCode = pMessage->GetClassID(); switch (dwMsgCode) { case FWL_MSGHASH_SetFocus: diff --git a/xfa/src/fwl/src/basewidget/fwl_scrollbarimp.cpp b/xfa/src/fwl/src/basewidget/fwl_scrollbarimp.cpp index 8162c9d9e8..7b3e43f6e5 100644 --- a/xfa/src/fwl/src/basewidget/fwl_scrollbarimp.cpp +++ b/xfa/src/fwl/src/basewidget/fwl_scrollbarimp.cpp @@ -302,7 +302,7 @@ FX_BOOL CFWL_ScrollBarImp::DoScroll(FX_DWORD dwCode, FX_FLOAT fPos ) } return OnScroll(dwCode, fPos); } -FX_INT32 CFWL_ScrollBarImp::Run(FWL_HTIMER hTimer) +int32_t CFWL_ScrollBarImp::Run(FWL_HTIMER hTimer) { if (m_hTimer) { FWL_StopTimer(m_hTimer); @@ -693,10 +693,10 @@ CFWL_ScrollBarImpDelegate::CFWL_ScrollBarImpDelegate(CFWL_ScrollBarImp *pOwner) : m_pOwner(pOwner) { } -FX_INT32 CFWL_ScrollBarImpDelegate::OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_ScrollBarImpDelegate::OnProcessMessage(CFWL_Message *pMessage) { _FWL_RETURN_VALUE_IF_FAIL(pMessage, 0); - FX_INT32 iRet = 1; + int32_t iRet = 1; FX_DWORD dwMsgCode = pMessage->GetClassID(); if (dwMsgCode == FWL_MSGHASH_Mouse) { CFWL_MsgMouse *pMsg = (CFWL_MsgMouse*)pMessage; @@ -794,11 +794,11 @@ void CFWL_ScrollBarImpDelegate::OnMouseLeave() } void CFWL_ScrollBarImpDelegate::OnMouseWheel(FX_FLOAT fx, FX_FLOAT fy, FX_DWORD dwFlags, FX_FLOAT fDeltaX, FX_FLOAT fDeltaY) { - m_pOwner->m_iMouseWheel = (FX_INT32)fDeltaX; + m_pOwner->m_iMouseWheel = (int32_t)fDeltaX; m_pOwner->SendEvent(); m_pOwner->m_iMouseWheel = 0; } -void CFWL_ScrollBarImpDelegate::DoMouseDown(FX_INT32 iItem, const CFX_RectF &rtItem, FX_INT32 &iState, FX_FLOAT fx, FX_FLOAT fy) +void CFWL_ScrollBarImpDelegate::DoMouseDown(int32_t iItem, const CFX_RectF &rtItem, int32_t &iState, FX_FLOAT fx, FX_FLOAT fy) { if (!rtItem.Contains(fx, fy)) { return; @@ -809,9 +809,9 @@ void CFWL_ScrollBarImpDelegate::DoMouseDown(FX_INT32 iItem, const CFX_RectF &rtI iState = FWL_PARTSTATE_SCB_Pressed; m_pOwner->Repaint(&rtItem); } -void CFWL_ScrollBarImpDelegate::DoMouseUp(FX_INT32 iItem, const CFX_RectF &rtItem, FX_INT32 &iState, FX_FLOAT fx, FX_FLOAT fy) +void CFWL_ScrollBarImpDelegate::DoMouseUp(int32_t iItem, const CFX_RectF &rtItem, int32_t &iState, FX_FLOAT fx, FX_FLOAT fy) { - FX_INT32 iNewState = rtItem.Contains(fx, fy) ? FWL_PARTSTATE_SCB_Hovered : FWL_PARTSTATE_SCB_Normal; + int32_t iNewState = rtItem.Contains(fx, fy) ? FWL_PARTSTATE_SCB_Hovered : FWL_PARTSTATE_SCB_Normal; if (iState == iNewState) { return; } @@ -819,10 +819,10 @@ void CFWL_ScrollBarImpDelegate::DoMouseUp(FX_INT32 iItem, const CFX_RectF &rtIte m_pOwner->Repaint(&rtItem); m_pOwner->OnScroll(FWL_SCBCODE_EndScroll, m_pOwner->m_fTrackPos); } -void CFWL_ScrollBarImpDelegate::DoMouseMove(FX_INT32 iItem, const CFX_RectF &rtItem, FX_INT32 &iState, FX_FLOAT fx, FX_FLOAT fy) +void CFWL_ScrollBarImpDelegate::DoMouseMove(int32_t iItem, const CFX_RectF &rtItem, int32_t &iState, FX_FLOAT fx, FX_FLOAT fy) { if (!m_pOwner->m_bMouseDown) { - FX_INT32 iNewState = rtItem.Contains(fx, fy) ? FWL_PARTSTATE_SCB_Hovered : FWL_PARTSTATE_SCB_Normal; + int32_t iNewState = rtItem.Contains(fx, fy) ? FWL_PARTSTATE_SCB_Hovered : FWL_PARTSTATE_SCB_Normal; if (iState == iNewState) { return; } @@ -834,7 +834,7 @@ void CFWL_ScrollBarImpDelegate::DoMouseMove(FX_INT32 iItem, const CFX_RectF &rtI m_pOwner->OnScroll(FWL_SCBCODE_TrackPos, fPos); } } -void CFWL_ScrollBarImpDelegate::DoMouseLeave(FX_INT32 iItem, const CFX_RectF &rtItem, FX_INT32 &iState) +void CFWL_ScrollBarImpDelegate::DoMouseLeave(int32_t iItem, const CFX_RectF &rtItem, int32_t &iState) { if (iState == FWL_PARTSTATE_SCB_Normal) { return; @@ -842,7 +842,7 @@ void CFWL_ScrollBarImpDelegate::DoMouseLeave(FX_INT32 iItem, const CFX_RectF &rt iState = FWL_PARTSTATE_SCB_Normal; m_pOwner->Repaint(&rtItem); } -void CFWL_ScrollBarImpDelegate::DoMouseHover(FX_INT32 iItem, const CFX_RectF &rtItem, FX_INT32 &iState) +void CFWL_ScrollBarImpDelegate::DoMouseHover(int32_t iItem, const CFX_RectF &rtItem, int32_t &iState) { if (iState == FWL_PARTSTATE_SCB_Hovered) { return; diff --git a/xfa/src/fwl/src/basewidget/fwl_spinbuttonimp.cpp b/xfa/src/fwl/src/basewidget/fwl_spinbuttonimp.cpp index f5f56955fa..c8be73228b 100644 --- a/xfa/src/fwl/src/basewidget/fwl_spinbuttonimp.cpp +++ b/xfa/src/fwl/src/basewidget/fwl_spinbuttonimp.cpp @@ -165,7 +165,7 @@ FWL_ERR CFWL_SpinButtonImp::DrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix DrawDownButton(pGraphics, pTheme, pMatrix); return FWL_ERR_Succeeded; } -FX_INT32 CFWL_SpinButtonImp::Run(FWL_HTIMER hTimer) +int32_t CFWL_SpinButtonImp::Run(FWL_HTIMER hTimer) { if (m_hTimer) { CFWL_EvtSpbClick wmPosChanged; @@ -229,10 +229,10 @@ CFWL_SpinButtonImpDelegate::CFWL_SpinButtonImpDelegate(CFWL_SpinButtonImp *pOwne : m_pOwner(pOwner) { } -FX_INT32 CFWL_SpinButtonImpDelegate::OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_SpinButtonImpDelegate::OnProcessMessage(CFWL_Message *pMessage) { _FWL_RETURN_VALUE_IF_FAIL(pMessage, 0); - FX_INT32 iRet = 1; + int32_t iRet = 1; FX_DWORD dwMsgCode = pMessage->GetClassID(); switch (dwMsgCode) { case FWL_MSGHASH_SetFocus: diff --git a/xfa/src/fwl/src/basewidget/fwl_tooltipctrlimp.cpp b/xfa/src/fwl/src/basewidget/fwl_tooltipctrlimp.cpp index 157d2fff73..920bcb73e1 100644 --- a/xfa/src/fwl/src/basewidget/fwl_tooltipctrlimp.cpp +++ b/xfa/src/fwl/src/basewidget/fwl_tooltipctrlimp.cpp @@ -124,7 +124,7 @@ FWL_ERR CFWL_ToolTipImp::GetWidgetRect(CFX_RectF &rect, FX_BOOL bAutoSize ) if (pData) { pData->GetCaption(m_pInterface, wsCaption); } - FX_INT32 iLen = wsCaption.GetLength(); + int32_t iLen = wsCaption.GetLength(); if (iLen > 0) { CFX_SizeF sz = CalcTextSize(wsCaption, m_pProperties->m_pThemeProvider); rect.Set(0, 0, sz.x, sz.y); @@ -240,7 +240,7 @@ FWL_ERR CFWL_ToolTipImp::SetAnchor(const CFX_RectF &rtAnchor) FWL_ERR CFWL_ToolTipImp::Show() { IFWL_ToolTipDP *pData = (IFWL_ToolTipDP*)m_pProperties->m_pDataProvider; - FX_INT32 nInitDelay = pData->GetInitialDelay(m_pInterface); + int32_t nInitDelay = pData->GetInitialDelay(m_pInterface); if ((m_pProperties->m_dwStates & FWL_WGTSTATE_Invisible)) { m_hTimerShow = FWL_StartTimer( &m_TimerShow, nInitDelay, FALSE); } @@ -263,7 +263,7 @@ FWL_ERR CFWL_ToolTipImp::SetStates(FX_DWORD dwStates, FX_BOOL bSet ) { if ( (dwStates & FWL_WGTSTATE_Invisible) && !bSet) { IFWL_ToolTipDP *pData = (IFWL_ToolTipDP*)m_pProperties->m_pDataProvider; - FX_INT32 nAutoPopDelay = pData->GetAutoPopDelay(m_pInterface); + int32_t nAutoPopDelay = pData->GetAutoPopDelay(m_pInterface); m_hTimerHide = FWL_StartTimer( &m_TimerHide, nAutoPopDelay, FALSE); } return CFWL_WidgetImp::SetStates(dwStates, bSet); @@ -301,7 +301,7 @@ CFWL_ToolTipImp::CFWL_ToolTipTimer::CFWL_ToolTipTimer(CFWL_ToolTipImp * pToolTip : m_pToolTip(pToolTip) { } -FX_INT32 CFWL_ToolTipImp::CFWL_ToolTipTimer::Run(FWL_HTIMER hTimer) +int32_t CFWL_ToolTipImp::CFWL_ToolTipTimer::Run(FWL_HTIMER hTimer) { if (m_pToolTip->m_hTimerShow == hTimer && m_pToolTip->m_hTimerShow) { if (m_pToolTip->GetStates() & FWL_WGTSTATE_Invisible) { @@ -324,7 +324,7 @@ CFWL_ToolTipImpDelegate::CFWL_ToolTipImpDelegate(CFWL_ToolTipImp *pOwner) : m_pOwner(pOwner) { } -FX_INT32 CFWL_ToolTipImpDelegate::OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_ToolTipImpDelegate::OnProcessMessage(CFWL_Message *pMessage) { return CFWL_WidgetImpDelegate::OnProcessMessage(pMessage); } diff --git a/xfa/src/fwl/src/basewidget/fxmath_barcodeimp.cpp b/xfa/src/fwl/src/basewidget/fxmath_barcodeimp.cpp index c56932b4fa..7996a882f5 100644 --- a/xfa/src/fwl/src/basewidget/fxmath_barcodeimp.cpp +++ b/xfa/src/fwl/src/basewidget/fxmath_barcodeimp.cpp @@ -63,19 +63,19 @@ FX_BOOL CFX_Barcode::SetCharEncoding(BC_CHAR_ENCODING encoding) { return m_pBCEngine ? m_pBCEngine->SetCharEncoding(encoding) : FALSE; } -FX_BOOL CFX_Barcode::SetModuleHeight(FX_INT32 moduleHeight) +FX_BOOL CFX_Barcode::SetModuleHeight(int32_t moduleHeight) { return m_pBCEngine ? m_pBCEngine->SetModuleHeight(moduleHeight) : FALSE; } -FX_BOOL CFX_Barcode::SetModuleWidth(FX_INT32 moduleWidth) +FX_BOOL CFX_Barcode::SetModuleWidth(int32_t moduleWidth) { return m_pBCEngine ? m_pBCEngine->SetModuleWidth(moduleWidth) : FALSE; } -FX_BOOL CFX_Barcode::SetHeight(FX_INT32 height) +FX_BOOL CFX_Barcode::SetHeight(int32_t height) { return m_pBCEngine ? m_pBCEngine->SetHeight(height) : FALSE; } -FX_BOOL CFX_Barcode::SetWidth(FX_INT32 width) +FX_BOOL CFX_Barcode::SetWidth(int32_t width) { return m_pBCEngine ? m_pBCEngine->SetWidth(width) : FALSE; } @@ -113,7 +113,7 @@ FX_BOOL CFX_Barcode::SetPrintChecksum(FX_BOOL checksum) return FALSE; } } -FX_BOOL CFX_Barcode::SetDataLength(FX_INT32 length) +FX_BOOL CFX_Barcode::SetDataLength(int32_t length) { switch(GetType()) { case BC_CODE39: @@ -130,7 +130,7 @@ FX_BOOL CFX_Barcode::SetDataLength(FX_INT32 length) return FALSE; } } -FX_BOOL CFX_Barcode::SetCalChecksum(FX_INT32 state) +FX_BOOL CFX_Barcode::SetCalChecksum(int32_t state) { switch(GetType()) { case BC_CODE39: @@ -181,7 +181,7 @@ FX_BOOL CFX_Barcode::SetFontSize(FX_FLOAT size) return FALSE; } } -FX_BOOL CFX_Barcode::SetFontStyle(FX_INT32 style) +FX_BOOL CFX_Barcode::SetFontStyle(int32_t style) { switch(GetType()) { case BC_CODE39: @@ -237,9 +237,9 @@ FX_BOOL CFX_Barcode::SetTextLocation(BC_TEXT_LOC location) return m_pBCEngine && memptr ? (m_pBCEngine->*memptr)(location) : FALSE; } -FX_BOOL CFX_Barcode::SetWideNarrowRatio(FX_INT32 ratio) +FX_BOOL CFX_Barcode::SetWideNarrowRatio(int32_t ratio) { - typedef FX_BOOL (CBC_CodeBase::*memptrtype)(FX_INT32); + typedef FX_BOOL (CBC_CodeBase::*memptrtype)(int32_t); memptrtype memptr = NULL; switch(GetType()) { case BC_CODE39: @@ -282,9 +282,9 @@ FX_BOOL CFX_Barcode::SetEndChar(FX_CHAR end) return m_pBCEngine && memptr ? (m_pBCEngine->*memptr)(end) : FALSE; } -FX_BOOL CFX_Barcode::SetVersion(FX_INT32 version) +FX_BOOL CFX_Barcode::SetVersion(int32_t version) { - typedef FX_BOOL (CBC_CodeBase::*memptrtype)(FX_INT32); + typedef FX_BOOL (CBC_CodeBase::*memptrtype)(int32_t); memptrtype memptr = NULL; switch(GetType()) { case BC_QR_CODE: @@ -296,9 +296,9 @@ FX_BOOL CFX_Barcode::SetVersion(FX_INT32 version) return m_pBCEngine && memptr ? (m_pBCEngine->*memptr)(version) : FALSE; } -FX_BOOL CFX_Barcode::SetErrorCorrectionLevel(FX_INT32 level) +FX_BOOL CFX_Barcode::SetErrorCorrectionLevel(int32_t level) { - typedef FX_BOOL (CBC_CodeBase::*memptrtype)(FX_INT32); + typedef FX_BOOL (CBC_CodeBase::*memptrtype)(int32_t); memptrtype memptr = NULL; switch(GetType()) { case BC_QR_CODE: @@ -336,21 +336,21 @@ FX_BOOL CFX_Barcode::SetTruncated(FX_BOOL truncated) #ifndef BCExceptionUnSupportedBarcode #define BCExceptionUnSupportedBarcode 18 #endif -FX_BOOL CFX_Barcode::Encode(FX_WSTR contents, FX_BOOL isDevice, FX_INT32 &e) +FX_BOOL CFX_Barcode::Encode(FX_WSTR contents, FX_BOOL isDevice, int32_t &e) { if(!m_pBCEngine) { return FALSE; } return m_pBCEngine->Encode(contents, isDevice, e); } -FX_BOOL CFX_Barcode::RenderDevice(CFX_RenderDevice* device, const CFX_Matrix* matirx, FX_INT32 &e) +FX_BOOL CFX_Barcode::RenderDevice(CFX_RenderDevice* device, const CFX_Matrix* matirx, int32_t &e) { if (!m_pBCEngine) { return FALSE; } return m_pBCEngine->RenderDevice(device, matirx, e); } -FX_BOOL CFX_Barcode::RenderBitmap(CFX_DIBitmap *&pOutBitmap, FX_INT32 &e) +FX_BOOL CFX_Barcode::RenderBitmap(CFX_DIBitmap *&pOutBitmap, int32_t &e) { if (!m_pBCEngine) { return FALSE; @@ -359,9 +359,9 @@ FX_BOOL CFX_Barcode::RenderBitmap(CFX_DIBitmap *&pOutBitmap, FX_INT32 &e) } #define BC_TYPE_MIN BC_CODE39 #define BC_TYPE_MAX BC_DATAMATRIX -CFX_WideString CFX_Barcode::Decode(FX_BYTE* buf, FX_INT32 width, FX_INT32 height, FX_INT32 &errorCode) +CFX_WideString CFX_Barcode::Decode(uint8_t* buf, int32_t width, int32_t height, int32_t &errorCode) { - for(BC_TYPE t = BC_TYPE_MIN; t <= BC_TYPE_MAX; t = (BC_TYPE)((FX_INT32)t + 1)) { + for(BC_TYPE t = BC_TYPE_MIN; t <= BC_TYPE_MAX; t = (BC_TYPE)((int32_t)t + 1)) { CBC_CodeBase* pTmpEngine = FX_Barcode_CreateBarCodeEngineObject(t); if(!pTmpEngine) { continue; @@ -374,9 +374,9 @@ CFX_WideString CFX_Barcode::Decode(FX_BYTE* buf, FX_INT32 width, FX_INT32 height errorCode = BCExceptionUnSupportedBarcode; return CFX_WideString(); } -CFX_WideString CFX_Barcode::Decode(CFX_DIBitmap *pBitmap, FX_INT32 &errorCode) +CFX_WideString CFX_Barcode::Decode(CFX_DIBitmap *pBitmap, int32_t &errorCode) { - for(BC_TYPE t = BC_TYPE_MIN; t <= BC_TYPE_MAX; t = (BC_TYPE)((FX_INT32)t + 1)) { + for(BC_TYPE t = BC_TYPE_MIN; t <= BC_TYPE_MAX; t = (BC_TYPE)((int32_t)t + 1)) { CBC_CodeBase* pTmpEngine = FX_Barcode_CreateBarCodeEngineObject(t); if(!pTmpEngine) { continue; diff --git a/xfa/src/fwl/src/basewidget/include/fwl_caretimp.h b/xfa/src/fwl/src/basewidget/include/fwl_caretimp.h index 673c720841..f4d090acb4 100644 --- a/xfa/src/fwl/src/basewidget/include/fwl_caretimp.h +++ b/xfa/src/fwl/src/basewidget/include/fwl_caretimp.h @@ -37,7 +37,7 @@ protected: { public: CFWL_CaretTimer(CFWL_CaretImp *m_pCaret); - virtual FX_INT32 Run(FWL_HTIMER hTimer); + virtual int32_t Run(FWL_HTIMER hTimer); CFWL_CaretImp *m_pCaret; }; @@ -54,7 +54,7 @@ class CFWL_CaretImpDelegate : public CFWL_WidgetImpDelegate { public: CFWL_CaretImpDelegate(CFWL_CaretImp *pOwner); - virtual FX_INT32 OnProcessMessage(CFWL_Message *pMessage); + virtual int32_t OnProcessMessage(CFWL_Message *pMessage); virtual FWL_ERR OnDrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); protected: diff --git a/xfa/src/fwl/src/basewidget/include/fwl_checkboximp.h b/xfa/src/fwl/src/basewidget/include/fwl_checkboximp.h index 0e538f32d6..490202dc9a 100644 --- a/xfa/src/fwl/src/basewidget/include/fwl_checkboximp.h +++ b/xfa/src/fwl/src/basewidget/include/fwl_checkboximp.h @@ -25,8 +25,8 @@ public: virtual FWL_ERR GetWidgetRect(CFX_RectF &rect, FX_BOOL bAutoSize = FALSE); virtual FWL_ERR Update(); virtual FWL_ERR DrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); - virtual FX_INT32 GetCheckState(); - virtual FWL_ERR SetCheckState(FX_INT32 iCheck); + virtual int32_t GetCheckState(); + virtual FWL_ERR SetCheckState(int32_t iCheck); protected: void Layout(); FX_DWORD GetPartStates(); @@ -37,7 +37,7 @@ protected: CFX_RectF m_rtCaption; CFX_RectF m_rtFocus; FX_DWORD m_dwTTOStyles; - FX_INT32 m_iTTOAlign; + int32_t m_iTTOAlign; FX_BOOL m_bBtnDown; friend class CFWL_CheckBoxImpDelegate; }; @@ -45,7 +45,7 @@ class CFWL_CheckBoxImpDelegate : public CFWL_WidgetImpDelegate { public: CFWL_CheckBoxImpDelegate(CFWL_CheckBoxImp *pOwner); - virtual FX_INT32 OnProcessMessage(CFWL_Message *pMessage); + virtual int32_t OnProcessMessage(CFWL_Message *pMessage); virtual FWL_ERR OnDrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); protected: void OnActivate(CFWL_Message *pMsg); diff --git a/xfa/src/fwl/src/basewidget/include/fwl_comboboximp.h b/xfa/src/fwl/src/basewidget/include/fwl_comboboximp.h index 250ef35e79..5046cdf47b 100644 --- a/xfa/src/fwl/src/basewidget/include/fwl_comboboximp.h +++ b/xfa/src/fwl/src/basewidget/include/fwl_comboboximp.h @@ -41,7 +41,7 @@ class CFWL_ComboEditDelegate : public CFWL_EditImpDelegate { public: CFWL_ComboEditDelegate(CFWL_ComboEdit *pOwner); - virtual FX_INT32 OnProcessMessage(CFWL_Message *pMessage); + virtual int32_t OnProcessMessage(CFWL_Message *pMessage); protected: CFWL_ComboEdit *m_pOwner; }; @@ -52,10 +52,10 @@ public: CFWL_ComboList(const CFWL_WidgetImpProperties &properties, IFWL_Widget *pOuter); virtual FWL_ERR Initialize(); virtual FWL_ERR Finalize(); - FX_INT32 MatchItem(const CFX_WideString &wsMatch); - void ChangeSelected(FX_INT32 iSel); - FX_INT32 CountItems(); - void GetItemRect(FX_INT32 nIndex, CFX_RectF &rtItem); + int32_t MatchItem(const CFX_WideString &wsMatch); + void ChangeSelected(int32_t iSel); + int32_t CountItems(); + void GetItemRect(int32_t nIndex, CFX_RectF &rtItem); void ClientToOuter(FX_FLOAT &fx, FX_FLOAT &fy); void SetFocus(FX_BOOL bSet); FX_BOOL m_bNotifyOwner; @@ -66,13 +66,13 @@ class CFWL_ComboListDelegate : public CFWL_ListBoxImpDelegate { public: CFWL_ComboListDelegate(CFWL_ComboList *pOwner); - virtual FX_INT32 OnProcessMessage(CFWL_Message *pMessage); + virtual int32_t OnProcessMessage(CFWL_Message *pMessage); protected: void OnDropListFocusChanged(CFWL_Message *pMsg, FX_BOOL bSet = TRUE); - FX_INT32 OnDropListMouseMove(CFWL_MsgMouse *pMsg); - FX_INT32 OnDropListLButtonDown(CFWL_MsgMouse *pMsg); - FX_INT32 OnDropListLButtonUp(CFWL_MsgMouse *pMsg); - FX_INT32 OnDropListKey(CFWL_MsgKey *pKey); + int32_t OnDropListMouseMove(CFWL_MsgMouse *pMsg); + int32_t OnDropListLButtonDown(CFWL_MsgMouse *pMsg); + int32_t OnDropListLButtonUp(CFWL_MsgMouse *pMsg); + int32_t OnDropListKey(CFWL_MsgKey *pKey); void OnDropListKeyDown(CFWL_MsgKey *pKey); CFWL_ComboList *m_pOwner; }; @@ -93,16 +93,16 @@ public: virtual FX_DWORD HitTest(FX_FLOAT fx, FX_FLOAT fy); virtual FWL_ERR DrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); virtual FWL_ERR SetThemeProvider(IFWL_ThemeProvider *pThemeProvider); - virtual FX_INT32 GetCurSel(); - virtual FWL_ERR SetCurSel(FX_INT32 iSel); + virtual int32_t GetCurSel(); + virtual FWL_ERR SetCurSel(int32_t iSel); virtual FWL_ERR SetEditText(const CFX_WideString &wsText); - virtual FX_INT32 GetEditTextLength() const; - virtual FWL_ERR GetEditText(CFX_WideString &wsText, FX_INT32 nStart = 0, FX_INT32 nCount = -1) const; - virtual FWL_ERR SetEditSelRange(FX_INT32 nStart, FX_INT32 nCount = -1); - virtual FX_INT32 GetEditSelRange(FX_INT32 nIndex, FX_INT32 &nStart); - virtual FX_INT32 GetEditLimit(); - virtual FWL_ERR SetEditLimit(FX_INT32 nLimit); - virtual FWL_ERR EditDoClipboard(FX_INT32 iCmd); + virtual int32_t GetEditTextLength() const; + virtual FWL_ERR GetEditText(CFX_WideString &wsText, int32_t nStart = 0, int32_t nCount = -1) const; + virtual FWL_ERR SetEditSelRange(int32_t nStart, int32_t nCount = -1); + virtual int32_t GetEditSelRange(int32_t nIndex, int32_t &nStart); + virtual int32_t GetEditLimit(); + virtual FWL_ERR SetEditLimit(int32_t nLimit); + virtual FWL_ERR EditDoClipboard(int32_t iCmd); virtual FX_BOOL EditRedo(FX_BSTR bsRecord); virtual FX_BOOL EditUndo(FX_BSTR bsRecord); virtual IFWL_ListBox* GetListBoxt(); @@ -130,7 +130,7 @@ protected: FX_BOOL IsDropListShowed(); FX_BOOL IsDropDownStyle() const; void MatchEditText(); - void SynchrEditText(FX_INT32 iListItem); + void SynchrEditText(int32_t iListItem); void Layout(); void ReSetTheme(); void ReSetEditAlignment(); @@ -161,8 +161,8 @@ protected: IFWL_Form *m_pForm; FX_BOOL m_bLButtonDown; FX_BOOL m_bUpFormHandler; - FX_INT32 m_iCurSel; - FX_INT32 m_iBtnState; + int32_t m_iCurSel; + int32_t m_iBtnState; FX_FLOAT m_fComboFormHandler; FX_FLOAT m_fItemHeight; FX_BOOL m_bNeedShowList; @@ -180,7 +180,7 @@ class CFWL_ComboBoxImpDelegate : public CFWL_WidgetImpDelegate { public: CFWL_ComboBoxImpDelegate(CFWL_ComboBoxImp *pOwner); - virtual FX_INT32 OnProcessMessage(CFWL_Message *pMessage); + virtual int32_t OnProcessMessage(CFWL_Message *pMessage); virtual FWL_ERR OnProcessEvent(CFWL_Event *pEvent); virtual FWL_ERR OnDrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); @@ -193,7 +193,7 @@ protected: void OnKey(CFWL_MsgKey *pMsg); void DoSubCtrlKey(CFWL_MsgKey *pMsg); protected: - FX_INT32 DisForm_OnProcessMessage(CFWL_Message *pMessage); + int32_t DisForm_OnProcessMessage(CFWL_Message *pMessage); void DisForm_OnLButtonDown(CFWL_MsgMouse *pMsg); void DisForm_OnFocusChanged(CFWL_Message *pMsg, FX_BOOL bSet = TRUE); void DisForm_OnKey(CFWL_MsgKey *pMsg); @@ -206,7 +206,7 @@ class CFWL_ComboProxyImpDelegate : public CFWL_WidgetImpDelegate { public: CFWL_ComboProxyImpDelegate(IFWL_Form *pForm, CFWL_ComboBoxImp *pComboBox); - virtual FX_INT32 OnProcessMessage(CFWL_Message *pMessage); + virtual int32_t OnProcessMessage(CFWL_Message *pMessage); virtual FWL_ERR OnDrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); void Reset() { diff --git a/xfa/src/fwl/src/basewidget/include/fwl_datetimepickerimp.h b/xfa/src/fwl/src/basewidget/include/fwl_datetimepickerimp.h index cc8db6ada1..f07dcb5532 100644 --- a/xfa/src/fwl/src/basewidget/include/fwl_datetimepickerimp.h +++ b/xfa/src/fwl/src/basewidget/include/fwl_datetimepickerimp.h @@ -48,9 +48,9 @@ class CFWL_DateTimeEditDelegate : public CFWL_EditImpDelegate { public: CFWL_DateTimeEditDelegate(CFWL_DateTimeEdit *pOwner); - virtual FX_INT32 OnProcessMessage(CFWL_Message *pMessage); + virtual int32_t OnProcessMessage(CFWL_Message *pMessage); private: - FX_INT32 DisForm_OnProcessMessage(CFWL_Message *pMessage); + int32_t DisForm_OnProcessMessage(CFWL_Message *pMessage); protected: CFWL_DateTimeEdit *m_pOwner; @@ -68,12 +68,12 @@ class CFWL_DateTimeCalendarDelegate : public CFWL_MonthCalendarImpDelegate { public: CFWL_DateTimeCalendarDelegate(CFWL_DateTimeCalendar *pOwner); - virtual FX_INT32 OnProcessMessage(CFWL_Message *pMessage); + virtual int32_t OnProcessMessage(CFWL_Message *pMessage); void OnLButtonDownEx(CFWL_MsgMouse *pMsg); void OnLButtonUpEx(CFWL_MsgMouse *pMsg); void OnMouseMoveEx(CFWL_MsgMouse *pMsg); private: - FX_INT32 DisForm_OnProcessMessage(CFWL_Message *pMessage); + int32_t DisForm_OnProcessMessage(CFWL_Message *pMessage); void DisForm_OnLButtonUpEx(CFWL_MsgMouse *pMsg); protected: CFWL_DateTimeCalendar *m_pOwner; @@ -94,10 +94,10 @@ public: virtual FX_DWORD HitTest(FX_FLOAT fx, FX_FLOAT fy); virtual FWL_ERR DrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); virtual FWL_ERR SetThemeProvider(IFWL_ThemeProvider *pTP); - virtual FWL_ERR GetCurSel(FX_INT32 &iYear, FX_INT32 &iMonth, FX_INT32 &iDay); - virtual FWL_ERR SetCurSel(FX_INT32 iYear, FX_INT32 iMonth, FX_INT32 iDay); + virtual FWL_ERR GetCurSel(int32_t &iYear, int32_t &iMonth, int32_t &iDay); + virtual FWL_ERR SetCurSel(int32_t iYear, int32_t iMonth, int32_t iDay); virtual FWL_ERR SetEditText(const CFX_WideString &wsText); - virtual FWL_ERR GetEditText(CFX_WideString &wsText, FX_INT32 nStart = 0, FX_INT32 nCount = -1) const; + virtual FWL_ERR GetEditText(CFX_WideString &wsText, int32_t nStart = 0, int32_t nCount = -1) const; public: virtual FX_BOOL CanUndo(); virtual FX_BOOL CanRedo(); @@ -113,18 +113,18 @@ public: virtual FX_BOOL Delete(); virtual FX_BOOL DeSelect(); virtual FWL_ERR GetBBox(CFX_RectF &rect); - virtual FWL_ERR SetEditLimit(FX_INT32 nLimit); + virtual FWL_ERR SetEditLimit(int32_t nLimit); virtual FWL_ERR ModifyEditStylesEx(FX_DWORD dwStylesExAdded, FX_DWORD dwStylesExRemoved); public: IFWL_DateTimeEdit* GetDataTimeEdit(); protected: void DrawDropDownButton(CFX_Graphics *pGraphics, IFWL_ThemeProvider *pTheme, const CFX_Matrix *pMatrix); - void FormatDateString(FX_INT32 iYear, FX_INT32 iMonth, FX_INT32 iDay, CFX_WideString &wsText); + void FormatDateString(int32_t iYear, int32_t iMonth, int32_t iDay, CFX_WideString &wsText); void ShowMonthCalendar(FX_BOOL bActivate); FX_BOOL IsMonthCalendarShowed(); void ReSetEditAlignment(); void InitProxyForm(); - void ProcessSelChanged(FX_INT32 iYear, FX_INT32 iMonth, FX_INT32 iDay); + void ProcessSelChanged(int32_t iYear, int32_t iMonth, int32_t iDay); private: FWL_ERR DisForm_Initialize(); void DisForm_InitDateTimeCalendar(); @@ -141,10 +141,10 @@ protected: CFX_RectF m_rtBtn; CFX_RectF m_rtClient; - FX_INT32 m_iBtnState; - FX_INT32 m_iYear; - FX_INT32 m_iMonth; - FX_INT32 m_iDay; + int32_t m_iBtnState; + int32_t m_iYear; + int32_t m_iMonth; + int32_t m_iDay; FX_BOOL m_bLBtnDown; IFWL_DateTimeEdit *m_pEdit; IFWL_DateTimeCalender *m_pMonthCal; @@ -163,21 +163,21 @@ protected: { return FWL_ERR_Succeeded; } - virtual FX_INT32 GetCurDay(IFWL_Widget *pWidget) + virtual int32_t GetCurDay(IFWL_Widget *pWidget) { return m_iCurDay; } - virtual FX_INT32 GetCurMonth(IFWL_Widget *pWidget) + virtual int32_t GetCurMonth(IFWL_Widget *pWidget) { return m_iCurMonth; } - virtual FX_INT32 GetCurYear(IFWL_Widget *pWidget) + virtual int32_t GetCurYear(IFWL_Widget *pWidget) { return m_iCurYear; } - FX_INT32 m_iCurDay; - FX_INT32 m_iCurYear; - FX_INT32 m_iCurMonth; + int32_t m_iCurDay; + int32_t m_iCurYear; + int32_t m_iCurMonth; }; CFWL_MonthCalendarImpDP m_MonthCalendarDP; @@ -190,7 +190,7 @@ class CFWL_DateTimePickerImpDelegate : public CFWL_WidgetImpDelegate { public: CFWL_DateTimePickerImpDelegate(CFWL_DateTimePickerImp *pOwner); - virtual FX_INT32 OnProcessMessage(CFWL_Message *pMessage); + virtual int32_t OnProcessMessage(CFWL_Message *pMessage); virtual FWL_ERR OnDrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); protected: void OnFocusChanged(CFWL_Message *pMsg, FX_BOOL bSet = TRUE); diff --git a/xfa/src/fwl/src/basewidget/include/fwl_editimp.h b/xfa/src/fwl/src/basewidget/include/fwl_editimp.h index b5671e659c..db9e25fb5c 100644 --- a/xfa/src/fwl/src/basewidget/include/fwl_editimp.h +++ b/xfa/src/fwl/src/basewidget/include/fwl_editimp.h @@ -32,25 +32,25 @@ public: virtual FWL_ERR DrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); virtual FWL_ERR SetThemeProvider(IFWL_ThemeProvider *pThemeProvider); virtual FWL_ERR SetText(const CFX_WideString &wsText); - virtual FX_INT32 GetTextLength() const; - virtual FWL_ERR GetText(CFX_WideString &wsText, FX_INT32 nStart = 0, FX_INT32 nCount = -1) const; + virtual int32_t GetTextLength() const; + virtual FWL_ERR GetText(CFX_WideString &wsText, int32_t nStart = 0, int32_t nCount = -1) const; virtual FWL_ERR ClearText(); - virtual FX_INT32 GetCaretPos() const; - virtual FX_INT32 SetCaretPos(FX_INT32 nIndex, FX_BOOL bBefore = TRUE); - virtual FWL_ERR AddSelRange(FX_INT32 nStart, FX_INT32 nCount = -1); - virtual FX_INT32 CountSelRanges(); - virtual FX_INT32 GetSelRange(FX_INT32 nIndex, FX_INT32 &nStart); + virtual int32_t GetCaretPos() const; + virtual int32_t SetCaretPos(int32_t nIndex, FX_BOOL bBefore = TRUE); + virtual FWL_ERR AddSelRange(int32_t nStart, int32_t nCount = -1); + virtual int32_t CountSelRanges(); + virtual int32_t GetSelRange(int32_t nIndex, int32_t &nStart); virtual FWL_ERR ClearSelections(); - virtual FX_INT32 GetLimit(); - virtual FWL_ERR SetLimit(FX_INT32 nLimit); + virtual int32_t GetLimit(); + virtual FWL_ERR SetLimit(int32_t nLimit); virtual FWL_ERR SetAliasChar(FX_WCHAR wAlias); virtual FWL_ERR SetFormatString(const CFX_WideString &wsFormat); - virtual FWL_ERR Insert(FX_INT32 nStart, FX_LPCWSTR lpText, FX_INT32 nLen); + virtual FWL_ERR Insert(int32_t nStart, FX_LPCWSTR lpText, int32_t nLen); virtual FWL_ERR DeleteSelections(); - virtual FWL_ERR DeleteRange(FX_INT32 nStart, FX_INT32 nCount = -1); + virtual FWL_ERR DeleteRange(int32_t nStart, int32_t nCount = -1); virtual FWL_ERR ReplaceSelections(const CFX_WideStringC &wsReplace); - virtual FWL_ERR Replace(FX_INT32 nStart, FX_INT32 nLen, const CFX_WideStringC &wsReplace); - virtual FWL_ERR DoClipboard(FX_INT32 iCmd); + virtual FWL_ERR Replace(int32_t nStart, int32_t nLen, const CFX_WideStringC &wsReplace); + virtual FWL_ERR DoClipboard(int32_t iCmd); virtual FX_BOOL Copy(CFX_WideString &wsCopy); virtual FX_BOOL Cut(CFX_WideString &wsCut); virtual FX_BOOL Paste(const CFX_WideString &wsPaste); @@ -63,22 +63,22 @@ public: virtual FX_BOOL CanRedo(); virtual FWL_ERR SetTabWidth(FX_FLOAT fTabWidth, FX_BOOL bEquidistant); virtual FWL_ERR SetOuter(IFWL_Widget *pOuter); - virtual FWL_ERR SetNumberRange(FX_INT32 iMin, FX_INT32 iMax); - virtual void On_CaretChanged(IFDE_TxtEdtEngine *pEdit, FX_INT32 nPage, FX_BOOL bVisible = TRUE); + virtual FWL_ERR SetNumberRange(int32_t iMin, int32_t iMax); + virtual void On_CaretChanged(IFDE_TxtEdtEngine *pEdit, int32_t nPage, FX_BOOL bVisible = TRUE); virtual void On_TextChanged(IFDE_TxtEdtEngine * pEdit, FDE_TXTEDT_TEXTCHANGE_INFO &ChangeInfo); virtual void On_PageCountChanged(IFDE_TxtEdtEngine *pEdit) {} virtual void On_SelChanged(IFDE_TxtEdtEngine *pEdit); - virtual FX_BOOL On_PageLoad(IFDE_TxtEdtEngine *pEdit, FX_INT32 nPageIndex, FX_INT32 nPurpose); - virtual FX_BOOL On_PageUnload(IFDE_TxtEdtEngine *pEdit, FX_INT32 nPageIndex, FX_INT32 nPurpose); + virtual FX_BOOL On_PageLoad(IFDE_TxtEdtEngine *pEdit, int32_t nPageIndex, int32_t nPurpose); + virtual FX_BOOL On_PageUnload(IFDE_TxtEdtEngine *pEdit, int32_t nPageIndex, int32_t nPurpose); virtual FX_BOOL On_PageChange(IFDE_TxtEdtEngine *pEdit, FX_BOOL bPageUp = TRUE) { return TRUE; } virtual void On_AddDoRecord(IFDE_TxtEdtEngine *pEdit, FX_BSTR bsDoRecord); - virtual FX_BOOL On_ValidateField(IFDE_TxtEdtEngine *pEdit, FX_INT32 nBlockIndex, FX_INT32 nFieldIndex, \ - const CFX_WideString &wsFieldText, FX_INT32 nCharIndex); - virtual FX_BOOL On_ValidateBlock(IFDE_TxtEdtEngine *pEdit, FX_INT32 nBlockIndex); - virtual FX_BOOL On_GetBlockFormatText(IFDE_TxtEdtEngine *pEdit, FX_INT32 nBlockIndex, CFX_WideString &wsBlockText); + virtual FX_BOOL On_ValidateField(IFDE_TxtEdtEngine *pEdit, int32_t nBlockIndex, int32_t nFieldIndex, \ + const CFX_WideString &wsFieldText, int32_t nCharIndex); + virtual FX_BOOL On_ValidateBlock(IFDE_TxtEdtEngine *pEdit, int32_t nBlockIndex); + virtual FX_BOOL On_GetBlockFormatText(IFDE_TxtEdtEngine *pEdit, int32_t nBlockIndex, CFX_WideString &wsBlockText); virtual FX_BOOL On_Validate(IFDE_TxtEdtEngine * pEdit, CFX_WideString &wsText); virtual FWL_ERR SetBackgroundColor(FX_DWORD color); virtual FWL_ERR SetFont(const CFX_WideString &wsFont, FX_FLOAT fSize); @@ -107,12 +107,12 @@ protected: void ClearRecord(); FX_BOOL IsShowScrollBar(FX_BOOL bVert); FX_BOOL IsContentHeightOverflow(); - FX_INT32 AddDoRecord(FX_BSTR bsDoRecord); - void ProcessInsertError(FX_INT32 iError); + int32_t AddDoRecord(FX_BSTR bsDoRecord); + void ProcessInsertError(int32_t iError); void DrawSpellCheck(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); - void AddSpellCheckObj(CFX_Path& PathData, FX_INT32 nStart, FX_INT32 nCount, FX_FLOAT fOffSetX, FX_FLOAT fOffSetY); - FX_INT32 GetWordAtPoint(CFX_PointF pointf, FX_INT32& nCount); + void AddSpellCheckObj(CFX_Path& PathData, int32_t nStart, int32_t nCount, FX_FLOAT fOffSetX, FX_FLOAT fOffSetY); + int32_t GetWordAtPoint(CFX_PointF pointf, int32_t& nCount); CFX_RectF m_rtClient; CFX_RectF m_rtEngine; CFX_RectF m_rtStatic; @@ -121,15 +121,15 @@ protected: FX_FLOAT m_fScrollOffsetY; IFDE_TxtEdtEngine* m_pEdtEngine; FX_BOOL m_bLButtonDown; - FX_INT32 m_nSelStart; - FX_INT32 m_nLimit; + int32_t m_nSelStart; + int32_t m_nLimit; FX_FLOAT m_fSpaceAbove; FX_FLOAT m_fSpaceBelow; FX_FLOAT m_fFontSize; FX_ARGB m_argbSel; FX_BOOL m_bSetRange; - FX_INT32 m_iMin; - FX_INT32 m_iMax; + int32_t m_iMin; + int32_t m_iMax; IFWL_ScrollBar* m_pVertScrollBar; IFWL_ScrollBar* m_pHorzScrollBar; IFWL_Caret* m_pCaret; @@ -141,14 +141,14 @@ protected: FX_BOOL m_updateBackColor; CFX_WideString m_wsFont; CFX_ByteStringArray m_RecordArr; - FX_INT32 m_iCurRecord; - FX_INT32 m_iMaxRecord; + int32_t m_iCurRecord; + int32_t m_iMaxRecord; }; class CFWL_EditImpDelegate : public CFWL_WidgetImpDelegate { public: CFWL_EditImpDelegate(CFWL_EditImp *pOwner); - virtual FX_INT32 OnProcessMessage(CFWL_Message *pMessage); + virtual int32_t OnProcessMessage(CFWL_Message *pMessage); virtual FWL_ERR OnProcessEvent(CFWL_Event *pEvent); virtual FWL_ERR OnDrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); protected: diff --git a/xfa/src/fwl/src/basewidget/include/fwl_formproxyimp.h b/xfa/src/fwl/src/basewidget/include/fwl_formproxyimp.h index def7eb9650..e582f8c0e6 100644 --- a/xfa/src/fwl/src/basewidget/include/fwl_formproxyimp.h +++ b/xfa/src/fwl/src/basewidget/include/fwl_formproxyimp.h @@ -32,7 +32,7 @@ class CFWL_FormProxyImpDelegate : public CFWL_WidgetImpDelegate { public: CFWL_FormProxyImpDelegate(CFWL_FormProxyImp *pOwner); - virtual FX_INT32 OnProcessMessage(CFWL_Message *pMessage); + virtual int32_t OnProcessMessage(CFWL_Message *pMessage); protected: CFWL_FormProxyImp *m_pOwner; }; diff --git a/xfa/src/fwl/src/basewidget/include/fwl_listboximp.h b/xfa/src/fwl/src/basewidget/include/fwl_listboximp.h index 51d605885f..7cbb0b8cfd 100644 --- a/xfa/src/fwl/src/basewidget/include/fwl_listboximp.h +++ b/xfa/src/fwl/src/basewidget/include/fwl_listboximp.h @@ -28,9 +28,9 @@ public: virtual FX_DWORD HitTest(FX_FLOAT fx, FX_FLOAT fy); virtual FWL_ERR DrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); virtual FWL_ERR SetThemeProvider(IFWL_ThemeProvider *pThemeProvider); - virtual FX_INT32 CountSelItems(); - virtual FWL_HLISTITEM GetSelItem(FX_INT32 nIndexSel); - virtual FX_INT32 GetSelIndex(FX_INT32 nIndex); + virtual int32_t CountSelItems(); + virtual FWL_HLISTITEM GetSelItem(int32_t nIndexSel); + virtual int32_t GetSelIndex(int32_t nIndex); virtual FWL_ERR SetSelItem(FWL_HLISTITEM hItem, FX_BOOL bSelect = TRUE); virtual FWL_ERR GetItemText(FWL_HLISTITEM hItem, CFX_WideString &wsText); virtual FWL_ERR GetScrollPos(FX_FLOAT &fPos, FX_BOOL bVert = TRUE); @@ -51,7 +51,7 @@ protected: FX_BOOL ScrollToVisible(FWL_HLISTITEM hItem); void DrawBkground(CFX_Graphics *pGraphics, IFWL_ThemeProvider *pTheme, const CFX_Matrix *pMatrix = NULL); void DrawItems(CFX_Graphics *pGraphics, IFWL_ThemeProvider *pTheme, const CFX_Matrix *pMatrix = NULL); - void DrawItem(CFX_Graphics *pGraphics, IFWL_ThemeProvider *pTheme, FWL_HLISTITEM hItem, FX_INT32 Index, const CFX_RectF &rtItem, const CFX_Matrix *pMatrix = NULL); + void DrawItem(CFX_Graphics *pGraphics, IFWL_ThemeProvider *pTheme, FWL_HLISTITEM hItem, int32_t Index, const CFX_RectF &rtItem, const CFX_Matrix *pMatrix = NULL); void DrawStatic(CFX_Graphics *pGraphics, IFWL_ThemeProvider *pTheme); CFX_SizeF CalcSize(FX_BOOL bAutoSize = FALSE); void GetItemSize(CFX_SizeF &size, FWL_HLISTITEM hItem, FX_FLOAT fWidth, FX_FLOAT fHeight, FX_BOOL bAutoSize = FALSE); @@ -69,7 +69,7 @@ protected: IFWL_ScrollBar* m_pHorzScrollBar; IFWL_ScrollBar* m_pVertScrollBar; FX_DWORD m_dwTTOStyles; - FX_INT32 m_iTTOAligns; + int32_t m_iTTOAligns; FWL_HLISTITEM m_hAnchor; FX_FLOAT m_fItemHeight; FX_FLOAT m_fScorllBarWidth; @@ -81,7 +81,7 @@ class CFWL_ListBoxImpDelegate : public CFWL_WidgetImpDelegate { public: CFWL_ListBoxImpDelegate(CFWL_ListBoxImp *pOwner); - virtual FX_INT32 OnProcessMessage(CFWL_Message *pMessage); + virtual int32_t OnProcessMessage(CFWL_Message *pMessage); virtual FWL_ERR OnProcessEvent(CFWL_Event *pEvent); virtual FWL_ERR OnDrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); protected: diff --git a/xfa/src/fwl/src/basewidget/include/fwl_monthcalendarimp.h b/xfa/src/fwl/src/basewidget/include/fwl_monthcalendarimp.h index fc4da5864f..0cf2ed444a 100644 --- a/xfa/src/fwl/src/basewidget/include/fwl_monthcalendarimp.h +++ b/xfa/src/fwl/src/basewidget/include/fwl_monthcalendarimp.h @@ -12,7 +12,7 @@ class CFWL_WidgetImpDelegate; class IFWL_Widget; class IFDE_DateTime; class CFDE_DateTime; -extern FX_BYTE FX_DaysInMonth(FX_INT32 iYear, FX_BYTE iMonth); +extern uint8_t FX_DaysInMonth(int32_t iYear, uint8_t iMonth); class CFWL_MonthCalendarImp; class CFWL_MonthCalendarImpDelegate; class CFWL_MonthCalendarImp : public CFWL_WidgetImp @@ -28,9 +28,9 @@ public: virtual FWL_ERR GetWidgetRect(CFX_RectF &rect, FX_BOOL bAutoSize = FALSE); virtual FWL_ERR Update(); virtual FWL_ERR DrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); - virtual FX_INT32 CountSelect(); - virtual FX_BOOL GetSelect(FX_INT32 &iYear, FX_INT32 &iMonth, FX_INT32 &iDay, FX_INT32 nIndex = 0); - virtual FX_BOOL SetSelect(FX_INT32 iYear, FX_INT32 iMonth, FX_INT32 iDay); + virtual int32_t CountSelect(); + virtual FX_BOOL GetSelect(int32_t &iYear, int32_t &iMonth, int32_t &iDay, int32_t nIndex = 0); + virtual FX_BOOL SetSelect(int32_t iYear, int32_t iMonth, int32_t iDay); protected: void DrawBkground(CFX_Graphics *pGraphics, IFWL_ThemeProvider *pTheme, const CFX_Matrix *pMatrix); void DrawHeadBK(CFX_Graphics *pGraphics, IFWL_ThemeProvider *pTheme, const CFX_Matrix *pMatrix); @@ -53,25 +53,25 @@ protected: void CalcTodaySize(); void CalDateItem(); void GetCapValue(); - FX_INT32 CalWeekNumber(FX_INT32 iYear, FX_INT32 iMonth, FX_INT32 iDay); + int32_t CalWeekNumber(int32_t iYear, int32_t iMonth, int32_t iDay); - FX_BOOL GetMinDate(FX_INT32 &iYear, FX_INT32 &iMonth, FX_INT32 &iDay); - FX_BOOL SetMinDate(FX_INT32 iYear, FX_INT32 iMonth, FX_INT32 iDay); - FX_BOOL GetMaxDate(FX_INT32 &iYear, FX_INT32 &iMonth, FX_INT32 &iDay); - FX_BOOL SetMaxDate(FX_INT32 iYear, FX_INT32 iMonth, FX_INT32 iDay); + FX_BOOL GetMinDate(int32_t &iYear, int32_t &iMonth, int32_t &iDay); + FX_BOOL SetMinDate(int32_t iYear, int32_t iMonth, int32_t iDay); + FX_BOOL GetMaxDate(int32_t &iYear, int32_t &iMonth, int32_t &iDay); + FX_BOOL SetMaxDate(int32_t iYear, int32_t iMonth, int32_t iDay); FX_BOOL InitDate(); void ClearDateItem(); void ReSetDateItem(); FX_BOOL NextMonth(); FX_BOOL PrevMonth(); - void ChangeToMonth(FX_INT32 iYear, FX_INT32 iMonth); - FX_BOOL RemoveSelDay(FX_INT32 iDay, FX_BOOL bAll = FALSE); - FX_BOOL AddSelDay(FX_INT32 iDay); + void ChangeToMonth(int32_t iYear, int32_t iMonth); + FX_BOOL RemoveSelDay(int32_t iDay, FX_BOOL bAll = FALSE); + FX_BOOL AddSelDay(int32_t iDay); FX_BOOL JumpToToday(); - void GetHeadText(FX_INT32 iYear, FX_INT32 iMonth, CFX_WideString &wsHead); - void GetTodayText(FX_INT32 iYear, FX_INT32 iMonth, FX_INT32 iDay, CFX_WideString &wsToday); - FX_INT32 GetDayAtPoint(FX_FLOAT x, FX_FLOAT y); - FX_BOOL GetDayRect(FX_INT32 iDay, CFX_RectF &rtDay); + void GetHeadText(int32_t iYear, int32_t iMonth, CFX_WideString &wsHead); + void GetTodayText(int32_t iYear, int32_t iMonth, int32_t iDay, CFX_WideString &wsToday); + int32_t GetDayAtPoint(FX_FLOAT x, FX_FLOAT y); + FX_BOOL GetDayRect(int32_t iDay, CFX_RectF &rtDay); typedef struct _DATE { _DATE() { @@ -79,7 +79,7 @@ protected: iMonth = 0; iDay = 0; } - _DATE(FX_INT32 year, FX_INT32 month, FX_INT32 day) : iYear(year), iMonth(month), iDay(day) {} + _DATE(int32_t year, int32_t month, int32_t day) : iYear(year), iMonth(month), iDay(day) {} FX_BOOL operator < (const _DATE &right) { if (iYear < right.iYear) { @@ -106,9 +106,9 @@ protected: } return FALSE; } - FX_INT32 iYear; - FX_INT32 iMonth; - FX_INT32 iDay; + int32_t iYear; + int32_t iMonth; + int32_t iDay; } DATE, *LPDATE; FX_BOOL m_bInit; @@ -128,22 +128,22 @@ protected: CFX_WideString m_wsToday; CFX_DateTime *m_pDateTime; CFX_PtrArray m_arrDates; - FX_INT32 m_iCurYear; - FX_INT32 m_iCurMonth; - FX_INT32 m_iYear; - FX_INT32 m_iMonth; - FX_INT32 m_iDay; - FX_INT32 m_iHovered; - FX_INT32 m_iLBtnPartStates; - FX_INT32 m_iRBtnPartStates; + int32_t m_iCurYear; + int32_t m_iCurMonth; + int32_t m_iYear; + int32_t m_iMonth; + int32_t m_iDay; + int32_t m_iHovered; + int32_t m_iLBtnPartStates; + int32_t m_iRBtnPartStates; DATE m_dtMin; DATE m_dtMax; CFX_SizeF m_szHead; CFX_SizeF m_szCell; CFX_SizeF m_szToday; - typedef CFX_ArrayTemplate CFWL_Int32Array; + typedef CFX_ArrayTemplate CFWL_Int32Array; CFWL_Int32Array m_arrSelDays; - FX_INT32 m_iMaxSel; + int32_t m_iMaxSel; CFX_RectF m_rtClient; FX_FLOAT m_fHeadWid; FX_FLOAT m_fHeadHei; @@ -178,9 +178,9 @@ protected: friend class CFWL_MonthCalendarImpDelegate; }; typedef struct _DATEINFO { - _DATEINFO(FX_INT32 day, FX_INT32 dayofweek, FX_DWORD dwSt, CFX_RectF rc, CFX_WideString &wsday) : iDay(day), iDayOfWeek(dayofweek), dwStates(dwSt), rect(rc), wsDay(wsday) {} - FX_INT32 iDay; - FX_INT32 iDayOfWeek; + _DATEINFO(int32_t day, int32_t dayofweek, FX_DWORD dwSt, CFX_RectF rc, CFX_WideString &wsday) : iDay(day), iDayOfWeek(dayofweek), dwStates(dwSt), rect(rc), wsDay(wsday) {} + int32_t iDay; + int32_t iDayOfWeek; FX_DWORD dwStates; CFX_RectF rect; CFX_WideString wsDay; @@ -189,7 +189,7 @@ class CFWL_MonthCalendarImpDelegate : public CFWL_WidgetImpDelegate { public: CFWL_MonthCalendarImpDelegate(CFWL_MonthCalendarImp *pOwner); - virtual FX_INT32 OnProcessMessage(CFWL_Message *pMessage); + virtual int32_t OnProcessMessage(CFWL_Message *pMessage); virtual FWL_ERR OnDrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); protected: void OnActivate(CFWL_Message *pMsg); diff --git a/xfa/src/fwl/src/basewidget/include/fwl_pushbuttonimp.h b/xfa/src/fwl/src/basewidget/include/fwl_pushbuttonimp.h index 1688da887c..5238884979 100644 --- a/xfa/src/fwl/src/basewidget/include/fwl_pushbuttonimp.h +++ b/xfa/src/fwl/src/basewidget/include/fwl_pushbuttonimp.h @@ -35,14 +35,14 @@ protected: CFX_RectF m_rtCaption; FX_BOOL m_bBtnDown; FX_DWORD m_dwTTOStyles; - FX_INT32 m_iTTOAlign; + int32_t m_iTTOAlign; friend class CFWL_PushButtonImpDelegate; }; class CFWL_PushButtonImpDelegate : public CFWL_WidgetImpDelegate { public: CFWL_PushButtonImpDelegate(CFWL_PushButtonImp *pOwner); - virtual FX_INT32 OnProcessMessage(CFWL_Message *pMessage); + virtual int32_t OnProcessMessage(CFWL_Message *pMessage); virtual FWL_ERR OnProcessEvent(CFWL_Event *pEvent); virtual FWL_ERR OnDrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); protected: diff --git a/xfa/src/fwl/src/basewidget/include/fwl_scrollbarimp.h b/xfa/src/fwl/src/basewidget/include/fwl_scrollbarimp.h index e4073b5fc7..9b8dc19efb 100644 --- a/xfa/src/fwl/src/basewidget/include/fwl_scrollbarimp.h +++ b/xfa/src/fwl/src/basewidget/include/fwl_scrollbarimp.h @@ -40,7 +40,7 @@ public: virtual FWL_ERR SetTrackPos(FX_FLOAT fTrackPos); virtual FX_BOOL DoScroll(FX_DWORD dwCode, FX_FLOAT fPos = 0.0f); virtual FWL_ERR SetOuter(IFWL_Widget *pOuter); - virtual FX_INT32 Run(FWL_HTIMER hTimer); + virtual int32_t Run(FWL_HTIMER hTimer); protected: void DrawTrack(CFX_Graphics *pGraphics, IFWL_ThemeProvider *pTheme, FX_BOOL bLower = TRUE, const CFX_Matrix *pMatrix = NULL); void DrawArrowBtn(CFX_Graphics *pGraphics, IFWL_ThemeProvider *pTheme, FX_BOOL bMinBtn = TRUE, const CFX_Matrix *pMatrix = NULL); @@ -64,15 +64,15 @@ protected: FX_FLOAT m_fStepSize; FX_FLOAT m_fPos; FX_FLOAT m_fTrackPos; - FX_INT32 m_iMinButtonState; - FX_INT32 m_iMaxButtonState; - FX_INT32 m_iThumbButtonState; - FX_INT32 m_iMinTrackState; - FX_INT32 m_iMaxTrackState; + int32_t m_iMinButtonState; + int32_t m_iMaxButtonState; + int32_t m_iThumbButtonState; + int32_t m_iMinTrackState; + int32_t m_iMaxTrackState; FX_FLOAT m_fLastTrackPos; FX_FLOAT m_cpTrackPointX; FX_FLOAT m_cpTrackPointY; - FX_INT32 m_iMouseWheel; + int32_t m_iMouseWheel; FX_BOOL m_bTrackMouseLeave; FX_BOOL m_bMouseHover; FX_BOOL m_bMouseDown; @@ -94,7 +94,7 @@ class CFWL_ScrollBarImpDelegate : public CFWL_WidgetImpDelegate { public: CFWL_ScrollBarImpDelegate(CFWL_ScrollBarImp *pOwner); - virtual FX_INT32 OnProcessMessage(CFWL_Message *pMessage); + virtual int32_t OnProcessMessage(CFWL_Message *pMessage); virtual FWL_ERR OnDrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); protected: void OnLButtonDown(FX_DWORD dwFlags, FX_FLOAT fx, FX_FLOAT fy); @@ -102,11 +102,11 @@ protected: void OnMouseMove(FX_DWORD dwFlags, FX_FLOAT fx, FX_FLOAT fy); void OnMouseLeave(); void OnMouseWheel(FX_FLOAT fx, FX_FLOAT fy, FX_DWORD dwFlags, FX_FLOAT fDeltaX, FX_FLOAT fDeltaY); - void DoMouseDown(FX_INT32 iItem, const CFX_RectF &rtItem, FX_INT32 &iState, FX_FLOAT fx, FX_FLOAT fy); - void DoMouseUp(FX_INT32 iItem, const CFX_RectF &rtItem, FX_INT32 &iState, FX_FLOAT fx, FX_FLOAT fy); - void DoMouseMove(FX_INT32 iItem, const CFX_RectF &rtItem, FX_INT32 &iState, FX_FLOAT fx, FX_FLOAT fy); - void DoMouseLeave(FX_INT32 iItem, const CFX_RectF &rtItem, FX_INT32 &iState); - void DoMouseHover(FX_INT32 iItem, const CFX_RectF &rtItem, FX_INT32 &iState); + void DoMouseDown(int32_t iItem, const CFX_RectF &rtItem, int32_t &iState, FX_FLOAT fx, FX_FLOAT fy); + void DoMouseUp(int32_t iItem, const CFX_RectF &rtItem, int32_t &iState, FX_FLOAT fx, FX_FLOAT fy); + void DoMouseMove(int32_t iItem, const CFX_RectF &rtItem, int32_t &iState, FX_FLOAT fx, FX_FLOAT fy); + void DoMouseLeave(int32_t iItem, const CFX_RectF &rtItem, int32_t &iState); + void DoMouseHover(int32_t iItem, const CFX_RectF &rtItem, int32_t &iState); CFWL_ScrollBarImp *m_pOwner; }; diff --git a/xfa/src/fwl/src/basewidget/include/fwl_spinbuttonimp.h b/xfa/src/fwl/src/basewidget/include/fwl_spinbuttonimp.h index 2275a40f90..808903c1d0 100644 --- a/xfa/src/fwl/src/basewidget/include/fwl_spinbuttonimp.h +++ b/xfa/src/fwl/src/basewidget/include/fwl_spinbuttonimp.h @@ -27,7 +27,7 @@ public: virtual FWL_ERR Update(); virtual FX_DWORD HitTest(FX_FLOAT fx, FX_FLOAT fy); virtual FWL_ERR DrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); - virtual FX_INT32 Run(FWL_HTIMER hTimer); + virtual int32_t Run(FWL_HTIMER hTimer); FWL_ERR EnableButton(FX_BOOL bEnable, FX_BOOL bUp = TRUE); FX_BOOL IsButtonEnable(FX_BOOL bUp = TRUE); protected: @@ -38,7 +38,7 @@ protected: CFX_RectF m_rtDnButton; FX_DWORD m_dwUpState; FX_DWORD m_dwDnState; - FX_INT32 m_iButtonIndex; + int32_t m_iButtonIndex; FX_BOOL m_bLButtonDwn; FWL_HTIMER m_hTimer; friend class CFWL_SpinButtonImpDelegate; @@ -47,7 +47,7 @@ class CFWL_SpinButtonImpDelegate : public CFWL_WidgetImpDelegate { public: CFWL_SpinButtonImpDelegate(CFWL_SpinButtonImp *pOwner); - virtual FX_INT32 OnProcessMessage(CFWL_Message *pMessage); + virtual int32_t OnProcessMessage(CFWL_Message *pMessage); virtual FWL_ERR OnProcessEvent(CFWL_Event *pEvent); virtual FWL_ERR OnDrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); protected: diff --git a/xfa/src/fwl/src/basewidget/include/fwl_tooltipctrlimp.h b/xfa/src/fwl/src/basewidget/include/fwl_tooltipctrlimp.h index 7317f3fe5b..6532ebab53 100644 --- a/xfa/src/fwl/src/basewidget/include/fwl_tooltipctrlimp.h +++ b/xfa/src/fwl/src/basewidget/include/fwl_tooltipctrlimp.h @@ -42,14 +42,14 @@ protected: CFWL_ToolTipTimer() {}; ~CFWL_ToolTipTimer() {}; CFWL_ToolTipTimer(CFWL_ToolTipImp * pToolTip); - virtual FX_INT32 Run(FWL_HTIMER hTimer); + virtual int32_t Run(FWL_HTIMER hTimer); CFWL_ToolTipImp *m_pToolTip; }; CFX_RectF m_rtClient; CFX_RectF m_rtCaption; FX_BOOL m_bBtnDown; FX_DWORD m_dwTTOStyles; - FX_INT32 m_iTTOAlign; + int32_t m_iTTOAlign; CFX_RectF m_rtAnchor; FWL_HTIMER m_hTimerShow; FWL_HTIMER m_hTimerHide; @@ -63,7 +63,7 @@ class CFWL_ToolTipImpDelegate : public CFWL_WidgetImpDelegate { public: CFWL_ToolTipImpDelegate(CFWL_ToolTipImp *pOwner); - virtual FX_INT32 OnProcessMessage(CFWL_Message *pMessage); + virtual int32_t OnProcessMessage(CFWL_Message *pMessage); virtual FWL_ERR OnProcessEvent(CFWL_Event *pEvent); virtual FWL_ERR OnDrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); protected: diff --git a/xfa/src/fwl/src/basewidget/include/fxmath_barcodeimp.h b/xfa/src/fwl/src/basewidget/include/fxmath_barcodeimp.h index 8fe41b762c..0c4e38dd9e 100644 --- a/xfa/src/fwl/src/basewidget/include/fxmath_barcodeimp.h +++ b/xfa/src/fwl/src/basewidget/include/fxmath_barcodeimp.h @@ -14,30 +14,30 @@ public: FX_BOOL Crreate(BC_TYPE type); virtual void Release(); virtual BC_TYPE GetType(); - virtual FX_BOOL Encode(FX_WSTR contents, FX_BOOL isDevice, FX_INT32 &e); - virtual FX_BOOL RenderDevice(CFX_RenderDevice* device, const CFX_Matrix* matirx, FX_INT32 &e); - virtual FX_BOOL RenderBitmap(CFX_DIBitmap *&pOutBitmap, FX_INT32 &e); - virtual CFX_WideString Decode(FX_BYTE* buf, FX_INT32 width, FX_INT32 height, FX_INT32 &errorCode); - virtual CFX_WideString Decode(CFX_DIBitmap *pBitmap, FX_INT32 &errorCode); + virtual FX_BOOL Encode(FX_WSTR contents, FX_BOOL isDevice, int32_t &e); + virtual FX_BOOL RenderDevice(CFX_RenderDevice* device, const CFX_Matrix* matirx, int32_t &e); + virtual FX_BOOL RenderBitmap(CFX_DIBitmap *&pOutBitmap, int32_t &e); + virtual CFX_WideString Decode(uint8_t* buf, int32_t width, int32_t height, int32_t &errorCode); + virtual CFX_WideString Decode(CFX_DIBitmap *pBitmap, int32_t &errorCode); virtual FX_BOOL SetCharEncoding(BC_CHAR_ENCODING encoding); - virtual FX_BOOL SetModuleHeight(FX_INT32 moduleHeight); - virtual FX_BOOL SetModuleWidth(FX_INT32 moduleWidth); - virtual FX_BOOL SetHeight(FX_INT32 height); - virtual FX_BOOL SetWidth(FX_INT32 width); + virtual FX_BOOL SetModuleHeight(int32_t moduleHeight); + virtual FX_BOOL SetModuleWidth(int32_t moduleWidth); + virtual FX_BOOL SetHeight(int32_t height); + virtual FX_BOOL SetWidth(int32_t width); virtual FX_BOOL CheckContentValidity(FX_WSTR contents); virtual FX_BOOL SetPrintChecksum(FX_BOOL checksum); - virtual FX_BOOL SetDataLength(FX_INT32 length); - virtual FX_BOOL SetCalChecksum(FX_INT32 state); + virtual FX_BOOL SetDataLength(int32_t length); + virtual FX_BOOL SetCalChecksum(int32_t state); virtual FX_BOOL SetFont(CFX_Font* pFont); virtual FX_BOOL SetFontSize(FX_FLOAT size); - virtual FX_BOOL SetFontStyle(FX_INT32 style); + virtual FX_BOOL SetFontStyle(int32_t style); virtual FX_BOOL SetFontColor(FX_ARGB color); virtual FX_BOOL SetTextLocation(BC_TEXT_LOC location); - virtual FX_BOOL SetWideNarrowRatio(FX_INT32 ratio); + virtual FX_BOOL SetWideNarrowRatio(int32_t ratio); virtual FX_BOOL SetStartChar(FX_CHAR start); virtual FX_BOOL SetEndChar(FX_CHAR end); - virtual FX_BOOL SetVersion(FX_INT32 version); - virtual FX_BOOL SetErrorCorrectionLevel(FX_INT32 level); + virtual FX_BOOL SetVersion(int32_t version); + virtual FX_BOOL SetErrorCorrectionLevel(int32_t level); virtual FX_BOOL SetTruncated(FX_BOOL truncated); protected: CBC_CodeBase* m_pBCEngine; diff --git a/xfa/src/fwl/src/core/fwl_appimp.cpp b/xfa/src/fwl/src/core/fwl_appimp.cpp index e70d3f6a09..33d2fff886 100644 --- a/xfa/src/fwl/src/core/fwl_appimp.cpp +++ b/xfa/src/fwl/src/core/fwl_appimp.cpp @@ -70,7 +70,7 @@ FWL_ERR CFWL_AppImp::SetThemeProvider(IFWL_ThemeProvider* pThemeProvider) m_pThemeProvider = pThemeProvider; return FWL_ERR_Succeeded; } -FWL_ERR CFWL_AppImp::Exit(FX_INT32 iExitCode ) +FWL_ERR CFWL_AppImp::Exit(int32_t iExitCode ) { while (m_pNoteDriver->PopNoteLoop()); return m_pWidgetMgr->GetAdapterWidgetMgr()->Exit(0); diff --git a/xfa/src/fwl/src/core/fwl_contentimp.cpp b/xfa/src/fwl/src/core/fwl_contentimp.cpp index 3093aebf74..93c8c3b612 100644 --- a/xfa/src/fwl/src/core/fwl_contentimp.cpp +++ b/xfa/src/fwl/src/core/fwl_contentimp.cpp @@ -21,7 +21,7 @@ FWL_ERR IFWL_Content::Initialize() ((CFWL_ContentImp*)m_pData)->SetInterface(this); return ((CFWL_ContentImp*)m_pData)->Initialize(); } -FWL_ERR IFWL_Content::InsertWidget(IFWL_Widget *pChild, FX_INT32 nIndex ) +FWL_ERR IFWL_Content::InsertWidget(IFWL_Widget *pChild, int32_t nIndex ) { return ((CFWL_ContentImp*)m_pData)->InsertWidget(pChild, nIndex); } @@ -78,7 +78,7 @@ CFWL_ContentImp::CFWL_ContentImp(const CFWL_WidgetImpProperties &properties) CFWL_ContentImp::~CFWL_ContentImp() { } -FWL_ERR CFWL_ContentImp::InsertWidget(IFWL_Widget *pChild, FX_INT32 nIndex ) +FWL_ERR CFWL_ContentImp::InsertWidget(IFWL_Widget *pChild, int32_t nIndex ) { _FWL_RETURN_VALUE_IF_FAIL(pChild, FWL_ERR_Indefinite); pChild->SetParent(m_pInterface); diff --git a/xfa/src/fwl/src/core/fwl_formimp.cpp b/xfa/src/fwl/src/core/fwl_formimp.cpp index 2491999484..db78afa369 100644 --- a/xfa/src/fwl/src/core/fwl_formimp.cpp +++ b/xfa/src/fwl/src/core/fwl_formimp.cpp @@ -326,7 +326,7 @@ FWL_ERR CFWL_FormImp::DrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMat _FWL_RETURN_VALUE_IF_FAIL(m_pProperties->m_pThemeProvider, FWL_ERR_Indefinite); IFWL_ThemeProvider *pTheme = m_pProperties->m_pThemeProvider; FX_BOOL bInactive = !IsActive(); - FX_INT32 iState = bInactive ? FWL_PARTSTATE_FRM_Inactive : FWL_PARTSTATE_FRM_Normal; + int32_t iState = bInactive ? FWL_PARTSTATE_FRM_Inactive : FWL_PARTSTATE_FRM_Normal; if ((m_pProperties->m_dwStyleExes & FWL_STYLEEXT_FRM_NoDrawClient) == 0) { DrawBackground(pGraphics, pTheme); } @@ -599,7 +599,7 @@ CFWL_SysBtn* CFWL_FormImp::GetSysBtnByState(FX_DWORD dwState) } return NULL; } -CFWL_SysBtn* CFWL_FormImp::GetSysBtnByIndex(FX_INT32 nIndex) +CFWL_SysBtn* CFWL_FormImp::GetSysBtnByIndex(int32_t nIndex) { if (nIndex < 0) { return NULL; @@ -616,7 +616,7 @@ CFWL_SysBtn* CFWL_FormImp::GetSysBtnByIndex(FX_INT32 nIndex) } return (CFWL_SysBtn*) arrBtn[nIndex]; } -FX_INT32 CFWL_FormImp::GetSysBtnIndex(CFWL_SysBtn *pBtn) +int32_t CFWL_FormImp::GetSysBtnIndex(CFWL_SysBtn *pBtn) { CFX_PtrArray arrBtn; if (m_pMinBox) { @@ -989,12 +989,12 @@ CFWL_FormDelegate::CFWL_FormDelegate(CFWL_FormImp *pOwner) : m_pOwner(pOwner) { } -FX_INT32 CFWL_FormDelegate::OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_FormDelegate::OnProcessMessage(CFWL_Message *pMessage) { #ifdef FWL_UseMacSystemBorder _FWL_RETURN_VALUE_IF_FAIL(pMessage, 0); FX_DWORD dwMsgCode = pMessage->GetClassID(); - FX_INT32 iRet = 1; + int32_t iRet = 1; switch (dwMsgCode) { case FWL_MSGHASH_Activate: { m_pOwner->m_pProperties->m_dwStates &= ~FWL_WGTSTATE_Deactivated; @@ -1011,7 +1011,7 @@ FX_INT32 CFWL_FormDelegate::OnProcessMessage(CFWL_Message *pMessage) #else _FWL_RETURN_VALUE_IF_FAIL(pMessage, 0); FX_DWORD dwMsgCode = pMessage->GetClassID(); - FX_INT32 iRet = 1; + int32_t iRet = 1; switch (dwMsgCode) { case FWL_MSGHASH_Activate: { m_pOwner->m_pProperties->m_dwStates &= ~FWL_WGTSTATE_Deactivated; diff --git a/xfa/src/fwl/src/core/fwl_gridimp.cpp b/xfa/src/fwl/src/core/fwl_gridimp.cpp index 18ade073a4..56eb655231 100644 --- a/xfa/src/fwl/src/core/fwl_gridimp.cpp +++ b/xfa/src/fwl/src/core/fwl_gridimp.cpp @@ -27,19 +27,19 @@ FWL_ERR IFWL_Grid::Initialize(CFWL_WidgetImpProperties &properties) ((CFWL_GridImp*)m_pData)->SetInterface(this); return ((CFWL_GridImp*)m_pData)->Initialize(); } -FWL_HGRIDCOLROW IFWL_Grid::InsertColRow(FX_BOOL bColumn, FX_INT32 nIndex ) +FWL_HGRIDCOLROW IFWL_Grid::InsertColRow(FX_BOOL bColumn, int32_t nIndex ) { return ((CFWL_GridImp*)m_pData)->InsertColRow(bColumn, nIndex); } -FX_INT32 IFWL_Grid::CountColRows(FX_BOOL bColumn) +int32_t IFWL_Grid::CountColRows(FX_BOOL bColumn) { return ((CFWL_GridImp*)m_pData)->CountColRows(bColumn); } -FWL_HGRIDCOLROW IFWL_Grid::GetColRow(FX_BOOL bColumn, FX_INT32 nIndex) +FWL_HGRIDCOLROW IFWL_Grid::GetColRow(FX_BOOL bColumn, int32_t nIndex) { return ((CFWL_GridImp*)m_pData)->GetColRow(bColumn, nIndex); } -FX_INT32 IFWL_Grid::GetIndex(FWL_HGRIDCOLROW hColRow) +int32_t IFWL_Grid::GetIndex(FWL_HGRIDCOLROW hColRow) { return ((CFWL_GridImp*)m_pData)->GetIndex(hColRow); } @@ -75,19 +75,19 @@ FX_BOOL IFWL_Grid::IsColumn(FWL_HGRIDCOLROW hColRow) { return ((CFWL_GridImp*)m_pData)->IsColumn(hColRow); } -FX_INT32 IFWL_Grid::GetWidgetPos(IFWL_Widget *pWidget, FX_BOOL bColumn) +int32_t IFWL_Grid::GetWidgetPos(IFWL_Widget *pWidget, FX_BOOL bColumn) { return ((CFWL_GridImp*)m_pData)->GetWidgetPos(pWidget, bColumn); } -FWL_ERR IFWL_Grid::SetWidgetPos(IFWL_Widget *pWidget, FX_INT32 iPos, FX_BOOL bColumn) +FWL_ERR IFWL_Grid::SetWidgetPos(IFWL_Widget *pWidget, int32_t iPos, FX_BOOL bColumn) { return ((CFWL_GridImp*)m_pData)->SetWidgetPos(pWidget, iPos, bColumn); } -FX_INT32 IFWL_Grid::GetWidgetSpan(IFWL_Widget *pWidget, FX_BOOL bColumn) +int32_t IFWL_Grid::GetWidgetSpan(IFWL_Widget *pWidget, FX_BOOL bColumn) { return ((CFWL_GridImp*)m_pData)->GetWidgetSpan(pWidget, bColumn); } -FWL_ERR IFWL_Grid::SetWidgetSpan(IFWL_Widget *pWidget, FX_INT32 iSpan, FX_BOOL bColumn) +FWL_ERR IFWL_Grid::SetWidgetSpan(IFWL_Widget *pWidget, int32_t iSpan, FX_BOOL bColumn) { return ((CFWL_GridImp*)m_pData)->SetWidgetSpan(pWidget, iSpan , bColumn); } @@ -163,13 +163,13 @@ CFWL_GridImp::CFWL_GridImp(const CFWL_WidgetImpProperties &properties) } CFWL_GridImp::~CFWL_GridImp() { - FX_INT32 iCount = m_Columns.GetSize(); - for (FX_INT32 i = 0; i < iCount; i++) { + int32_t iCount = m_Columns.GetSize(); + for (int32_t i = 0; i < iCount; i++) { delete (CFWL_GridColRow *) m_Columns[i]; } m_Columns.RemoveAll(); iCount = m_Rows.GetSize(); - for (FX_INT32 j = 0; j < iCount; j++) { + for (int32_t j = 0; j < iCount; j++) { delete (CFWL_GridColRow*) m_Rows[j]; } m_Rows.RemoveAll(); @@ -251,8 +251,8 @@ FWL_ERR CFWL_GridImp::DrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMat FX_BOOL bDrawLine = FALSE; CFX_Path path; path.Create(); - FX_INT32 iColumns = m_Columns.GetSize(); - for (FX_INT32 i = 1; i < iColumns; i++) { + int32_t iColumns = m_Columns.GetSize(); + for (int32_t i = 1; i < iColumns; i++) { CFWL_GridColRow *pColRow = (CFWL_GridColRow*)m_Columns[i]; if (!pColRow) { continue; @@ -265,8 +265,8 @@ FWL_ERR CFWL_GridImp::DrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMat pColRow->m_fActualPos, m_pProperties->m_rtWidget.height); } - FX_INT32 iRows = m_Rows.GetSize(); - for (FX_INT32 j = 1; j < iRows; j++) { + int32_t iRows = m_Rows.GetSize(); + for (int32_t j = 1; j < iRows; j++) { CFWL_GridColRow *pColRow = (CFWL_GridColRow*)m_Rows[j]; if (!pColRow) { continue; @@ -288,7 +288,7 @@ FWL_ERR CFWL_GridImp::DrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMat pGraphics->RestoreGraphState(); return FWL_ERR_Succeeded; } -FWL_ERR CFWL_GridImp::InsertWidget(IFWL_Widget *pChild, FX_INT32 nIndex ) +FWL_ERR CFWL_GridImp::InsertWidget(IFWL_Widget *pChild, int32_t nIndex ) { _FWL_RETURN_VALUE_IF_FAIL(pChild, FWL_ERR_Indefinite); CFWL_ContentImp::InsertWidget(pChild, nIndex); @@ -306,12 +306,12 @@ FWL_ERR CFWL_GridImp::RemoveWidget(IFWL_Widget* pWidget) if (CFWL_GridWidgetInfo *pInfo = (CFWL_GridWidgetInfo*)m_mapWidgetInfo.GetValueAt(pWidget)) { m_mapWidgetInfo.RemoveKey(pWidget); delete pInfo; - FX_INT32 nIndex = m_Widgets.Find(pWidget); + int32_t nIndex = m_Widgets.Find(pWidget); m_Widgets.RemoveAt(nIndex, 1); } return FWL_ERR_Succeeded; } -FWL_HGRIDCOLROW CFWL_GridImp::InsertColRow(FX_BOOL bColumn, FX_INT32 nIndex ) +FWL_HGRIDCOLROW CFWL_GridImp::InsertColRow(FX_BOOL bColumn, int32_t nIndex ) { if (bColumn) { if (nIndex < 0 || nIndex > m_Columns.GetSize()) { @@ -328,14 +328,14 @@ FWL_HGRIDCOLROW CFWL_GridImp::InsertColRow(FX_BOOL bColumn, FX_INT32 nIndex ) m_Rows.InsertAt(nIndex, pRow, 1); return (FWL_HGRIDCOLROW)pRow; } -FX_INT32 CFWL_GridImp::CountColRows(FX_BOOL bColumn) +int32_t CFWL_GridImp::CountColRows(FX_BOOL bColumn) { if (bColumn) { return m_Columns.GetSize(); } return m_Rows.GetSize(); } -FWL_HGRIDCOLROW CFWL_GridImp::GetColRow(FX_BOOL bColumn, FX_INT32 nIndex) +FWL_HGRIDCOLROW CFWL_GridImp::GetColRow(FX_BOOL bColumn, int32_t nIndex) { if (bColumn) { if (nIndex < 0 || nIndex >= m_Columns.GetSize()) { @@ -348,7 +348,7 @@ FWL_HGRIDCOLROW CFWL_GridImp::GetColRow(FX_BOOL bColumn, FX_INT32 nIndex) } return (FWL_HGRIDCOLROW)m_Rows[nIndex]; } -FX_INT32 CFWL_GridImp::GetIndex(FWL_HGRIDCOLROW hColRow) +int32_t CFWL_GridImp::GetIndex(FWL_HGRIDCOLROW hColRow) { if (IsColumn(hColRow)) { return m_Columns.Find(hColRow); @@ -402,7 +402,7 @@ FWL_ERR CFWL_GridImp::SetMaxSize(FWL_HGRIDCOLROW hColRow, FX_FLOAT fSize, FWL_GR } FX_BOOL CFWL_GridImp::DeleteColRow(FWL_HGRIDCOLROW hColRow) { - FX_INT32 nIndex = m_Columns.Find(hColRow); + int32_t nIndex = m_Columns.Find(hColRow); if (nIndex >= 0) { m_Columns.RemoveAt(nIndex); delete (CFWL_GridColRow*)hColRow; @@ -420,7 +420,7 @@ FX_BOOL CFWL_GridImp::IsColumn(FWL_HGRIDCOLROW hColRow) { return m_Columns.Find(hColRow) != -1; } -FX_INT32 CFWL_GridImp::GetWidgetPos(IFWL_Widget *pWidget, FX_BOOL bColumn) +int32_t CFWL_GridImp::GetWidgetPos(IFWL_Widget *pWidget, FX_BOOL bColumn) { CFWL_GridWidgetInfo *pInfo = (CFWL_GridWidgetInfo*)GetWidgetInfo(pWidget); if (pInfo) { @@ -428,7 +428,7 @@ FX_INT32 CFWL_GridImp::GetWidgetPos(IFWL_Widget *pWidget, FX_BOOL bColumn) } return -1; } -FWL_ERR CFWL_GridImp::SetWidgetPos(IFWL_Widget *pWidget, FX_INT32 iPos, FX_BOOL bColumn) +FWL_ERR CFWL_GridImp::SetWidgetPos(IFWL_Widget *pWidget, int32_t iPos, FX_BOOL bColumn) { CFWL_GridWidgetInfo *pInfo = (CFWL_GridWidgetInfo*)GetWidgetInfo(pWidget); if (pInfo) { @@ -436,7 +436,7 @@ FWL_ERR CFWL_GridImp::SetWidgetPos(IFWL_Widget *pWidget, FX_INT32 iPos, FX_BOOL } return FWL_ERR_Succeeded; } -FX_INT32 CFWL_GridImp::GetWidgetSpan(IFWL_Widget *pWidget, FX_BOOL bColumn) +int32_t CFWL_GridImp::GetWidgetSpan(IFWL_Widget *pWidget, FX_BOOL bColumn) { CFWL_GridWidgetInfo *pInfo = (CFWL_GridWidgetInfo*)GetWidgetInfo(pWidget); if (pInfo) { @@ -444,7 +444,7 @@ FX_INT32 CFWL_GridImp::GetWidgetSpan(IFWL_Widget *pWidget, FX_BOOL bColumn) } return 0; } -FWL_ERR CFWL_GridImp::SetWidgetSpan(IFWL_Widget *pWidget, FX_INT32 iSpan, FX_BOOL bColumn) +FWL_ERR CFWL_GridImp::SetWidgetSpan(IFWL_Widget *pWidget, int32_t iSpan, FX_BOOL bColumn) { CFWL_GridWidgetInfo *pInfo = (CFWL_GridWidgetInfo*)GetWidgetInfo(pWidget); if (pInfo) { @@ -511,7 +511,7 @@ CFWL_GridWidgetInfo* CFWL_GridImp::GetWidgetInfo(IFWL_Widget* pWidget) { return (CFWL_GridWidgetInfo*)m_mapWidgetInfo.GetValueAt(pWidget); } -void CFWL_GridImp::ProcFixedColRow(CFWL_GridColRow *pColRow, FX_INT32 nIndex, FX_FLOAT fColRowSize, FX_BOOL bColumn) +void CFWL_GridImp::ProcFixedColRow(CFWL_GridColRow *pColRow, int32_t nIndex, FX_FLOAT fColRowSize, FX_BOOL bColumn) { pColRow->m_fActualSize = fColRowSize; FX_POSITION ps = m_mapWidgetInfo.GetStartPosition(); @@ -530,7 +530,7 @@ void CFWL_GridImp::ProcFixedColRow(CFWL_GridColRow *pColRow, FX_INT32 nIndex, FX } } } -void CFWL_GridImp::ProcAutoColRow(CFWL_GridColRow *pColRow, FX_INT32 nIndex, FX_BOOL bColumn) +void CFWL_GridImp::ProcAutoColRow(CFWL_GridColRow *pColRow, int32_t nIndex, FX_BOOL bColumn) { _FWL_RETURN_IF_FAIL(pColRow); FX_FLOAT fMaxSize = 0, fWidgetSize = 0; @@ -562,7 +562,7 @@ void CFWL_GridImp::ProcAutoColRow(CFWL_GridColRow *pColRow, FX_INT32 nIndex, FX_ } SetColRowActualSize(pColRow, fMaxSize); } -void CFWL_GridImp::ProcScaledColRow(CFWL_GridColRow *pColRow, FX_INT32 nIndex, FX_FLOAT fColRowSize, FX_BOOL bColumn) +void CFWL_GridImp::ProcScaledColRow(CFWL_GridColRow *pColRow, int32_t nIndex, FX_FLOAT fColRowSize, FX_BOOL bColumn) { if (fColRowSize > 0) { ProcFixedColRow(pColRow, nIndex, fColRowSize, bColumn); @@ -655,7 +655,7 @@ FX_FLOAT CFWL_GridImp::ProcessColumns(FX_FLOAT fWidth) if (fWidth <= 0) { return ProcessUnCertainColumns(); } - FX_INT32 iColumns = m_Columns.GetSize(); + int32_t iColumns = m_Columns.GetSize(); if (iColumns < 1) { return fWidth; } @@ -664,7 +664,7 @@ FX_FLOAT CFWL_GridImp::ProcessColumns(FX_FLOAT fWidth) CFX_PtrArray autoColumns; CFX_PtrArray scaledColumns; FX_FLOAT fScaledColumnNum = 0; - for (FX_INT32 i = 0; i < iColumns; i++) { + for (int32_t i = 0; i < iColumns; i++) { CFWL_GridColRow *pColRow = (CFWL_GridColRow*)m_Columns[i]; if (!pColRow) { continue; @@ -698,9 +698,9 @@ FX_FLOAT CFWL_GridImp::ProcessColumns(FX_FLOAT fWidth) } CFX_PtrArray spanAutoColumns; FX_FLOAT fSpanSize = 0; - FX_INT32 iAutoColRows = 0; - FX_INT32 iScaledColRows = 0; - for (FX_INT32 i = 0; i < pInfo->m_iColumnSpan; i++) { + int32_t iAutoColRows = 0; + int32_t iScaledColRows = 0; + for (int32_t i = 0; i < pInfo->m_iColumnSpan; i++) { CFWL_GridColRow *pColumn = (CFWL_GridColRow*)GetColRow(TRUE, pInfo->m_iColumn + i); if (!pColumn) { break; @@ -724,8 +724,8 @@ FX_FLOAT CFWL_GridImp::ProcessColumns(FX_FLOAT fWidth) } } } - FX_INT32 iAutoCols = autoColumns.GetSize(); - for (FX_INT32 k = 0; k < iAutoCols; k++) { + int32_t iAutoCols = autoColumns.GetSize(); + for (int32_t k = 0; k < iAutoCols; k++) { fAutoWidth += ((CFWL_GridColRow*)autoColumns[k])->m_fActualSize; } FX_FLOAT fScaledWidth = fWidth - fFixedWidth - fAutoWidth; @@ -739,7 +739,7 @@ FX_FLOAT CFWL_GridImp::ProcessRows(FX_FLOAT fHeight) if (fHeight <= 0) { return ProcessUnCertainRows(); } - FX_INT32 iRows = m_Rows.GetSize(); + int32_t iRows = m_Rows.GetSize(); if (iRows < 1) { return fHeight; } @@ -748,7 +748,7 @@ FX_FLOAT CFWL_GridImp::ProcessRows(FX_FLOAT fHeight) CFX_PtrArray autoRows; CFX_PtrArray scaledRows; FX_FLOAT fScaledRowNum = 0; - for (FX_INT32 i = 0; i < iRows; i++) { + for (int32_t i = 0; i < iRows; i++) { CFWL_GridColRow *pColRow = (CFWL_GridColRow*)m_Rows[i]; if (!pColRow) { continue; @@ -783,9 +783,9 @@ FX_FLOAT CFWL_GridImp::ProcessRows(FX_FLOAT fHeight) } CFX_PtrArray spanAutoRows; FX_FLOAT fSpanSize = 0; - FX_INT32 iAutoColRows = 0; - FX_INT32 iScaledColRows = 0; - for (FX_INT32 i = 0; i < pInfo->m_iRowSpan; i++) { + int32_t iAutoColRows = 0; + int32_t iScaledColRows = 0; + for (int32_t i = 0; i < pInfo->m_iRowSpan; i++) { CFWL_GridColRow *pRow = (CFWL_GridColRow*)GetColRow(FALSE, pInfo->m_iRow + i); if (!pRow) { break; @@ -809,8 +809,8 @@ FX_FLOAT CFWL_GridImp::ProcessRows(FX_FLOAT fHeight) } } } - FX_INT32 iAutoRows = autoRows.GetSize(); - for (FX_INT32 k = 0; k < iAutoRows; k++) { + int32_t iAutoRows = autoRows.GetSize(); + for (int32_t k = 0; k < iAutoRows; k++) { fAutoHeigt += ((CFWL_GridColRow*)autoRows[k])->m_fActualSize; } FX_FLOAT fScaledHeight = fHeight - fFixedHeight - fAutoHeigt; @@ -821,7 +821,7 @@ FX_FLOAT CFWL_GridImp::ProcessRows(FX_FLOAT fHeight) } FX_FLOAT CFWL_GridImp::ProcessUnCertainColumns() { - FX_INT32 iColumns = m_Columns.GetSize(); + int32_t iColumns = m_Columns.GetSize(); if (iColumns < 1) { CFWL_GridColRow *pColRow = new CFWL_GridColRow; pColRow->m_Size.eUnit = FWL_GRIDUNIT_Auto; @@ -835,7 +835,7 @@ FX_FLOAT CFWL_GridImp::ProcessUnCertainColumns() CFX_PtrArray scaledColumns; FX_FLOAT fScaledColumnNum = 0; FX_FLOAT fScaledMaxPerWidth = 0; - for (FX_INT32 i = 0; i < iColumns; i++) { + for (int32_t i = 0; i < iColumns; i++) { CFWL_GridColRow *pColRow = (CFWL_GridColRow*)m_Columns[i]; if (!pColRow) { continue; @@ -867,7 +867,7 @@ FX_FLOAT CFWL_GridImp::ProcessUnCertainColumns() } } iColumns = scaledColumns.GetSize(); - for (FX_INT32 j = 0; j < iColumns; j++) { + for (int32_t j = 0; j < iColumns; j++) { CFWL_GridColRow *pColRow = (CFWL_GridColRow*)scaledColumns[j]; if (!pColRow) { continue; @@ -886,9 +886,9 @@ FX_FLOAT CFWL_GridImp::ProcessUnCertainColumns() CFX_PtrArray spanScaledColumns; FX_FLOAT fSpanSize = 0; FX_FLOAT fScaledSum = 0; - FX_INT32 iAutoColRows = 0; - FX_INT32 iScaledColRows = 0; - for (FX_INT32 i = 0; i < pInfo->m_iColumnSpan; i++) { + int32_t iAutoColRows = 0; + int32_t iScaledColRows = 0; + for (int32_t i = 0; i < pInfo->m_iColumnSpan; i++) { CFWL_GridColRow *pColumn = (CFWL_GridColRow*)GetColRow(TRUE, pInfo->m_iColumn + i); if (!pColumn) { break; @@ -919,20 +919,20 @@ FX_FLOAT CFWL_GridImp::ProcessUnCertainColumns() } } FX_FLOAT fAutoWidth = 0; - FX_INT32 iAutoCols = autoColumns.GetSize(); - for (FX_INT32 m = 0; m < iAutoCols; m++) { + int32_t iAutoCols = autoColumns.GetSize(); + for (int32_t m = 0; m < iAutoCols; m++) { fAutoWidth += ((CFWL_GridColRow*)autoColumns[m])->m_fActualSize; } FX_FLOAT fScaledWidth = 0; iColumns = scaledColumns.GetSize(); - for (FX_INT32 n = 0; n < iColumns; n++) { + for (int32_t n = 0; n < iColumns; n++) { fScaledWidth += ((CFWL_GridColRow*)scaledColumns[n])->m_fActualSize; } return fFixedWidth + fAutoWidth + fScaledWidth; } FX_FLOAT CFWL_GridImp::ProcessUnCertainRows() { - FX_INT32 iRows = m_Rows.GetSize(); + int32_t iRows = m_Rows.GetSize(); if (iRows < 1) { CFWL_GridColRow *pColRow = new CFWL_GridColRow; pColRow->m_Size.eUnit = FWL_GRIDUNIT_Auto; @@ -946,7 +946,7 @@ FX_FLOAT CFWL_GridImp::ProcessUnCertainRows() CFX_PtrArray scaledRows; FX_FLOAT fScaledRowNum = 0; FX_FLOAT fScaledMaxPerHeight = 0; - for (FX_INT32 i = 0; i < iRows; i++) { + for (int32_t i = 0; i < iRows; i++) { CFWL_GridColRow *pColRow = (CFWL_GridColRow*)m_Rows[i]; if (!pColRow) { continue; @@ -978,7 +978,7 @@ FX_FLOAT CFWL_GridImp::ProcessUnCertainRows() } } iRows = scaledRows.GetSize(); - for (FX_INT32 j = 0; j < iRows; j++) { + for (int32_t j = 0; j < iRows; j++) { CFWL_GridColRow *pColRow = (CFWL_GridColRow*)scaledRows[j]; if (!pColRow) { continue; @@ -997,9 +997,9 @@ FX_FLOAT CFWL_GridImp::ProcessUnCertainRows() CFX_PtrArray spanScaledRows; FX_FLOAT fSpanSize = 0; FX_FLOAT fScaledSum = 0; - FX_INT32 iAutoColRows = 0; - FX_INT32 iScaledColRows = 0; - for (FX_INT32 i = 0; i < pInfo->m_iRowSpan; i++) { + int32_t iAutoColRows = 0; + int32_t iScaledColRows = 0; + for (int32_t i = 0; i < pInfo->m_iRowSpan; i++) { CFWL_GridColRow *pRow = (CFWL_GridColRow*)GetColRow(FALSE, pInfo->m_iRow + i); if (!pRow) { break; @@ -1030,13 +1030,13 @@ FX_FLOAT CFWL_GridImp::ProcessUnCertainRows() } } FX_FLOAT fAutoHeigt = 0; - FX_INT32 iAutoRows = autoRows.GetSize(); - for (FX_INT32 m = 0; m < iAutoRows; m++) { + int32_t iAutoRows = autoRows.GetSize(); + for (int32_t m = 0; m < iAutoRows; m++) { fAutoHeigt += ((CFWL_GridColRow*)autoRows[m])->m_fActualSize; } FX_FLOAT fScaledHeight = 0; iRows = scaledRows.GetSize(); - for (FX_INT32 n = 0; n < iRows; n++) { + for (int32_t n = 0; n < iRows; n++) { fScaledHeight += ((CFWL_GridColRow*)scaledRows[n])->m_fActualSize; } return fFixedHeight + fAutoHeigt + fScaledHeight; @@ -1086,8 +1086,8 @@ FX_FLOAT CFWL_GridImp::SetWidgetActualHeight(CFWL_GridWidgetInfo* pInfo, FX_FLOA void CFWL_GridImp::SetAllWidgetsRect() { FX_FLOAT fStartLeft = 0; - FX_INT32 iColumns = m_Columns.GetSize(); - for (FX_INT32 i = 0; i < iColumns; i++) { + int32_t iColumns = m_Columns.GetSize(); + for (int32_t i = 0; i < iColumns; i++) { CFWL_GridColRow *pColRow = (CFWL_GridColRow*)m_Columns[i]; if (!pColRow) { continue; @@ -1096,8 +1096,8 @@ void CFWL_GridImp::SetAllWidgetsRect() fStartLeft += pColRow->m_fActualSize; } FX_FLOAT fStartTop = 0; - FX_INT32 iRows = m_Rows.GetSize(); - for (FX_INT32 j = 0; j < iRows; j++) { + int32_t iRows = m_Rows.GetSize(); + for (int32_t j = 0; j < iRows; j++) { CFWL_GridColRow *pColRow = (CFWL_GridColRow*)m_Rows[j]; if (!pColRow) { continue; @@ -1125,7 +1125,7 @@ void CFWL_GridImp::SetAllWidgetsRect() } FX_FLOAT fColumnWidth = 0; if (iColumns > 0) { - for (FX_INT32 j = 0; j < pInfo->m_iColumnSpan; j++) { + for (int32_t j = 0; j < pInfo->m_iColumnSpan; j++) { CFWL_GridColRow *pCol = (CFWL_GridColRow*)GetColRow(TRUE, pInfo->m_iColumn + j); if (!pCol) { break; @@ -1137,7 +1137,7 @@ void CFWL_GridImp::SetAllWidgetsRect() } FX_FLOAT fRowHeight = 0; if (iRows > 0) { - for (FX_INT32 k = 0; k < pInfo->m_iRowSpan; k++) { + for (int32_t k = 0; k < pInfo->m_iRowSpan; k++) { CFWL_GridColRow *pR = (CFWL_GridColRow*)GetColRow(FALSE, pInfo->m_iRow + k); if (!pR) { break; @@ -1220,20 +1220,20 @@ FX_BOOL CFWL_GridImp::IsGrid(IFWL_Widget* pWidget) } void CFWL_GridImp::SetSpanAutoColRowSize(const CFX_PtrArray &spanAutos, FX_FLOAT fTotalSize) { - FX_INT32 iAutoColRows = spanAutos.GetSize(); + int32_t iAutoColRows = spanAutos.GetSize(); if (iAutoColRows < 1) { return; } CFX_PtrArray autoNoMinMaxs; FX_FLOAT fAutoPer = fTotalSize / iAutoColRows; - for (FX_INT32 j = 0; j < iAutoColRows; j++) { + for (int32_t j = 0; j < iAutoColRows; j++) { CFWL_GridColRow *pColumn = (CFWL_GridColRow*)spanAutos[j]; FX_FLOAT fOrgSize = pColumn->m_fActualSize; if (SetColRowActualSize(pColumn, pColumn->m_fActualSize + fAutoPer, TRUE)) { autoNoMinMaxs.Add(pColumn); } else { fTotalSize -= pColumn->m_fActualSize - fOrgSize; - FX_INT32 iNoMinMax = iAutoColRows - (j + 1 - autoNoMinMaxs.GetSize()); + int32_t iNoMinMax = iAutoColRows - (j + 1 - autoNoMinMaxs.GetSize()); if (iNoMinMax > 0 && fTotalSize > 0) { fAutoPer = fTotalSize / iNoMinMax; } else { @@ -1241,11 +1241,11 @@ void CFWL_GridImp::SetSpanAutoColRowSize(const CFX_PtrArray &spanAutos, FX_FLOAT } } } - FX_INT32 iNormals = autoNoMinMaxs.GetSize(); + int32_t iNormals = autoNoMinMaxs.GetSize(); if (fTotalSize > 0) { if (iNormals == iAutoColRows) { fAutoPer = fTotalSize / iNormals; - for (FX_INT32 k = 0; k < iNormals; k++) { + for (int32_t k = 0; k < iNormals; k++) { CFWL_GridColRow *pColumn = (CFWL_GridColRow*)autoNoMinMaxs[k]; pColumn->m_fActualSize += fAutoPer; } @@ -1257,20 +1257,20 @@ void CFWL_GridImp::SetSpanAutoColRowSize(const CFX_PtrArray &spanAutos, FX_FLOAT } void CFWL_GridImp::SetSpanScaledColRowSize(const CFX_PtrArray &spanScaleds, FX_FLOAT fTotalSize, FX_FLOAT fTotalScaledNum) { - FX_INT32 iScaledColRows = spanScaleds.GetSize(); + int32_t iScaledColRows = spanScaleds.GetSize(); if (iScaledColRows < 1) { return; } CFX_PtrArray autoNoMinMaxs; FX_FLOAT fPerSize = fTotalSize / fTotalScaledNum; - for (FX_INT32 i = 0; i < iScaledColRows; i++) { + for (int32_t i = 0; i < iScaledColRows; i++) { CFWL_GridColRow *pColRow = (CFWL_GridColRow*)spanScaleds[i]; if (SetColRowActualSize(pColRow, pColRow->m_fActualSize + fPerSize * pColRow->m_Size.fLength, TRUE)) { autoNoMinMaxs.Add(pColRow); } else { fTotalSize -= pColRow->m_fActualSize; fTotalScaledNum -= pColRow->m_Size.fLength; - FX_INT32 iNoMinMax = iScaledColRows - (i + 1 - autoNoMinMaxs.GetSize()); + int32_t iNoMinMax = iScaledColRows - (i + 1 - autoNoMinMaxs.GetSize()); if (iNoMinMax > 0 && fTotalSize > 0) { fPerSize = fTotalSize / fTotalScaledNum; } else { @@ -1278,11 +1278,11 @@ void CFWL_GridImp::SetSpanScaledColRowSize(const CFX_PtrArray &spanScaleds, FX_F } } } - FX_INT32 iNormals = autoNoMinMaxs.GetSize(); + int32_t iNormals = autoNoMinMaxs.GetSize(); if (fTotalSize > 0) { if (iNormals == iScaledColRows) { fPerSize = fTotalSize / fTotalScaledNum; - for (FX_INT32 j = 0; j < iNormals; j++) { + for (int32_t j = 0; j < iNormals; j++) { CFWL_GridColRow *pColumn = (CFWL_GridColRow*)autoNoMinMaxs[j]; pColumn->m_fActualSize += fPerSize * pColumn->m_Size.fLength; } @@ -1294,13 +1294,13 @@ void CFWL_GridImp::SetSpanScaledColRowSize(const CFX_PtrArray &spanScaleds, FX_F } void CFWL_GridImp::SetScaledColRowsSize(const CFX_PtrArray &spanScaleds, FX_FLOAT fTotalSize, FX_FLOAT fTotalScaledNum) { - FX_INT32 iScaledColRows = spanScaleds.GetSize(); + int32_t iScaledColRows = spanScaleds.GetSize(); if (iScaledColRows < 1) { return; } CFX_PtrArray autoNoMinMaxs; FX_FLOAT fPerSize = fTotalSize / fTotalScaledNum; - for (FX_INT32 i = 0; i < iScaledColRows; i++) { + for (int32_t i = 0; i < iScaledColRows; i++) { CFWL_GridColRow *pColRow = (CFWL_GridColRow*)spanScaleds[i]; if (!pColRow) { continue; @@ -1312,7 +1312,7 @@ void CFWL_GridImp::SetScaledColRowsSize(const CFX_PtrArray &spanScaleds, FX_FLOA } else { fTotalSize -= pColRow->m_fActualSize - fOrgSize; fTotalScaledNum -= pColRow->m_Size.fLength; - FX_INT32 iNoMinMax = iScaledColRows - (i + 1 - autoNoMinMaxs.GetSize()); + int32_t iNoMinMax = iScaledColRows - (i + 1 - autoNoMinMaxs.GetSize()); if (iNoMinMax > 0 && fTotalSize > 0) { fPerSize = fTotalSize / fTotalScaledNum; } else { @@ -1320,11 +1320,11 @@ void CFWL_GridImp::SetScaledColRowsSize(const CFX_PtrArray &spanScaleds, FX_FLOA } } } - FX_INT32 iNormals = autoNoMinMaxs.GetSize(); + int32_t iNormals = autoNoMinMaxs.GetSize(); if (fTotalSize > 0) { if (iNormals == iScaledColRows) { fPerSize = fTotalSize / fTotalScaledNum; - for (FX_INT32 i = 0; i < iNormals; i++) { + for (int32_t i = 0; i < iNormals; i++) { CFWL_GridColRow *pColRow = (CFWL_GridColRow*)autoNoMinMaxs[i]; if (!pColRow) { continue; @@ -1342,7 +1342,7 @@ CFWL_GridDelegate::CFWL_GridDelegate(CFWL_GridImp *pOwner) : m_pOwner(pOwner) { } -FX_INT32 CFWL_GridDelegate::OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_GridDelegate::OnProcessMessage(CFWL_Message *pMessage) { if (pMessage->GetClassID() != FWL_MSGHASH_Mouse) { return 0; diff --git a/xfa/src/fwl/src/core/fwl_noteimp.cpp b/xfa/src/fwl/src/core/fwl_noteimp.cpp index 101516fcac..4a9c138d86 100644 --- a/xfa/src/fwl/src/core/fwl_noteimp.cpp +++ b/xfa/src/fwl/src/core/fwl_noteimp.cpp @@ -26,7 +26,7 @@ FX_BOOL CFWL_NoteLoop::PreProcessMessage(CFWL_Message *pMessage) } return TranslateAccelerator(pMessage); } -FWL_ERR CFWL_NoteLoop::Idle(FX_INT32 count) +FWL_ERR CFWL_NoteLoop::Idle(int32_t count) { #if (_FX_OS_==_FX_WIN32_DESKTOP_) if (count <= 0) @@ -123,7 +123,7 @@ CFWL_NoteDriver::~CFWL_NoteDriver() FX_BOOL CFWL_NoteDriver::SendNote(CFWL_Note *pNote) { if (pNote->IsEvent()) { - FX_INT32 iCount = m_eventTargets.GetCount(); + int32_t iCount = m_eventTargets.GetCount(); if (iCount < 1) { return TRUE; } @@ -169,29 +169,29 @@ FX_BOOL CFWL_NoteDriver::PostMessage(CFWL_Message *pMessage) #define FWL_NoteDriver_EventKey 1100 FWL_ERR CFWL_NoteDriver::RegisterEventTarget(IFWL_Widget *pListener, IFWL_Widget *pEventSource , FX_DWORD dwFilter ) { - FX_DWORD dwkey = (FX_DWORD)(FX_UINTPTR)pListener->GetPrivateData((FX_LPVOID)(FX_UINTPTR)FWL_NoteDriver_EventKey); + FX_DWORD dwkey = (FX_DWORD)(uintptr_t)pListener->GetPrivateData((FX_LPVOID)(uintptr_t)FWL_NoteDriver_EventKey); if (dwkey == 0) { FX_LPVOID random = FX_Random_MT_Start(0); dwkey = rand(); FX_Random_MT_Close(random); - pListener->SetPrivateData((FX_LPVOID)(FX_UINTPTR)FWL_NoteDriver_EventKey, (FX_LPVOID)(FX_UINTPTR)dwkey, NULL); + pListener->SetPrivateData((FX_LPVOID)(uintptr_t)FWL_NoteDriver_EventKey, (FX_LPVOID)(uintptr_t)dwkey, NULL); } CFWL_EventTarget *value = NULL; - if (!m_eventTargets.Lookup((void*)(FX_UINTPTR)dwkey, (FX_LPVOID&)value)) { + if (!m_eventTargets.Lookup((void*)(uintptr_t)dwkey, (FX_LPVOID&)value)) { value = FX_NEW CFWL_EventTarget(this, pListener); - m_eventTargets.SetAt((void*)(FX_UINTPTR)dwkey, value); + m_eventTargets.SetAt((void*)(uintptr_t)dwkey, value); } value->SetEventSource(pEventSource, dwFilter); return FWL_ERR_Succeeded; } FWL_ERR CFWL_NoteDriver::UnregisterEventTarget(IFWL_Widget *pListener) { - FX_DWORD dwkey = (FX_DWORD)(FX_UINTPTR)pListener->GetPrivateData((FX_LPVOID)(FX_UINTPTR)FWL_NoteDriver_EventKey); + FX_DWORD dwkey = (FX_DWORD)(uintptr_t)pListener->GetPrivateData((FX_LPVOID)(uintptr_t)FWL_NoteDriver_EventKey); if (dwkey == 0) { return FWL_ERR_Indefinite; } CFWL_EventTarget *value = NULL; - if (m_eventTargets.Lookup((void*)(FX_UINTPTR)dwkey, (FX_LPVOID&)value)) { + if (m_eventTargets.Lookup((void*)(uintptr_t)dwkey, (FX_LPVOID&)value)) { value->FlagInvalid(); } return FWL_ERR_Succeeded; @@ -200,11 +200,11 @@ void CFWL_NoteDriver::ClearEventTargets(FX_BOOL bRemoveAll) { ClearInvalidEventTargets(bRemoveAll); } -FX_INT32 CFWL_NoteDriver::GetQueueMaxSize() const +int32_t CFWL_NoteDriver::GetQueueMaxSize() const { return m_maxSize; } -FWL_ERR CFWL_NoteDriver::SetQueueMaxSize(const FX_INT32 size) +FWL_ERR CFWL_NoteDriver::SetQueueMaxSize(const int32_t size) { m_maxSize = size; return FWL_ERR_Succeeded; @@ -220,7 +220,7 @@ FWL_ERR CFWL_NoteDriver::PushNoteLoop(IFWL_NoteLoop *pNoteLoop) } IFWL_NoteLoop* CFWL_NoteDriver::PopNoteLoop() { - FX_INT32 pos = m_noteLoopQueue.GetSize(); + int32_t pos = m_noteLoopQueue.GetSize(); _FWL_RETURN_VALUE_IF_FAIL(pos > 0, NULL); IFWL_NoteLoop * p = (IFWL_NoteLoop *) m_noteLoopQueue.GetAt(pos - 1); m_noteLoopQueue.RemoveAt(pos - 1); @@ -282,7 +282,7 @@ FWL_ERR CFWL_NoteDriver::Run() } #elif (_FX_OS_==_FX_WIN32_DESKTOP_ || _FX_OS_ == _FX_WIN64_) FX_BOOL bIdle = TRUE; - FX_INT32 iIdleCount = 0; + int32_t iIdleCount = 0; CFWL_NoteLoop *pTopLoop = NULL; for (;;) { pTopLoop = GetTopLoop(); @@ -364,8 +364,8 @@ void CFWL_NoteDriver::NotifyTargetDestroy(IFWL_Widget *pNoteTarget) m_pGrab = NULL; } UnregisterEventTarget(pNoteTarget); - FX_INT32 count = m_forms.GetSize(); - for (FX_INT32 nIndex = 0; nIndex < count; nIndex ++) { + int32_t count = m_forms.GetSize(); + for (int32_t nIndex = 0; nIndex < count; nIndex ++) { CFWL_FormImp *pForm = (CFWL_FormImp*)m_forms[nIndex]; if (!pForm) { continue; @@ -398,7 +398,7 @@ FWL_ERR CFWL_NoteDriver::RegisterForm(CFWL_WidgetImp *pForm) FWL_ERR CFWL_NoteDriver::UnRegisterForm(CFWL_WidgetImp *pForm) { _FWL_RETURN_VALUE_IF_FAIL(pForm, FWL_ERR_Indefinite); - FX_INT32 nIndex = m_forms.Find(pForm); + int32_t nIndex = m_forms.Find(pForm); if (nIndex < 0) { return FWL_ERR_Indefinite; } @@ -434,11 +434,11 @@ FX_BOOL CFWL_NoteDriver::UnqueueMessage(CFWL_NoteLoop *pNoteLoop) } CFWL_NoteLoop* CFWL_NoteDriver::GetTopLoop() { - FX_INT32 size = m_noteLoopQueue.GetSize(); + int32_t size = m_noteLoopQueue.GetSize(); _FWL_RETURN_VALUE_IF_FAIL(size > 0, NULL); return (CFWL_NoteLoop*)m_noteLoopQueue[size - 1]; } -FX_INT32 CFWL_NoteDriver::CountLoop() +int32_t CFWL_NoteDriver::CountLoop() { return m_noteLoopQueue.GetSize(); } @@ -542,7 +542,7 @@ FX_BOOL CFWL_NoteDriver::DoDeactivate(CFWL_MsgDeactivate *pMsg, IFWL_Widget *pMe if (m_bFullScreen) { return FALSE; } - FX_INT32 iTrackLoop = m_noteLoopQueue.GetSize(); + int32_t iTrackLoop = m_noteLoopQueue.GetSize(); _FWL_RETURN_VALUE_IF_FAIL(iTrackLoop > 0, FALSE); if (iTrackLoop == 1) { if (pMessageForm->IsInstance(FX_WSTRC(L"FWL_FORMPROXY"))) { @@ -760,8 +760,8 @@ FX_BOOL CFWL_NoteDriver::IsValidMessage(CFWL_Message *pMessage) if (pMessage->GetClassID() == FWL_MSGHASH_Post) { return TRUE; } - FX_INT32 iCount = m_noteLoopQueue.GetSize(); - for (FX_INT32 i = 0; i < iCount; i ++) { + int32_t iCount = m_noteLoopQueue.GetSize(); + for (int32_t i = 0; i < iCount; i ++) { CFWL_NoteLoop *pNoteLoop = (CFWL_NoteLoop*)m_noteLoopQueue[i]; CFWL_WidgetImp *pForm = pNoteLoop->GetForm(); if (pForm && (pForm->GetInterface() == pMessage->m_pDstTarget)) { @@ -769,7 +769,7 @@ FX_BOOL CFWL_NoteDriver::IsValidMessage(CFWL_Message *pMessage) } } iCount = m_forms.GetSize(); - for (FX_INT32 j = 0; j < iCount; j ++) { + for (int32_t j = 0; j < iCount; j ++) { CFWL_FormImp *pForm = (CFWL_FormImp*)m_forms[j]; if (pForm->GetInterface() == pMessage->m_pDstTarget) { return TRUE; @@ -779,7 +779,7 @@ FX_BOOL CFWL_NoteDriver::IsValidMessage(CFWL_Message *pMessage) } IFWL_Widget* CFWL_NoteDriver::GetMessageForm(IFWL_Widget *pDstTarget) { - FX_INT32 iTrackLoop = m_noteLoopQueue.GetSize(); + int32_t iTrackLoop = m_noteLoopQueue.GetSize(); _FWL_RETURN_VALUE_IF_FAIL(iTrackLoop > 0, NULL); IFWL_Widget *pMessageForm = NULL; if (iTrackLoop > 1) { @@ -812,16 +812,16 @@ class CFWL_CoreToopTipDP : public IFWL_ToolTipDP { public: FWL_ERR GetCaption(IFWL_Widget *pWidget, CFX_WideString &wsCaption); - FX_INT32 GetInitialDelay(IFWL_Widget *pWidget); - FX_INT32 GetAutoPopDelay(IFWL_Widget *pWidget); + int32_t GetInitialDelay(IFWL_Widget *pWidget); + int32_t GetAutoPopDelay(IFWL_Widget *pWidget); CFX_DIBitmap* GetToolTipIcon(IFWL_Widget *pWidget); CFX_SizeF GetToolTipIconSize(IFWL_Widget *pWidget); CFX_RectF GetAnchor(); CFWL_CoreToopTipDP(); CFX_WideString m_wsCaption; - FX_INT32 m_nInitDelayTime; - FX_INT32 m_nAutoPopDelayTime; + int32_t m_nInitDelayTime; + int32_t m_nAutoPopDelayTime; CFX_RectF m_fAnchor; }; CFWL_CoreToopTipDP::CFWL_CoreToopTipDP() @@ -835,11 +835,11 @@ FWL_ERR CFWL_CoreToopTipDP::GetCaption(IFWL_Widget *pWidget, CFX_WideString &wsC wsCaption = m_wsCaption; return FWL_ERR_Succeeded; } -FX_INT32 CFWL_CoreToopTipDP::GetInitialDelay(IFWL_Widget *pWidget) +int32_t CFWL_CoreToopTipDP::GetInitialDelay(IFWL_Widget *pWidget) { return m_nInitDelayTime; } -FX_INT32 CFWL_CoreToopTipDP::GetAutoPopDelay(IFWL_Widget *pWidget) +int32_t CFWL_CoreToopTipDP::GetAutoPopDelay(IFWL_Widget *pWidget) { return m_nAutoPopDelayTime; } @@ -861,7 +861,7 @@ CFWL_EventTarget::~CFWL_EventTarget() { m_eventSources.RemoveAll(); } -FX_INT32 CFWL_EventTarget::SetEventSource(IFWL_Widget *pSource, FX_DWORD dwFilter) +int32_t CFWL_EventTarget::SetEventSource(IFWL_Widget *pSource, FX_DWORD dwFilter) { if (pSource) { m_eventSources.SetAt(pSource, dwFilter); @@ -997,8 +997,8 @@ FX_ERR CFWL_ToolTipContainer::RemoveToolTipTarget(IFWL_ToolTipTarget *pTarget) } FX_BOOL CFWL_ToolTipContainer::HasToolTip(IFWL_Widget *pWedget) { - FX_INT32 iCount = m_arrWidget.GetSize(); - for (FX_INT32 i = 0; i < iCount; i++) { + int32_t iCount = m_arrWidget.GetSize(); + for (int32_t i = 0; i < iCount; i++) { IFWL_ToolTipTarget *p = (IFWL_ToolTipTarget *)m_arrWidget[i]; if (p->GetWidget() == pWedget) { pCurTarget = p; @@ -1079,12 +1079,12 @@ IFWL_ToolTipTarget* CFWL_ToolTipContainer::GetCurrentToolTipTarget() { return pCurTarget; } -FX_ERR CFWL_ToolTipContainer::SetToolTipInitialDelay(FX_INT32 nDelayTime) +FX_ERR CFWL_ToolTipContainer::SetToolTipInitialDelay(int32_t nDelayTime) { m_ToolTipDp->m_nInitDelayTime = nDelayTime; return FWL_ERR_Succeeded; } -FX_ERR CFWL_ToolTipContainer::SetToolTipAutoPopDelay(FX_INT32 nDelayTime) +FX_ERR CFWL_ToolTipContainer::SetToolTipAutoPopDelay(int32_t nDelayTime) { m_ToolTipDp->m_nAutoPopDelayTime = nDelayTime; return FWL_ERR_Succeeded; @@ -1097,11 +1097,11 @@ FWL_ERR FWL_RemoveToolTipTarget(IFWL_ToolTipTarget *pTarget) { return CFWL_ToolTipContainer::getInstance()->RemoveToolTipTarget(pTarget); } -FWL_ERR FWL_SetToolTipInitialDelay(FX_INT32 nDelayTime) +FWL_ERR FWL_SetToolTipInitialDelay(int32_t nDelayTime) { return CFWL_ToolTipContainer::getInstance()->SetToolTipInitialDelay(nDelayTime); } -FWL_ERR FWL_SetToolTipAutoPopDelay(FX_INT32 nDelayTime) +FWL_ERR FWL_SetToolTipAutoPopDelay(int32_t nDelayTime) { return CFWL_ToolTipContainer::getInstance()->SetToolTipAutoPopDelay(nDelayTime); } diff --git a/xfa/src/fwl/src/core/fwl_sdadapterimp.cpp b/xfa/src/fwl/src/core/fwl_sdadapterimp.cpp index fae5a2a6db..25636ea582 100644 --- a/xfa/src/fwl/src/core/fwl_sdadapterimp.cpp +++ b/xfa/src/fwl/src/core/fwl_sdadapterimp.cpp @@ -63,7 +63,7 @@ FWL_ERR CFWL_SDAdapterWidgetMgr::RepaintWidget(IFWL_Widget *pWidget, const CFX_R { return FWL_ERR_Succeeded; } -FWL_ERR CFWL_SDAdapterWidgetMgr::Exit(FX_INT32 iExitCode) +FWL_ERR CFWL_SDAdapterWidgetMgr::Exit(int32_t iExitCode) { return FWL_ERR_Succeeded; } @@ -135,11 +135,11 @@ FWL_ERR CFWL_SDAdapterWidgetMgr::InitMenu(IFWL_Menu *pMenu, IFWL_MenuDP *pMenuD { return FWL_ERR_Succeeded; } -FWL_ERR CFWL_SDAdapterWidgetMgr::UpdateMenu(IFWL_Menu *pMenu, FX_LPCVOID hItem, FX_INT32 iType) +FWL_ERR CFWL_SDAdapterWidgetMgr::UpdateMenu(IFWL_Menu *pMenu, FX_LPCVOID hItem, int32_t iType) { return FWL_ERR_Succeeded; } -FX_INT32 CFWL_SDAdapterWidgetMgr::TrackPopupMenu(IFWL_Menu *pMenu, IFWL_MenuDP *pMenuData) +int32_t CFWL_SDAdapterWidgetMgr::TrackPopupMenu(IFWL_Menu *pMenu, IFWL_MenuDP *pMenuData) { return 0; } @@ -173,11 +173,11 @@ FWL_ERR CFWL_SDAdapterThreadMgr::Suspend(FWL_HTHREAD hThread) { return FWL_ERR_Succeeded; } -FWL_ERR CFWL_SDAdapterThreadMgr::Kill(FWL_HTHREAD hThread, FX_INT32 iExitCode) +FWL_ERR CFWL_SDAdapterThreadMgr::Kill(FWL_HTHREAD hThread, int32_t iExitCode) { return FWL_ERR_Succeeded; } -FWL_ERR CFWL_SDAdapterThreadMgr::Stop(FWL_HTHREAD hThread, FX_INT32 iExitCode) +FWL_ERR CFWL_SDAdapterThreadMgr::Stop(FWL_HTHREAD hThread, int32_t iExitCode) { return FWL_ERR_Succeeded; } diff --git a/xfa/src/fwl/src/core/fwl_threadimp.cpp b/xfa/src/fwl/src/core/fwl_threadimp.cpp index 66f4144c71..7d9609a9cd 100644 --- a/xfa/src/fwl/src/core/fwl_threadimp.cpp +++ b/xfa/src/fwl/src/core/fwl_threadimp.cpp @@ -35,7 +35,7 @@ FWL_ERR CFWL_Thread::Run(FWL_HTHREAD hThread) } CFWL_ControlThread * CFWL_NoteThread::_assistantThreadHandler = NULL; FWL_HTHREAD CFWL_NoteThread::_assistantThread = NULL; -FX_INT32 CFWL_NoteThread::_refCount = 0; +int32_t CFWL_NoteThread::_refCount = 0; IFWL_NoteThread* IFWL_NoteThread::Create() { return (IFWL_NoteThread*) FX_NEW CFWL_NoteThread; @@ -92,7 +92,7 @@ FWL_ERR FWL_SuspendThread(FWL_HTHREAD hThread) _FWL_RETURN_VALUE_IF_FAIL(ThreadMgr, FWL_ERR_Indefinite); return ThreadMgr->Suspend(hThread); } -FWL_ERR FWL_KillThread(FWL_HTHREAD hThread, FX_INT32 iExitCode) +FWL_ERR FWL_KillThread(FWL_HTHREAD hThread, int32_t iExitCode) { IFWL_AdapterNative * Native = FWL_GetAdapterNative(); _FWL_RETURN_VALUE_IF_FAIL(Native, FWL_ERR_Indefinite); @@ -100,7 +100,7 @@ FWL_ERR FWL_KillThread(FWL_HTHREAD hThread, FX_INT32 iExitCode) _FWL_RETURN_VALUE_IF_FAIL(ThreadMgr, FWL_ERR_Indefinite); return ThreadMgr->Kill(hThread, iExitCode); } -FWL_ERR FWL_StopThread(FWL_HTHREAD hThread, FX_INT32 iExitCode) +FWL_ERR FWL_StopThread(FWL_HTHREAD hThread, int32_t iExitCode) { IFWL_AdapterNative * Native = FWL_GetAdapterNative(); _FWL_RETURN_VALUE_IF_FAIL(Native, FWL_ERR_Indefinite); @@ -144,15 +144,15 @@ FWL_ERR FWL_WaitSemaphore(FWL_HSEMAPHORE hSemaphore) { return ((IFWL_AdapterSemaphore*)hSemaphore)->Wait(); } -FWL_ERR FWL_PostSemaphore(FWL_HSEMAPHORE hSemaphore, FX_INT32 down ) +FWL_ERR FWL_PostSemaphore(FWL_HSEMAPHORE hSemaphore, int32_t down ) { return ((IFWL_AdapterSemaphore*)hSemaphore)->Post(); } -FWL_ERR FWL_GetSemaphoreValue(FWL_HSEMAPHORE hSemaphore, FX_INT32 &value) +FWL_ERR FWL_GetSemaphoreValue(FWL_HSEMAPHORE hSemaphore, int32_t &value) { return ((IFWL_AdapterSemaphore*)hSemaphore)->Value((FX_DWORD &)value); } -FWL_ERR FWL_ResetSemaphore(FWL_HSEMAPHORE hSemaphore, FX_INT32 init) +FWL_ERR FWL_ResetSemaphore(FWL_HSEMAPHORE hSemaphore, int32_t init) { return ((IFWL_AdapterSemaphore*)hSemaphore)->Reset(init); } diff --git a/xfa/src/fwl/src/core/fwl_timerimp.cpp b/xfa/src/fwl/src/core/fwl_timerimp.cpp index e0300f4316..300ab5cefb 100644 --- a/xfa/src/fwl/src/core/fwl_timerimp.cpp +++ b/xfa/src/fwl/src/core/fwl_timerimp.cpp @@ -18,7 +18,7 @@ FWL_HTIMER FWL_StartTimer(IFWL_Timer *pTimer, FX_DWORD dwElapse, FX_BOOL bImmedi pAdapterTimerMgr->Start(pTimer, dwElapse, hTimer, bImmediately); return hTimer; } -FX_INT32 FWL_StopTimer(FWL_HTIMER hTimer) +int32_t FWL_StopTimer(FWL_HTIMER hTimer) { IFWL_AdapterNative *pAdapterNative = FWL_GetAdapterNative(); _FWL_RETURN_VALUE_IF_FAIL(pAdapterNative, FWL_ERR_Indefinite); diff --git a/xfa/src/fwl/src/core/fwl_widgetimp.cpp b/xfa/src/fwl/src/core/fwl_widgetimp.cpp index 61186a7ede..4659e6bc9e 100644 --- a/xfa/src/fwl/src/core/fwl_widgetimp.cpp +++ b/xfa/src/fwl/src/core/fwl_widgetimp.cpp @@ -450,8 +450,8 @@ FWL_ERR CFWL_WidgetImp::GetMatrix(CFX_Matrix &matrix, FX_BOOL bGlobal ) matrix.Reset(); CFX_Matrix ctmOnParent; CFX_RectF rect; - FX_INT32 count = parents.GetSize(); - for (FX_INT32 i = count - 2; i >= 0; i--) { + int32_t count = parents.GetSize(); + for (int32_t i = count - 2; i >= 0; i--) { parent = (IFWL_Widget *) parents.GetAt(i); parent->GetMatrix(ctmOnParent, FALSE); parent->GetWidgetRect(rect); @@ -708,7 +708,7 @@ CFWL_WidgetImp* CFWL_WidgetImp::GetSameAncestor(CFWL_WidgetImp *pWidget) arr2.Add(pAncestor); relation = pAncestor->IsPopup() ? FWL_WGTRELATION_Owner : FWL_WGTRELATION_Parent; } while ((pAncestor = (CFWL_WidgetImp*)m_pWidgetMgr->GetWidget(pAncestor->m_pInterface, relation)) != NULL); - for (FX_INT32 i = 0; i < arr1.GetSize(); i ++) { + for (int32_t i = 0; i < arr1.GetSize(); i ++) { FX_LPVOID pVoid = arr1[i]; if (arr2.Find(pVoid) < 0) { continue; @@ -755,7 +755,7 @@ FX_BOOL CFWL_WidgetImp::TransformFromOuter(FX_FLOAT &fx, FX_FLOAT &fy) #define FWL_WGT_CalcHeight 2048 #define FWL_WGT_CalcWidth 2048 #define FWL_WGT_CalcMultiLineDefWidth 120.0f -CFX_SizeF CFWL_WidgetImp::CalcTextSize(const CFX_WideString &wsText, IFWL_ThemeProvider *pTheme, FX_BOOL bMultiLine , FX_INT32 iLineWidth ) +CFX_SizeF CFWL_WidgetImp::CalcTextSize(const CFX_WideString &wsText, IFWL_ThemeProvider *pTheme, FX_BOOL bMultiLine , int32_t iLineWidth ) { CFX_SizeF sz; sz.Set(0, 0); @@ -775,7 +775,7 @@ CFX_SizeF CFWL_WidgetImp::CalcTextSize(const CFX_WideString &wsText, IFWL_ThemeP sz.y = rect.height; return sz; } -void CFWL_WidgetImp::CalcTextRect(const CFX_WideString &wsText, IFWL_ThemeProvider *pTheme, FX_DWORD dwTTOStyles, FX_INT32 iTTOAlign, CFX_RectF &rect) +void CFWL_WidgetImp::CalcTextRect(const CFX_WideString &wsText, IFWL_ThemeProvider *pTheme, FX_DWORD dwTTOStyles, int32_t iTTOAlign, CFX_RectF &rect) { CFWL_ThemeText calPart; calPart.m_pWidget = m_pInterface; @@ -955,7 +955,7 @@ void CFWL_WidgetImp::Repaint(const CFX_RectF *pRect ) m_pWidgetMgr->RepaintWidget(m_pInterface, &rect); } void CFWL_WidgetImp::DrawBackground(CFX_Graphics *pGraphics, - FX_INT32 iPartBk, + int32_t iPartBk, IFWL_ThemeProvider *pTheme, const CFX_Matrix *pMatrix ) { @@ -972,7 +972,7 @@ void CFWL_WidgetImp::DrawBackground(CFX_Graphics *pGraphics, pTheme->DrawBackground(¶m); } void CFWL_WidgetImp::DrawBorder(CFX_Graphics *pGraphics, - FX_INT32 iPartBorder, + int32_t iPartBorder, IFWL_ThemeProvider *pTheme, const CFX_Matrix *pMatrix ) { @@ -989,7 +989,7 @@ void CFWL_WidgetImp::DrawBorder(CFX_Graphics *pGraphics, pTheme->DrawBackground(¶m); } void CFWL_WidgetImp::DrawEdge(CFX_Graphics *pGraphics, - FX_INT32 iPartEdge, + int32_t iPartEdge, IFWL_ThemeProvider *pTheme, const CFX_Matrix *pMatrix ) { @@ -1051,7 +1051,7 @@ FX_BOOL CFWL_WidgetImp::IsParent(IFWL_Widget *pParent) CFWL_WidgetImpDelegate::CFWL_WidgetImpDelegate() { } -FX_INT32 CFWL_WidgetImpDelegate::OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_WidgetImpDelegate::OnProcessMessage(CFWL_Message *pMessage) { _FWL_RETURN_VALUE_IF_FAIL(pMessage->m_pDstTarget, 0); CFWL_WidgetImp *pWidget = (CFWL_WidgetImp*)((IFWL_TargetData*)pMessage->m_pDstTarget)->GetData(); diff --git a/xfa/src/fwl/src/core/fwl_widgetmgrimp.cpp b/xfa/src/fwl/src/core/fwl_widgetmgrimp.cpp index 283c328008..a1e1d45718 100644 --- a/xfa/src/fwl/src/core/fwl_widgetmgrimp.cpp +++ b/xfa/src/fwl/src/core/fwl_widgetmgrimp.cpp @@ -59,12 +59,12 @@ CFWL_WidgetMgr::~CFWL_WidgetMgr() m_pDelegate = NULL; } } -FX_INT32 CFWL_WidgetMgr::CountWidgets(IFWL_Widget *pParent ) +int32_t CFWL_WidgetMgr::CountWidgets(IFWL_Widget *pParent ) { CFWL_WidgetMgrItem *pParentItem = GetWidgetMgrItem(pParent); return TravelWidgetMgr(pParentItem, NULL, NULL); } -IFWL_Widget* CFWL_WidgetMgr::GetWidget(FX_INT32 nIndex, IFWL_Widget *pParent ) +IFWL_Widget* CFWL_WidgetMgr::GetWidget(int32_t nIndex, IFWL_Widget *pParent ) { CFWL_WidgetMgrItem *pParentItem = GetWidgetMgrItem(pParent); IFWL_Widget *pWidget = NULL; @@ -138,19 +138,19 @@ IFWL_Widget* CFWL_WidgetMgr::GetWidget(IFWL_Widget *pWidget, FWL_WGTRELATION eRe } return pRet; } -FX_INT32 CFWL_WidgetMgr::GetWidgetIndex(IFWL_Widget *pWidget) +int32_t CFWL_WidgetMgr::GetWidgetIndex(IFWL_Widget *pWidget) { CFWL_WidgetMgrItem *pItem = GetWidgetMgrItem(pWidget); _FWL_RETURN_VALUE_IF_FAIL(pItem, -1); return TravelWidgetMgr(pItem->pParent, NULL, pItem); } -FX_BOOL CFWL_WidgetMgr::SetWidgetIndex(IFWL_Widget *pWidget, FX_INT32 nIndex) +FX_BOOL CFWL_WidgetMgr::SetWidgetIndex(IFWL_Widget *pWidget, int32_t nIndex) { CFWL_WidgetMgrItem *pItem = GetWidgetMgrItem(pWidget); _FWL_RETURN_VALUE_IF_FAIL(pItem, FALSE); _FWL_RETURN_VALUE_IF_FAIL(pItem->pParent, FALSE); CFWL_WidgetMgrItem *pChild = pItem->pParent->pChild; - FX_INT32 i = 0; + int32_t i = 0; while (pChild) { if (pChild == pItem) { if (i == nIndex) { @@ -264,7 +264,7 @@ void CFWL_WidgetMgr::AddWidget(IFWL_Widget *pWidget) pItem->pParent = pParentItem; SetWidgetIndex(pWidget, -1); } -void CFWL_WidgetMgr::InsertWidget(IFWL_Widget *pParent, IFWL_Widget *pChild, FX_INT32 nIndex ) +void CFWL_WidgetMgr::InsertWidget(IFWL_Widget *pParent, IFWL_Widget *pChild, int32_t nIndex ) { CFWL_WidgetMgrItem *pParentItem = GetWidgetMgrItem(pParent); if (!pParentItem) { @@ -462,7 +462,7 @@ FX_BOOL CFWL_WidgetMgr::IsIdleMessage_Native() { return m_pAdapter->IsIdleMessage(); } -FWL_ERR CFWL_WidgetMgr::Exit_Native(FX_INT32 iExitCode) +FWL_ERR CFWL_WidgetMgr::Exit_Native(int32_t iExitCode) { return m_pAdapter->Exit(iExitCode); } @@ -527,9 +527,9 @@ IFWL_Widget* CFWL_WidgetMgr::nextTab(IFWL_Widget *parent, IFWL_Widget *focus, FX } return NULL; } -FX_INT32 CFWL_WidgetMgr::CountRadioButtonGroup(IFWL_Widget *pFirst) +int32_t CFWL_WidgetMgr::CountRadioButtonGroup(IFWL_Widget *pFirst) { - FX_INT32 iRet = 0; + int32_t iRet = 0; IFWL_Widget *pChild = pFirst; while (pChild) { if ((pChild->GetStyles() & FWL_WGTSTYLE_Group) && pChild->GetClassID() == 3811304691) { @@ -580,7 +580,7 @@ void CFWL_WidgetMgr::GetSameGroupRadioButton(IFWL_Widget *pRadioButton, CFX_PtrA if (!pFirst) { pFirst = pRadioButton; } - FX_INT32 iGroup = CountRadioButtonGroup(pFirst); + int32_t iGroup = CountRadioButtonGroup(pFirst); if (iGroup < 2) { if (pFirst->GetClassID() == 3811304691) { group.Add(pFirst); @@ -636,12 +636,12 @@ CFWL_WidgetMgrItem* CFWL_WidgetMgr::GetWidgetMgrItem(IFWL_Widget *pWidget) { return (CFWL_WidgetMgrItem*)m_mapWidgetItem.GetValueAt(pWidget); } -FX_INT32 CFWL_WidgetMgr::TravelWidgetMgr(CFWL_WidgetMgrItem *pParent, FX_INT32 *pIndex, CFWL_WidgetMgrItem *pItem, IFWL_Widget **pWidget ) +int32_t CFWL_WidgetMgr::TravelWidgetMgr(CFWL_WidgetMgrItem *pParent, int32_t *pIndex, CFWL_WidgetMgrItem *pItem, IFWL_Widget **pWidget ) { if (!pParent) { return 0; } - FX_INT32 iCount = 0; + int32_t iCount = 0; CFWL_WidgetMgrItem *pChild = pParent->pChild; while (pChild) { iCount ++; @@ -695,7 +695,7 @@ FWL_ERR CFWL_WidgetMgrDelegate::OnSetCapability(FX_DWORD dwCapability ) m_pWidgetMgr->m_dwCapability = dwCapability; return FWL_ERR_Succeeded; } -FX_INT32 CFWL_WidgetMgrDelegate::OnProcessMessageToForm(CFWL_Message *pMessage) +int32_t CFWL_WidgetMgrDelegate::OnProcessMessageToForm(CFWL_Message *pMessage) { _FWL_RETURN_VALUE_IF_FAIL(pMessage, 0); _FWL_RETURN_VALUE_IF_FAIL(pMessage->m_pDstTarget, 0); @@ -833,7 +833,7 @@ CFX_Graphics* CFWL_WidgetMgrDelegate::DrawWidgetBefore(IFWL_Widget *pWidget, CFX pItem->pOffscreen = FX_NEW CFX_Graphics; CFX_RectF rect; pWidget->GetWidgetRect(rect); - pItem->pOffscreen->Create((FX_INT32)rect.width, (FX_INT32)rect.height, FXDIB_Argb); + pItem->pOffscreen->Create((int32_t)rect.width, (int32_t)rect.height, FXDIB_Argb); } CFX_RectF rect; pGraphics->GetClipRect(rect); @@ -893,7 +893,7 @@ FX_BOOL CFWL_WidgetMgrDelegate::IsNeedRepaint(IFWL_Widget *pWidget, CFX_Matrix * FX_BOOL bOrginPtIntersectWidthChild = FALSE; FX_BOOL bOrginPtIntersectWidthDirty = rtDirty.Contains(rtWidget.left, rtWidget.top); static FWL_NeedRepaintHitData hitPoint[FWL_NEEDREPAINTHIT_Point]; - static FX_INT32 iSize = sizeof(FWL_NeedRepaintHitData); + static int32_t iSize = sizeof(FWL_NeedRepaintHitData); FXSYS_memset(hitPoint, 0, iSize); FX_FLOAT fxPiece = rtWidget.width / FWL_NEEDREPAINTHIT_Piece; FX_FLOAT fyPiece = rtWidget.height / FWL_NEEDREPAINTHIT_Piece; @@ -928,7 +928,7 @@ FX_BOOL CFWL_WidgetMgrDelegate::IsNeedRepaint(IFWL_Widget *pWidget, CFX_Matrix * } else if (!(pChild->GetStates() & FWL_WGTSTATE_Invisible)) { rtChilds.Union(rect); } - for (FX_INT32 i = 0; i < FWL_NEEDREPAINTHIT_Point; i ++) { + for (int32_t i = 0; i < FWL_NEEDREPAINTHIT_Point; i ++) { if (hitPoint[i].bNotContainByDirty || hitPoint[i].bNotNeedRepaint) { continue; } @@ -950,8 +950,8 @@ FX_BOOL CFWL_WidgetMgrDelegate::IsNeedRepaint(IFWL_Widget *pWidget, CFX_Matrix * if (rtChilds.IsEmpty()) { return TRUE; } - FX_INT32 repaintPoint = FWL_NEEDREPAINTHIT_Point; - for (FX_INT32 i = 0; i < FWL_NEEDREPAINTHIT_Point; i ++) { + int32_t repaintPoint = FWL_NEEDREPAINTHIT_Point; + for (int32_t i = 0; i < FWL_NEEDREPAINTHIT_Point; i ++) { if (hitPoint[i].bNotNeedRepaint) { repaintPoint --; } @@ -1027,7 +1027,7 @@ FWL_ERR FWL_WidgetMgrSnapshot(IFWL_Widget *pWidget, const CFX_WideString *saveFi CFX_RectF r; pWidget->GetWidgetRect(r); CFX_Graphics gs; - gs.Create((FX_INT32)r.width, (FX_INT32)r.height, FXDIB_Argb); + gs.Create((int32_t)r.width, (int32_t)r.height, FXDIB_Argb); CFWL_WidgetMgr *widgetMgr = (CFWL_WidgetMgr*)FWL_GetWidgetMgr(); CFWL_WidgetMgrDelegate *delegate = widgetMgr->GetDelegate(); delegate->OnDrawWidget(pWidget, &gs, pMatrix); diff --git a/xfa/src/fwl/src/core/include/fwl_appimp.h b/xfa/src/fwl/src/core/include/fwl_appimp.h index edc2089252..e0f1f5977a 100644 --- a/xfa/src/fwl/src/core/include/fwl_appimp.h +++ b/xfa/src/fwl/src/core/include/fwl_appimp.h @@ -23,7 +23,7 @@ public: virtual IFWL_AdapterNative* GetAdapterNative(); virtual IFWL_WidgetMgr* GetWidgetMgr(); virtual FWL_ERR SetThemeProvider(IFWL_ThemeProvider* pThemeProvider); - virtual FWL_ERR Exit(FX_INT32 iExitCode = 0); + virtual FWL_ERR Exit(int32_t iExitCode = 0); IFWL_ThemeProvider* GetThemeProvider(); protected: CFWL_WidgetMgr *m_pWidgetMgr; diff --git a/xfa/src/fwl/src/core/include/fwl_contentimp.h b/xfa/src/fwl/src/core/include/fwl_contentimp.h index 0aaaf0e1b8..95a47a3796 100644 --- a/xfa/src/fwl/src/core/include/fwl_contentimp.h +++ b/xfa/src/fwl/src/core/include/fwl_contentimp.h @@ -15,7 +15,7 @@ public: CFWL_ContentImp(); CFWL_ContentImp(const CFWL_WidgetImpProperties &properties); virtual ~CFWL_ContentImp(); - virtual FWL_ERR InsertWidget(IFWL_Widget *pChild, FX_INT32 nIndex = -1); + virtual FWL_ERR InsertWidget(IFWL_Widget *pChild, int32_t nIndex = -1); virtual FWL_ERR RemoveWidget(IFWL_Widget *pWidget); virtual FWL_ERR RemoveAllWidgets(); virtual FWL_ERR GetMinSize(FX_FLOAT &fWidth, FX_FLOAT &fHeight); diff --git a/xfa/src/fwl/src/core/include/fwl_formimp.h b/xfa/src/fwl/src/core/include/fwl_formimp.h index b283c121e9..0cf9c9d25c 100644 --- a/xfa/src/fwl/src/core/include/fwl_formimp.h +++ b/xfa/src/fwl/src/core/include/fwl_formimp.h @@ -58,7 +58,7 @@ public: { bDisabled ? m_dwState |= FWL_SYSBUTTONSTATE_Disabled : m_dwState &= ~FWL_SYSBUTTONSTATE_Disabled; } - FX_INT32 GetPartState() + int32_t GetPartState() { return (IsDisabled() ? FWL_PARTSTATE_FRM_Disabled : (m_dwState + 1)); } @@ -116,8 +116,8 @@ protected: void CalcContentRect(CFX_RectF &rtContent); CFWL_SysBtn* GetSysBtnAtPoint(FX_FLOAT fx, FX_FLOAT fy); CFWL_SysBtn* GetSysBtnByState(FX_DWORD dwState); - CFWL_SysBtn* GetSysBtnByIndex(FX_INT32 nIndex); - FX_INT32 GetSysBtnIndex(CFWL_SysBtn *pBtn); + CFWL_SysBtn* GetSysBtnByIndex(int32_t nIndex); + int32_t GetSysBtnIndex(CFWL_SysBtn *pBtn); FX_FLOAT GetCaptionHeight(); void DrawCaptionText(CFX_Graphics *pGs, IFWL_ThemeProvider *pTheme, const CFX_Matrix* pMatrix = NULL); void DrawIconImage(CFX_Graphics *pGs, IFWL_ThemeProvider *pTheme, const CFX_Matrix* pMatrix = NULL); @@ -150,9 +150,9 @@ protected: RestoreInfo m_InfoStart; FX_FLOAT m_fCXBorder; FX_FLOAT m_fCYBorder; - FX_INT32 m_iCaptureBtn; - FX_INT32 m_iSysBox; - FX_INT32 m_eResizeType; + int32_t m_iCaptureBtn; + int32_t m_iSysBox; + int32_t m_eResizeType; FX_BOOL m_bLButtonDown; FX_BOOL m_bMaximized; FX_BOOL m_bSetMaximize; @@ -170,7 +170,7 @@ class CFWL_FormDelegate : public CFWL_WidgetImpDelegate { public: CFWL_FormDelegate(CFWL_FormImp *pOwner); - virtual FX_INT32 OnProcessMessage(CFWL_Message *pMessage); + virtual int32_t OnProcessMessage(CFWL_Message *pMessage); virtual FWL_ERR OnProcessEvent(CFWL_Event *pEvent); virtual FWL_ERR OnDrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); protected: diff --git a/xfa/src/fwl/src/core/include/fwl_gridimp.h b/xfa/src/fwl/src/core/include/fwl_gridimp.h index 1bd7ada04b..82aeb7ecdc 100644 --- a/xfa/src/fwl/src/core/include/fwl_gridimp.h +++ b/xfa/src/fwl/src/core/include/fwl_gridimp.h @@ -71,10 +71,10 @@ public: m_Size[FWL_GRIDSIZE_MaxHeight].fLength = 0; m_Margin[0] = m_Margin[1] = m_Margin[2] = m_Margin[3] = 0; } - FX_INT32 m_iColumn; - FX_INT32 m_iColumnSpan; - FX_INT32 m_iRow; - FX_INT32 m_iRowSpan; + int32_t m_iColumn; + int32_t m_iColumnSpan; + int32_t m_iRow; + int32_t m_iRowSpan; CFWL_GridLength m_Size[6]; FX_DWORD m_dwMarginFlag; FX_FLOAT m_Margin[4]; @@ -96,12 +96,12 @@ public: virtual FWL_ERR Update(); virtual FWL_ERR DrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); - virtual FWL_ERR InsertWidget(IFWL_Widget *pChild, FX_INT32 nIndex = -1); + virtual FWL_ERR InsertWidget(IFWL_Widget *pChild, int32_t nIndex = -1); virtual FWL_ERR RemoveWidget(IFWL_Widget *pWidget); - virtual FWL_HGRIDCOLROW InsertColRow(FX_BOOL bColumn, FX_INT32 nIndex = -1); - virtual FX_INT32 CountColRows(FX_BOOL bColumn); - virtual FWL_HGRIDCOLROW GetColRow(FX_BOOL bColumn, FX_INT32 nIndex); - virtual FX_INT32 GetIndex(FWL_HGRIDCOLROW hColRow); + virtual FWL_HGRIDCOLROW InsertColRow(FX_BOOL bColumn, int32_t nIndex = -1); + virtual int32_t CountColRows(FX_BOOL bColumn); + virtual FWL_HGRIDCOLROW GetColRow(FX_BOOL bColumn, int32_t nIndex); + virtual int32_t GetIndex(FWL_HGRIDCOLROW hColRow); virtual FX_FLOAT GetSize(FWL_HGRIDCOLROW hColRow, FWL_GRIDUNIT &eUnit); virtual FWL_ERR SetSize(FWL_HGRIDCOLROW hColRow, FX_FLOAT fSize, FWL_GRIDUNIT eUnit); virtual FX_FLOAT GetMinSize(FWL_HGRIDCOLROW hColRow, FWL_GRIDUNIT &eUnit); @@ -110,10 +110,10 @@ public: virtual FWL_ERR SetMaxSize(FWL_HGRIDCOLROW hColRow, FX_FLOAT fSize, FWL_GRIDUNIT eUnit); virtual FX_BOOL DeleteColRow(FWL_HGRIDCOLROW hColRow); virtual FX_BOOL IsColumn(FWL_HGRIDCOLROW hColRow); - virtual FX_INT32 GetWidgetPos(IFWL_Widget *pWidget, FX_BOOL bColumn); - virtual FWL_ERR SetWidgetPos(IFWL_Widget *pWidget, FX_INT32 iPos, FX_BOOL bColumn); - virtual FX_INT32 GetWidgetSpan(IFWL_Widget *pWidget, FX_BOOL bColumn); - virtual FWL_ERR SetWidgetSpan(IFWL_Widget *pWidget, FX_INT32 iSpan, FX_BOOL bColumn); + virtual int32_t GetWidgetPos(IFWL_Widget *pWidget, FX_BOOL bColumn); + virtual FWL_ERR SetWidgetPos(IFWL_Widget *pWidget, int32_t iPos, FX_BOOL bColumn); + virtual int32_t GetWidgetSpan(IFWL_Widget *pWidget, FX_BOOL bColumn); + virtual FWL_ERR SetWidgetSpan(IFWL_Widget *pWidget, int32_t iSpan, FX_BOOL bColumn); virtual FX_FLOAT GetWidgetSize(IFWL_Widget *pWidget, FWL_GRIDSIZE eSize, FWL_GRIDUNIT &eUnit); virtual FWL_ERR SetWidgetSize(IFWL_Widget *pWidget, FWL_GRIDSIZE eSize, FX_FLOAT fSize, FWL_GRIDUNIT eUit); virtual FX_BOOL GetWidgetMargin(IFWL_Widget *pWidget, FWL_GRIDMARGIN eMargin, FX_FLOAT &fMargin); @@ -123,9 +123,9 @@ public: virtual FWL_ERR SetGridSize(FWL_GRIDSIZE eSize, FX_FLOAT fSize, FWL_GRIDUNIT eUit); protected: CFWL_GridWidgetInfo* GetWidgetInfo(IFWL_Widget* pWidget); - void ProcFixedColRow(CFWL_GridColRow *pColRow, FX_INT32 nIndex, FX_FLOAT fColRowSize, FX_BOOL bColumn); - void ProcAutoColRow(CFWL_GridColRow *pColRow, FX_INT32 nIndex, FX_BOOL bColumn); - void ProcScaledColRow(CFWL_GridColRow *pColRow, FX_INT32 nIndex, FX_FLOAT fColRowSize, FX_BOOL bColumn); + void ProcFixedColRow(CFWL_GridColRow *pColRow, int32_t nIndex, FX_FLOAT fColRowSize, FX_BOOL bColumn); + void ProcAutoColRow(CFWL_GridColRow *pColRow, int32_t nIndex, FX_BOOL bColumn); + void ProcScaledColRow(CFWL_GridColRow *pColRow, int32_t nIndex, FX_FLOAT fColRowSize, FX_BOOL bColumn); void CalcWidgetWidth(IFWL_Widget *pWidget, CFWL_GridWidgetInfo *pInfo, FX_FLOAT fColunmWidth); void CalcWidgetHeigt(IFWL_Widget *pWidget, CFWL_GridWidgetInfo *pInfo, FX_FLOAT fRowHeigt); FX_FLOAT CalcAutoColumnWidgetWidth(IFWL_Widget *pWidget, CFWL_GridWidgetInfo* pInfo); @@ -153,7 +153,7 @@ class CFWL_GridDelegate : public CFWL_WidgetImpDelegate { public: CFWL_GridDelegate(CFWL_GridImp *pOwner); - virtual FX_INT32 OnProcessMessage(CFWL_Message *pMessage); + virtual int32_t OnProcessMessage(CFWL_Message *pMessage); virtual FWL_ERR OnDrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); protected: CFWL_GridImp *m_pOwner; diff --git a/xfa/src/fwl/src/core/include/fwl_noteimp.h b/xfa/src/fwl/src/core/include/fwl_noteimp.h index 08ab13d3e7..699840d27e 100644 --- a/xfa/src/fwl/src/core/include/fwl_noteimp.h +++ b/xfa/src/fwl/src/core/include/fwl_noteimp.h @@ -21,7 +21,7 @@ class CFWL_NoteLoop public: CFWL_NoteLoop(CFWL_WidgetImp *pForm = NULL); virtual FX_BOOL PreProcessMessage(CFWL_Message *pMessage); - virtual FWL_ERR Idle(FX_INT32 count); + virtual FWL_ERR Idle(int32_t count); CFWL_WidgetImp* GetForm(); FX_BOOL ContinueModal(); FWL_ERR EndModalLoop(); @@ -43,8 +43,8 @@ public: virtual FWL_ERR RegisterEventTarget(IFWL_Widget *pListener, IFWL_Widget *pEventSource = NULL, FX_DWORD dwFilter = FWL_EVENT_ALL_MASK); virtual FWL_ERR UnregisterEventTarget(IFWL_Widget *pListener); virtual void ClearEventTargets(FX_BOOL bRemoveAll); - virtual FX_INT32 GetQueueMaxSize() const; - virtual FWL_ERR SetQueueMaxSize(const FX_INT32 size); + virtual int32_t GetQueueMaxSize() const; + virtual FWL_ERR SetQueueMaxSize(const int32_t size); virtual IFWL_NoteThread* GetOwnerThread() const; virtual FWL_ERR PushNoteLoop(IFWL_NoteLoop *pNoteLoop); virtual IFWL_NoteLoop* PopNoteLoop(); @@ -62,7 +62,7 @@ public: FX_BOOL QueueMessage(CFWL_Message *pMessage); FX_BOOL UnqueueMessage(CFWL_NoteLoop *pNoteLoop); CFWL_NoteLoop* GetTopLoop(); - FX_INT32 CountLoop(); + int32_t CountLoop(); void SetHook(FWLMessageHookCallback callback, FX_LPVOID info); FX_BOOL ProcessMessage(CFWL_Message *pMessage); protected: @@ -86,8 +86,8 @@ protected: CFX_PtrArray m_noteQueue; CFX_PtrArray m_noteLoopQueue; CFX_MapPtrToPtr m_eventTargets; - FX_INT32 m_sendEventCalled; - FX_INT32 m_maxSize; + int32_t m_sendEventCalled; + int32_t m_maxSize; FX_BOOL m_bFullScreen; IFWL_Widget *m_pHover; IFWL_Widget *m_pFocus; @@ -107,7 +107,7 @@ public: { } ~CFWL_EventTarget(); - FX_INT32 SetEventSource(IFWL_Widget *pSource, FX_DWORD dwFilter = FWL_EVENT_ALL_MASK); + int32_t SetEventSource(IFWL_Widget *pSource, FX_DWORD dwFilter = FWL_EVENT_ALL_MASK); FX_BOOL ProcessEvent(CFWL_Event *pEvent); FX_BOOL IsFilterEvent(CFWL_Event *pEvent, FX_DWORD dwFilter); FX_BOOL IsInvalid() @@ -139,8 +139,8 @@ public: FX_BOOL ProcessEnter(CFWL_EvtMouse *pEvt, IFWL_Widget *pOwner); FX_BOOL ProcessLeave(CFWL_EvtMouse *pEvt); - FX_ERR SetToolTipInitialDelay(FX_INT32 iDelayTime); - FX_ERR SetToolTipAutoPopDelay(FX_INT32 iDelayTime); + FX_ERR SetToolTipInitialDelay(int32_t iDelayTime); + FX_ERR SetToolTipAutoPopDelay(int32_t iDelayTime); protected: CFWL_ToolTipContainer(); diff --git a/xfa/src/fwl/src/core/include/fwl_threadimp.h b/xfa/src/fwl/src/core/include/fwl_threadimp.h index e03e6c6e15..26acc54006 100644 --- a/xfa/src/fwl/src/core/include/fwl_threadimp.h +++ b/xfa/src/fwl/src/core/include/fwl_threadimp.h @@ -48,6 +48,6 @@ protected: FWL_HTHREAD m_hThread; static CFWL_ControlThread * _assistantThreadHandler; static FWL_HTHREAD _assistantThread; - static FX_INT32 _refCount; + static int32_t _refCount; }; #endif diff --git a/xfa/src/fwl/src/core/include/fwl_widgetimp.h b/xfa/src/fwl/src/core/include/fwl_widgetimp.h index 862bb53665..4d28722576 100644 --- a/xfa/src/fwl/src/core/include/fwl_widgetimp.h +++ b/xfa/src/fwl/src/core/include/fwl_widgetimp.h @@ -83,8 +83,8 @@ protected: CFX_SizeF GetOffsetFromAncestor(CFWL_WidgetImp *pAncestor); FX_BOOL TransformToOuter(FX_FLOAT &fx, FX_FLOAT &fy); FX_BOOL TransformFromOuter(FX_FLOAT &fx, FX_FLOAT &fy); - CFX_SizeF CalcTextSize(const CFX_WideString &wsText, IFWL_ThemeProvider *pTheme, FX_BOOL bMultiLine = FALSE, FX_INT32 iLineWidth = -1); - void CalcTextRect(const CFX_WideString &wsText, IFWL_ThemeProvider *pTheme, FX_DWORD dwTTOStyles, FX_INT32 iTTOAlign, CFX_RectF &rect); + CFX_SizeF CalcTextSize(const CFX_WideString &wsText, IFWL_ThemeProvider *pTheme, FX_BOOL bMultiLine = FALSE, int32_t iLineWidth = -1); + void CalcTextRect(const CFX_WideString &wsText, IFWL_ThemeProvider *pTheme, FX_DWORD dwTTOStyles, int32_t iTTOAlign, CFX_RectF &rect); void SetFocus(FX_BOOL bFocus); void SetGrab(FX_BOOL bSet); FX_BOOL GetPopupPos(FX_FLOAT fMinHeight, FX_FLOAT fMaxHeight, const CFX_RectF &rtAnchor, CFX_RectF &rtPopup); @@ -97,9 +97,9 @@ protected: void DispatchKeyEvent(CFWL_MsgKey *pNote); void DispatchEvent(CFWL_Event *pEvent); void Repaint(const CFX_RectF *pRect = NULL); - void DrawBackground(CFX_Graphics *pGraphics, FX_INT32 iPartBk, IFWL_ThemeProvider *pTheme, const CFX_Matrix *pMatrix = NULL); - void DrawBorder(CFX_Graphics *pGraphics, FX_INT32 iPartBorder, IFWL_ThemeProvider *pTheme, const CFX_Matrix *pMatrix = NULL); - void DrawEdge(CFX_Graphics *pGraphics, FX_INT32 iPartEdge, IFWL_ThemeProvider *pTheme, const CFX_Matrix *pMatrix = NULL); + void DrawBackground(CFX_Graphics *pGraphics, int32_t iPartBk, IFWL_ThemeProvider *pTheme, const CFX_Matrix *pMatrix = NULL); + void DrawBorder(CFX_Graphics *pGraphics, int32_t iPartBorder, IFWL_ThemeProvider *pTheme, const CFX_Matrix *pMatrix = NULL); + void DrawEdge(CFX_Graphics *pGraphics, int32_t iPartEdge, IFWL_ThemeProvider *pTheme, const CFX_Matrix *pMatrix = NULL); void NotifyDriver(); FX_BOOL IsParent(IFWL_Widget *pParent); @@ -111,7 +111,7 @@ protected: IFWL_WidgetDelegate *m_pCurDelegate; IFWL_Widget *m_pOuter; IFWL_Widget *m_pInterface; - FX_INT32 m_iLock; + int32_t m_iLock; friend class CFWL_WidgetImpDelegate; friend void FWL_SetWidgetRect(IFWL_Widget *widget, const CFX_RectF &rect); friend void FWL_SetWidgetStates(IFWL_Widget *widget, FX_DWORD dwStates); @@ -121,7 +121,7 @@ class CFWL_WidgetImpDelegate { public: CFWL_WidgetImpDelegate(); - virtual FX_INT32 OnProcessMessage(CFWL_Message *pMessage); + virtual int32_t OnProcessMessage(CFWL_Message *pMessage); virtual FWL_ERR OnProcessEvent(CFWL_Event *pEvent); virtual FWL_ERR OnDrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL); }; diff --git a/xfa/src/fwl/src/core/include/fwl_widgetmgrimp.h b/xfa/src/fwl/src/core/include/fwl_widgetmgrimp.h index 314021f9b6..f730f5b33d 100644 --- a/xfa/src/fwl/src/core/include/fwl_widgetmgrimp.h +++ b/xfa/src/fwl/src/core/include/fwl_widgetmgrimp.h @@ -44,7 +44,7 @@ public: CFWL_WidgetMgrItem *pNext; IFWL_Widget *pWidget; CFX_Graphics *pOffscreen; - FX_INT32 iRedrawCounter; + int32_t iRedrawCounter; #if (_FX_OS_==_FX_WIN32_DESKTOP_) || (_FX_OS_==_FX_WIN64_) FX_BOOL bOutsideChanged; #endif @@ -54,11 +54,11 @@ class CFWL_WidgetMgr public: CFWL_WidgetMgr(IFWL_AdapterNative *pAdapterNative); ~CFWL_WidgetMgr(); - virtual FX_INT32 CountWidgets(IFWL_Widget *pParent = NULL); - virtual IFWL_Widget* GetWidget(FX_INT32 nIndex, IFWL_Widget *pParent = NULL); + virtual int32_t CountWidgets(IFWL_Widget *pParent = NULL); + virtual IFWL_Widget* GetWidget(int32_t nIndex, IFWL_Widget *pParent = NULL); virtual IFWL_Widget* GetWidget(IFWL_Widget *pWidget, FWL_WGTRELATION eRelation); - virtual FX_INT32 GetWidgetIndex(IFWL_Widget *pWidget); - virtual FX_BOOL SetWidgetIndex(IFWL_Widget *pWidget, FX_INT32 nIndex); + virtual int32_t GetWidgetIndex(IFWL_Widget *pWidget); + virtual FX_BOOL SetWidgetIndex(IFWL_Widget *pWidget, int32_t nIndex); virtual FX_BOOL IsWidget(FX_LPVOID pObj); virtual FWL_ERR RepaintWidget(IFWL_Widget *pWidget, const CFX_RectF *pRect = NULL); virtual FX_DWORD GetCapability() @@ -66,7 +66,7 @@ public: return m_dwCapability; } void AddWidget(IFWL_Widget *pWidget); - void InsertWidget(IFWL_Widget *pParent, IFWL_Widget *pChild, FX_INT32 nIndex = -1); + void InsertWidget(IFWL_Widget *pParent, IFWL_Widget *pChild, int32_t nIndex = -1); void RemoveWidget(IFWL_Widget *pWidget); void SetOwner(IFWL_Widget *pOwner, IFWL_Widget *pOwned); void SetParent(IFWL_Widget *pParent, IFWL_Widget *pChild); @@ -87,12 +87,12 @@ public: FX_BOOL CheckMessage_Native(); FWL_ERR DispatchMessage_Native(); FX_BOOL IsIdleMessage_Native(); - FWL_ERR Exit_Native(FX_INT32 iExitCode); + FWL_ERR Exit_Native(int32_t iExitCode); FWL_ERR CreateWidgetWithNativeId_Native(IFWL_Widget *pWidget, void *vp); IFWL_Widget* GetWidgetAtPoint(IFWL_Widget *pParent, FX_FLOAT fx, FX_FLOAT fy); void NotifySizeChanged(IFWL_Widget *pForm, FX_FLOAT fx, FX_FLOAT fy); IFWL_Widget* nextTab(IFWL_Widget *parent, IFWL_Widget *focus, FX_BOOL &bFind); - FX_INT32 CountRadioButtonGroup(IFWL_Widget *pFirst); + int32_t CountRadioButtonGroup(IFWL_Widget *pFirst); IFWL_Widget* GetSiblingRadioButton(IFWL_Widget *pWidget, FX_BOOL bNext); IFWL_Widget* GetRadioButtonGroupHeader(IFWL_Widget *pRadioButton); void GetSameGroupRadioButton(IFWL_Widget *pRadioButton, CFX_PtrArray &group); @@ -112,7 +112,7 @@ public: FX_BOOL IsFormDisabled(); FX_BOOL GetAdapterPopupPos(IFWL_Widget* pWidget, FX_FLOAT fMinHeight, FX_FLOAT fMaxHeight, const CFX_RectF &rtAnchor, CFX_RectF &rtPopup); protected: - FX_INT32 TravelWidgetMgr(CFWL_WidgetMgrItem *pParent, FX_INT32 *pIndex, CFWL_WidgetMgrItem *pItem, IFWL_Widget **pWidget = NULL); + int32_t TravelWidgetMgr(CFWL_WidgetMgrItem *pParent, int32_t *pIndex, CFWL_WidgetMgrItem *pItem, IFWL_Widget **pWidget = NULL); FX_BOOL IsAbleNative(IFWL_Widget *pWidget); CFX_MapPtrToPtr m_mapWidgetItem; IFWL_AdapterWidgetMgr *m_pAdapter; @@ -128,7 +128,7 @@ class CFWL_WidgetMgrDelegate public: CFWL_WidgetMgrDelegate(CFWL_WidgetMgr *pWidgetMgr); virtual FWL_ERR OnSetCapability(FX_DWORD dwCapability = FWL_WGTMGR_DisableThread); - virtual FX_INT32 OnProcessMessageToForm(CFWL_Message *pMessage); + virtual int32_t OnProcessMessageToForm(CFWL_Message *pMessage); virtual FWL_ERR OnDrawWidget(IFWL_Widget *pWidget, CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix ); protected: void DrawChild(IFWL_Widget *pParent, const CFX_RectF &rtClip, CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix ); diff --git a/xfa/src/fwl/src/lightwidget/app.cpp b/xfa/src/fwl/src/lightwidget/app.cpp index e89b6c86de..54327c8cbc 100644 --- a/xfa/src/fwl/src/lightwidget/app.cpp +++ b/xfa/src/fwl/src/lightwidget/app.cpp @@ -31,7 +31,7 @@ CFWL_Theme* CFWL_App::GetTheme() { return m_pThemeProvider; } -FWL_ERR CFWL_App::Exit(FX_INT32 iExitCode ) +FWL_ERR CFWL_App::Exit(int32_t iExitCode ) { _FWL_RETURN_VALUE_IF_FAIL(m_pAppImp, FWL_ERR_Indefinite); return m_pAppImp->Exit(iExitCode); diff --git a/xfa/src/fwl/src/lightwidget/checkbox.cpp b/xfa/src/fwl/src/lightwidget/checkbox.cpp index cb659fffa7..298aa41b4e 100644 --- a/xfa/src/fwl/src/lightwidget/checkbox.cpp +++ b/xfa/src/fwl/src/lightwidget/checkbox.cpp @@ -45,11 +45,11 @@ FWL_ERR CFWL_CheckBox::SetBoxSize(FX_FLOAT fHeight) m_checkboxData.m_fBoxHeight = fHeight; return FWL_ERR_Succeeded; } -FX_INT32 CFWL_CheckBox::GetCheckState() +int32_t CFWL_CheckBox::GetCheckState() { return ((IFWL_CheckBox*)m_pImp)->GetCheckState(); } -FWL_ERR CFWL_CheckBox::SetCheckState(FX_INT32 iCheck) +FWL_ERR CFWL_CheckBox::SetCheckState(int32_t iCheck) { return ((IFWL_CheckBox*)m_pImp)->SetCheckState(iCheck); } diff --git a/xfa/src/fwl/src/lightwidget/combobox.cpp b/xfa/src/fwl/src/lightwidget/combobox.cpp index 557dc2d2b5..c443dfbcb3 100644 --- a/xfa/src/fwl/src/lightwidget/combobox.cpp +++ b/xfa/src/fwl/src/lightwidget/combobox.cpp @@ -35,14 +35,14 @@ FWL_ERR CFWL_ComboBox::Initialize(const CFWL_WidgetProperties *pProperties ) } return ret; } -FX_INT32 CFWL_ComboBox::AddString(FX_WSTR wsText) +int32_t CFWL_ComboBox::AddString(FX_WSTR wsText) { CFWL_ComboBoxItem *pItem = FX_NEW CFWL_ComboBoxItem; pItem->m_wsText = wsText; pItem->m_dwStyles = 0; return m_comboBoxData.m_arrItem.Add(pItem); } -FX_INT32 CFWL_ComboBox::AddString(FX_WSTR wsText, CFX_DIBitmap *pIcon) +int32_t CFWL_ComboBox::AddString(FX_WSTR wsText, CFX_DIBitmap *pIcon) { CFWL_ComboBoxItem *pItem = FX_NEW CFWL_ComboBoxItem; pItem->m_wsText = wsText; @@ -50,32 +50,32 @@ FX_INT32 CFWL_ComboBox::AddString(FX_WSTR wsText, CFX_DIBitmap *pIcon) pItem->m_pDIB = pIcon; return m_comboBoxData.m_arrItem.Add(pItem); } -FX_INT32 CFWL_ComboBox::RemoveAt(FX_INT32 iIndex) +int32_t CFWL_ComboBox::RemoveAt(int32_t iIndex) { return m_comboBoxData.m_arrItem.RemoveAt(iIndex); } -FX_INT32 CFWL_ComboBox::RemoveAll() +int32_t CFWL_ComboBox::RemoveAll() { m_comboBoxData.m_arrItem.RemoveAll(); return 0; } -FX_INT32 CFWL_ComboBox::CountItems() +int32_t CFWL_ComboBox::CountItems() { return m_comboBoxData.CountItems(GetWidget()); } -FWL_ERR CFWL_ComboBox::GetTextByIndex(FX_INT32 iIndex, CFX_WideString &wsText) +FWL_ERR CFWL_ComboBox::GetTextByIndex(int32_t iIndex, CFX_WideString &wsText) { CFWL_ComboBoxItem *pItem = (CFWL_ComboBoxItem*)(m_comboBoxData.GetItem((IFWL_Widget *)this, iIndex)); _FWL_RETURN_VALUE_IF_FAIL(pItem, FWL_ERR_Indefinite); wsText = pItem->m_wsText; return FWL_ERR_Succeeded; } -FX_INT32 CFWL_ComboBox::GetCurSel() +int32_t CFWL_ComboBox::GetCurSel() { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, -1); return ((IFWL_ComboBox*)m_pImp)->GetCurSel(); } -FWL_ERR CFWL_ComboBox::SetCurSel(FX_INT32 iSel) +FWL_ERR CFWL_ComboBox::SetCurSel(int32_t iSel) { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, FWL_ERR_Indefinite); return ((IFWL_ComboBox*)m_pImp)->SetCurSel(iSel); @@ -85,37 +85,37 @@ FWL_ERR CFWL_ComboBox::SetEditText(FX_WSTR wsText) _FWL_RETURN_VALUE_IF_FAIL(m_pImp, FWL_ERR_Indefinite); return ((IFWL_ComboBox*)m_pImp)->SetEditText(wsText); } -FX_INT32 CFWL_ComboBox::GetEditTextLength() const +int32_t CFWL_ComboBox::GetEditTextLength() const { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, 0); return ((IFWL_ComboBox*)m_pImp)->GetEditTextLength(); } -FWL_ERR CFWL_ComboBox::GetEditText(CFX_WideString &wsText, FX_INT32 nStart, FX_INT32 nCount) const +FWL_ERR CFWL_ComboBox::GetEditText(CFX_WideString &wsText, int32_t nStart, int32_t nCount) const { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, FWL_ERR_Indefinite); return ((IFWL_ComboBox*)m_pImp)->GetEditText(wsText, nStart, nCount); } -FWL_ERR CFWL_ComboBox::SetEditSelRange(FX_INT32 nStart, FX_INT32 nCount) +FWL_ERR CFWL_ComboBox::SetEditSelRange(int32_t nStart, int32_t nCount) { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, FWL_ERR_Indefinite); return ((IFWL_ComboBox*)m_pImp)->SetEditSelRange(nStart, nCount); } -FX_INT32 CFWL_ComboBox::GetEditSelRange(FX_INT32 nIndex, FX_INT32 &nStart) +int32_t CFWL_ComboBox::GetEditSelRange(int32_t nIndex, int32_t &nStart) { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, 0); return ((IFWL_ComboBox*)m_pImp)->GetEditSelRange(nIndex, nStart); } -FX_INT32 CFWL_ComboBox::GetEditLimit() +int32_t CFWL_ComboBox::GetEditLimit() { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, 0); return ((IFWL_ComboBox*)m_pImp)->GetEditLimit(); } -FWL_ERR CFWL_ComboBox::SetEditLimit(FX_INT32 nLimit) +FWL_ERR CFWL_ComboBox::SetEditLimit(int32_t nLimit) { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, FWL_ERR_Indefinite); return ((IFWL_ComboBox*)m_pImp)->SetEditLimit(nLimit); } -FWL_ERR CFWL_ComboBox::EditDoClipboard(FX_INT32 iCmd) +FWL_ERR CFWL_ComboBox::EditDoClipboard(int32_t iCmd) { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, FWL_ERR_Indefinite); return ((IFWL_ComboBox*)m_pImp)->EditDoClipboard(iCmd); @@ -135,14 +135,14 @@ FWL_ERR CFWL_ComboBox::SetMaxListHeight(FX_FLOAT fMaxHeight) m_comboBoxData.m_fMaxListHeight = fMaxHeight; return FWL_ERR_Succeeded; } -FWL_ERR CFWL_ComboBox::SetItemData(FX_INT32 iIndex, FX_LPVOID pData) +FWL_ERR CFWL_ComboBox::SetItemData(int32_t iIndex, FX_LPVOID pData) { CFWL_ComboBoxItem *pItem = (CFWL_ComboBoxItem*)(m_comboBoxData.GetItem((IFWL_Widget *)this, iIndex)); _FWL_RETURN_VALUE_IF_FAIL(pItem, FWL_ERR_Indefinite); pItem->m_pData = pData; return FWL_ERR_Succeeded; } -FX_LPVOID CFWL_ComboBox::GetItemData(FX_INT32 iIndex) +FX_LPVOID CFWL_ComboBox::GetItemData(int32_t iIndex) { CFWL_ComboBoxItem *pItem = (CFWL_ComboBoxItem*)(m_comboBoxData.GetItem((IFWL_Widget *)this, iIndex)); _FWL_RETURN_VALUE_IF_FAIL(pItem, NULL); @@ -249,8 +249,8 @@ CFWL_ComboBox::CFWL_ComboBoxDP::CFWL_ComboBoxDP() } CFWL_ComboBox::CFWL_ComboBoxDP::~CFWL_ComboBoxDP() { - FX_INT32 nCount = m_arrItem.GetSize(); - for (FX_INT32 i = 0; i < nCount; i ++) { + int32_t nCount = m_arrItem.GetSize(); + for (int32_t i = 0; i < nCount; i ++) { CFWL_ComboBoxItem *pItem = (CFWL_ComboBoxItem*)m_arrItem[i]; if (pItem) { delete pItem; @@ -258,23 +258,23 @@ CFWL_ComboBox::CFWL_ComboBoxDP::~CFWL_ComboBoxDP() } m_arrItem.RemoveAll(); } -FX_INT32 CFWL_ComboBox::CFWL_ComboBoxDP::CountItems(IFWL_Widget *pWidget) +int32_t CFWL_ComboBox::CFWL_ComboBoxDP::CountItems(IFWL_Widget *pWidget) { return m_arrItem.GetSize(); } -FWL_HLISTITEM CFWL_ComboBox::CFWL_ComboBoxDP::GetItem(IFWL_Widget *pWidget, FX_INT32 nIndex) +FWL_HLISTITEM CFWL_ComboBox::CFWL_ComboBoxDP::GetItem(IFWL_Widget *pWidget, int32_t nIndex) { - FX_INT32 iCount = m_arrItem.GetSize(); + int32_t iCount = m_arrItem.GetSize(); if (nIndex >= iCount || nIndex < 0) { return NULL; } return (FWL_HLISTITEM)m_arrItem[nIndex]; } -FX_INT32 CFWL_ComboBox::CFWL_ComboBoxDP::GetItemIndex(IFWL_Widget *pWidget, FWL_HLISTITEM hItem) +int32_t CFWL_ComboBox::CFWL_ComboBoxDP::GetItemIndex(IFWL_Widget *pWidget, FWL_HLISTITEM hItem) { return m_arrItem.Find(hItem); } -FX_BOOL CFWL_ComboBox::CFWL_ComboBoxDP::SetItemIndex(IFWL_Widget *pWidget, FWL_HLISTITEM hItem, FX_INT32 nIndex) +FX_BOOL CFWL_ComboBox::CFWL_ComboBoxDP::SetItemIndex(IFWL_Widget *pWidget, FWL_HLISTITEM hItem, int32_t nIndex) { return m_arrItem.SetAt(nIndex, hItem); } diff --git a/xfa/src/fwl/src/lightwidget/datetimepicker.cpp b/xfa/src/fwl/src/lightwidget/datetimepicker.cpp index 4a314c5079..5a18efe542 100644 --- a/xfa/src/fwl/src/lightwidget/datetimepicker.cpp +++ b/xfa/src/fwl/src/lightwidget/datetimepicker.cpp @@ -35,18 +35,18 @@ FWL_ERR CFWL_DateTimePicker::Initialize(const CFWL_WidgetProperties *pProperties } return ret; } -FWL_ERR CFWL_DateTimePicker::SetToday(FX_INT32 iYear, FX_INT32 iMonth, FX_INT32 iDay) +FWL_ERR CFWL_DateTimePicker::SetToday(int32_t iYear, int32_t iMonth, int32_t iDay) { m_DateTimePickerDP.m_iYear = iYear; m_DateTimePickerDP.m_iMonth = iMonth; m_DateTimePickerDP.m_iDay = iDay; return FWL_ERR_Succeeded; } -FX_INT32 CFWL_DateTimePicker::CountSelRanges() +int32_t CFWL_DateTimePicker::CountSelRanges() { return ((IFWL_DateTimePicker*)m_pImp)->CountSelRanges(); } -FX_INT32 CFWL_DateTimePicker::GetSelRange(FX_INT32 nIndex, FX_INT32 &nStart) +int32_t CFWL_DateTimePicker::GetSelRange(int32_t nIndex, int32_t &nStart) { return ((IFWL_DateTimePicker*)m_pImp)->GetSelRange(nIndex, nStart); } @@ -58,11 +58,11 @@ FWL_ERR CFWL_DateTimePicker::SetEditText(FX_WSTR wsText) { return ((IFWL_DateTimePicker*)m_pImp)->SetEditText(wsText); } -FWL_ERR CFWL_DateTimePicker::GetCurSel(FX_INT32 &iYear, FX_INT32 &iMonth, FX_INT32 &iDay) +FWL_ERR CFWL_DateTimePicker::GetCurSel(int32_t &iYear, int32_t &iMonth, int32_t &iDay) { return ((IFWL_DateTimePicker*)m_pImp)->GetCurSel(iYear, iMonth, iDay); } -FWL_ERR CFWL_DateTimePicker::SetCurSel(FX_INT32 iYear, FX_INT32 iMonth, FX_INT32 iDay) +FWL_ERR CFWL_DateTimePicker::SetCurSel(int32_t iYear, int32_t iMonth, int32_t iDay) { return ((IFWL_DateTimePicker*)m_pImp)->SetCurSel(iYear, iMonth, iDay); } @@ -83,7 +83,7 @@ FWL_ERR CFWL_DateTimePicker::CFWL_DateTimePickerDP::GetCaption(IFWL_Widget *pWid wsCaption = m_wsData; return FWL_ERR_Succeeded; } -FWL_ERR CFWL_DateTimePicker::CFWL_DateTimePickerDP::GetToday(IFWL_Widget *pWidget, FX_INT32 &iYear, FX_INT32 &iMonth, FX_INT32 &iDay) +FWL_ERR CFWL_DateTimePicker::CFWL_DateTimePickerDP::GetToday(IFWL_Widget *pWidget, int32_t &iYear, int32_t &iMonth, int32_t &iDay) { iYear = m_iYear; iMonth = m_iMonth; @@ -146,7 +146,7 @@ FWL_ERR CFWL_DateTimePicker::GetBBox(CFX_RectF &rect) { return ((IFWL_DateTimePicker*)m_pImp)->GetBBox(rect); } -FWL_ERR CFWL_DateTimePicker::SetEditLimit(FX_INT32 nLimit) +FWL_ERR CFWL_DateTimePicker::SetEditLimit(int32_t nLimit) { return ((IFWL_DateTimePicker*)m_pImp)->SetEditLimit(nLimit); } diff --git a/xfa/src/fwl/src/lightwidget/edit.cpp b/xfa/src/fwl/src/lightwidget/edit.cpp index c87f83fac6..8bace71d74 100644 --- a/xfa/src/fwl/src/lightwidget/edit.cpp +++ b/xfa/src/fwl/src/lightwidget/edit.cpp @@ -39,12 +39,12 @@ FWL_ERR CFWL_Edit::SetText(const CFX_WideString &wsText) _FWL_RETURN_VALUE_IF_FAIL(m_pImp, FWL_ERR_Indefinite); return ((IFWL_Edit*)m_pImp)->SetText(wsText); } -FX_INT32 CFWL_Edit::GetTextLength() const +int32_t CFWL_Edit::GetTextLength() const { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, 0); return ((IFWL_Edit*)m_pImp)->GetTextLength(); } -FWL_ERR CFWL_Edit::GetText(CFX_WideString &wsText, FX_INT32 nStart, FX_INT32 nCount) const +FWL_ERR CFWL_Edit::GetText(CFX_WideString &wsText, int32_t nStart, int32_t nCount) const { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, FWL_ERR_Indefinite); return ((IFWL_Edit*)m_pImp)->GetText(wsText, nStart, nCount); @@ -54,22 +54,22 @@ FWL_ERR CFWL_Edit::ClearText() _FWL_RETURN_VALUE_IF_FAIL(m_pImp, FWL_ERR_Indefinite); return ((IFWL_Edit*)m_pImp)->ClearText(); } -FX_INT32 CFWL_Edit::GetCaretPos() const +int32_t CFWL_Edit::GetCaretPos() const { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, -1); return ((IFWL_Edit*)m_pImp)->GetCaretPos(); } -FX_INT32 CFWL_Edit::SetCaretPos(FX_INT32 nIndex, FX_BOOL bBefore) +int32_t CFWL_Edit::SetCaretPos(int32_t nIndex, FX_BOOL bBefore) { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, -1); return ((IFWL_Edit*)m_pImp)->SetCaretPos(nIndex, bBefore); } -FWL_ERR CFWL_Edit::AddSelRange(FX_INT32 nStart, FX_INT32 nCount) +FWL_ERR CFWL_Edit::AddSelRange(int32_t nStart, int32_t nCount) { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, FWL_ERR_Indefinite); ((IFWL_Edit*)m_pImp)->AddSelRange(nStart, nCount); - FX_INT32 pos = 0; - FX_INT32 sum = ((IFWL_Edit*)m_pImp)->GetTextLength(); + int32_t pos = 0; + int32_t sum = ((IFWL_Edit*)m_pImp)->GetTextLength(); if (nCount == -1) { pos = sum; } else { @@ -77,12 +77,12 @@ FWL_ERR CFWL_Edit::AddSelRange(FX_INT32 nStart, FX_INT32 nCount) } return ((IFWL_Edit*)m_pImp)->SetCaretPos(pos); } -FX_INT32 CFWL_Edit::CountSelRanges() +int32_t CFWL_Edit::CountSelRanges() { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, 0); return ((IFWL_Edit*)m_pImp)->CountSelRanges(); } -FX_INT32 CFWL_Edit::GetSelRange(FX_INT32 nIndex, FX_INT32 &nStart) +int32_t CFWL_Edit::GetSelRange(int32_t nIndex, int32_t &nStart) { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, 0); return ((IFWL_Edit*)m_pImp)->GetSelRange(nIndex, nStart); @@ -92,12 +92,12 @@ FWL_ERR CFWL_Edit::ClearSelections() _FWL_RETURN_VALUE_IF_FAIL(m_pImp, FWL_ERR_Indefinite); return ((IFWL_Edit*)m_pImp)->ClearSelections(); } -FX_INT32 CFWL_Edit::GetLimit() +int32_t CFWL_Edit::GetLimit() { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, -1); return ((IFWL_Edit*)m_pImp)->GetLimit(); } -FWL_ERR CFWL_Edit::SetLimit(FX_INT32 nLimit) +FWL_ERR CFWL_Edit::SetLimit(int32_t nLimit) { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, FWL_ERR_Indefinite); return ((IFWL_Edit*)m_pImp)->SetLimit(nLimit); @@ -112,7 +112,7 @@ FWL_ERR CFWL_Edit::SetFormatString(const CFX_WideString &wsFormat) _FWL_RETURN_VALUE_IF_FAIL(m_pImp, FWL_ERR_Indefinite); return ((IFWL_Edit*)m_pImp)->SetFormatString(wsFormat); } -FWL_ERR CFWL_Edit::Insert(FX_INT32 nStart, FX_LPCWSTR lpText, FX_INT32 nLen) +FWL_ERR CFWL_Edit::Insert(int32_t nStart, FX_LPCWSTR lpText, int32_t nLen) { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, FWL_ERR_Indefinite); return ((IFWL_Edit*)m_pImp)->Insert(nStart, lpText, nLen); @@ -122,7 +122,7 @@ FWL_ERR CFWL_Edit::DeleteSelections() _FWL_RETURN_VALUE_IF_FAIL(m_pImp, FWL_ERR_Indefinite); return ((IFWL_Edit*)m_pImp)->DeleteSelections(); } -FWL_ERR CFWL_Edit::DeleteRange(FX_INT32 nStart, FX_INT32 nCount) +FWL_ERR CFWL_Edit::DeleteRange(int32_t nStart, int32_t nCount) { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, FWL_ERR_Indefinite); return ((IFWL_Edit*)m_pImp)->DeleteRange(nStart, nCount); @@ -132,12 +132,12 @@ FWL_ERR CFWL_Edit::ReplaceSelections(const CFX_WideStringC &wsReplace) _FWL_RETURN_VALUE_IF_FAIL(m_pImp, FWL_ERR_Indefinite); return ((IFWL_Edit*)m_pImp)->ReplaceSelections(wsReplace); } -FWL_ERR CFWL_Edit::Replace(FX_INT32 nStart, FX_INT32 nLen, const CFX_WideStringC &wsReplace) +FWL_ERR CFWL_Edit::Replace(int32_t nStart, int32_t nLen, const CFX_WideStringC &wsReplace) { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, FWL_ERR_Indefinite); return ((IFWL_Edit*)m_pImp)->Replace(nStart, nLen, wsReplace); } -FWL_ERR CFWL_Edit::DoClipboard(FX_INT32 iCmd) +FWL_ERR CFWL_Edit::DoClipboard(int32_t iCmd) { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, FWL_ERR_Indefinite); return ((IFWL_Edit*)m_pImp)->DoClipboard(iCmd); @@ -157,7 +157,7 @@ FWL_ERR CFWL_Edit::SetTabWidth(FX_FLOAT fTabWidth, FX_BOOL bEquidistant) _FWL_RETURN_VALUE_IF_FAIL(m_pImp, FWL_ERR_Indefinite); return ((IFWL_Edit*)m_pImp)->SetTabWidth(fTabWidth, bEquidistant); } -FWL_ERR CFWL_Edit::SetNumberRange(FX_INT32 iMin, FX_INT32 iMax) +FWL_ERR CFWL_Edit::SetNumberRange(int32_t iMin, int32_t iMax) { if (iMin > iMax) { return FWL_ERR_Parameter_Invalid; diff --git a/xfa/src/fwl/src/lightwidget/listbox.cpp b/xfa/src/fwl/src/lightwidget/listbox.cpp index 7cc3878d3f..f3278df1f9 100644 --- a/xfa/src/fwl/src/lightwidget/listbox.cpp +++ b/xfa/src/fwl/src/lightwidget/listbox.cpp @@ -51,13 +51,13 @@ FWL_HLISTITEM CFWL_ListBox::AddString(FX_WSTR wsAdd, FX_BOOL bSelect) } FX_BOOL CFWL_ListBox::DeleteString(FWL_HLISTITEM hItem) { - FX_INT32 nIndex = m_ListBoxDP.GetItemIndex(GetWidget(), hItem); + int32_t nIndex = m_ListBoxDP.GetItemIndex(GetWidget(), hItem); if (nIndex < 0 || nIndex >= m_ListBoxDP.m_arrItem.GetSize()) { return FALSE; } CFWL_ListItem *pDelItem = (CFWL_ListItem*)m_ListBoxDP.GetItem((IFWL_ListBox*)this, nIndex); - FX_INT32 iCount = m_ListBoxDP.CountItems((IFWL_ListBox*)this); - FX_INT32 iSel = nIndex + 1; + int32_t iCount = m_ListBoxDP.CountItems((IFWL_ListBox*)this); + int32_t iSel = nIndex + 1; if (iSel >= iCount) { iSel = nIndex - 1; if (iSel < 0) { @@ -74,25 +74,25 @@ FX_BOOL CFWL_ListBox::DeleteString(FWL_HLISTITEM hItem) } FX_BOOL CFWL_ListBox::DeleteAll() { - FX_INT32 iCount = m_ListBoxDP.CountItems((IFWL_ListBox*)this); - for (FX_INT32 i = 0; i < iCount; i ++) { + int32_t iCount = m_ListBoxDP.CountItems((IFWL_ListBox*)this); + for (int32_t i = 0; i < iCount; i ++) { CFWL_ListItem *pItem = (CFWL_ListItem*)m_ListBoxDP.GetItem((IFWL_ListBox*)this, i); delete pItem; } m_ListBoxDP.m_arrItem.RemoveAll(); return TRUE; } -FX_INT32 CFWL_ListBox::CountSelItems() +int32_t CFWL_ListBox::CountSelItems() { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, 0); return ((IFWL_ListBox*)m_pImp)->CountSelItems(); } -FWL_HLISTITEM CFWL_ListBox::GetSelItem(FX_INT32 nIndexSel) +FWL_HLISTITEM CFWL_ListBox::GetSelItem(int32_t nIndexSel) { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, NULL); return ((IFWL_ListBox*)m_pImp)->GetSelItem(nIndexSel); } -FX_INT32 CFWL_ListBox::GetSelIndex(FX_INT32 nIndex) +int32_t CFWL_ListBox::GetSelIndex(int32_t nIndex) { _FWL_RETURN_VALUE_IF_FAIL(m_pImp, 0); return ((IFWL_ListBox*)m_pImp)->GetSelIndex(nIndex); @@ -119,7 +119,7 @@ FWL_ERR CFWL_ListBox::SetItemHeight(FX_FLOAT fItemHeight) } FWL_HLISTITEM CFWL_ListBox::GetFocusItem() { - for (FX_INT32 i = 0; i < m_ListBoxDP.m_arrItem.GetSize(); i++) { + for (int32_t i = 0; i < m_ListBoxDP.m_arrItem.GetSize(); i++) { CFWL_ListItem * hItem = (CFWL_ListItem *)(m_ListBoxDP.m_arrItem[i]); if (hItem->m_dwStates & FWL_ITEMSTATE_LTB_Focused) { return (FWL_HLISTITEM)hItem; @@ -129,7 +129,7 @@ FWL_HLISTITEM CFWL_ListBox::GetFocusItem() } FWL_ERR CFWL_ListBox::SetFocusItem(FWL_HLISTITEM hItem) { - FX_INT32 nIndex = m_ListBoxDP.GetItemIndex(GetWidget(), hItem); + int32_t nIndex = m_ListBoxDP.GetItemIndex(GetWidget(), hItem); ((CFWL_ListItem *)(m_ListBoxDP.m_arrItem[nIndex]))->m_dwStates |= FWL_ITEMSTATE_LTB_Focused; return FWL_ERR_Succeeded; } @@ -137,13 +137,13 @@ FWL_ERR* CFWL_ListBox::Sort(IFWL_ListBoxCompare *pCom) { return ((IFWL_ListBox*)m_pImp)->Sort(pCom); } -FX_INT32 CFWL_ListBox::CountItems() +int32_t CFWL_ListBox::CountItems() { return m_ListBoxDP.m_arrItem.GetSize(); } -FWL_HLISTITEM CFWL_ListBox::GetItem(FX_INT32 nIndex) +FWL_HLISTITEM CFWL_ListBox::GetItem(int32_t nIndex) { - FX_INT32 nCount = m_ListBoxDP.m_arrItem.GetSize(); + int32_t nCount = m_ListBoxDP.m_arrItem.GetSize(); if (nIndex > nCount - 1 && nIndex < 0) { return NULL; } @@ -186,8 +186,8 @@ FWL_HLISTITEM CFWL_ListBox::GetItemAtPoint(FX_FLOAT fx, FX_FLOAT fy) FX_FLOAT fPosY = 0; ((IFWL_ListBox*)m_pImp)->GetScrollPos(fx); ((IFWL_ListBox*)m_pImp)->GetScrollPos(fy, FALSE); - FX_INT32 nCount = m_ListBoxDP.CountItems(NULL); - for (FX_INT32 i = 0; i < nCount; i ++) { + int32_t nCount = m_ListBoxDP.CountItems(NULL); + for (int32_t i = 0; i < nCount; i ++) { FWL_HLISTITEM hItem = m_ListBoxDP.GetItem(NULL, i); if (!hItem) { continue; @@ -218,8 +218,8 @@ CFWL_ListBox::CFWL_ListBoxDP::CFWL_ListBoxDP() } CFWL_ListBox::CFWL_ListBoxDP::~CFWL_ListBoxDP() { - FX_INT32 nCount = m_arrItem.GetSize(); - for (FX_INT32 i = 0; i < nCount; i ++) { + int32_t nCount = m_arrItem.GetSize(); + for (int32_t i = 0; i < nCount; i ++) { CFWL_ListItem *pItem = (CFWL_ListItem*)m_arrItem[i]; if (pItem != NULL) { delete pItem; @@ -232,11 +232,11 @@ FWL_ERR CFWL_ListBox::CFWL_ListBoxDP::GetCaption(IFWL_Widget *pWidget, CFX_WideS wsCaption = m_wsData; return FWL_ERR_Succeeded; } -FX_INT32 CFWL_ListBox::CFWL_ListBoxDP::CountItems(IFWL_Widget *pWidget) +int32_t CFWL_ListBox::CFWL_ListBoxDP::CountItems(IFWL_Widget *pWidget) { return m_arrItem.GetSize(); } -FWL_HLISTITEM CFWL_ListBox::CFWL_ListBoxDP::GetItem(IFWL_Widget *pWidget, FX_INT32 nIndex) +FWL_HLISTITEM CFWL_ListBox::CFWL_ListBoxDP::GetItem(IFWL_Widget *pWidget, int32_t nIndex) { if (nIndex >= m_arrItem.GetSize() || nIndex < 0) { return NULL; @@ -244,11 +244,11 @@ FWL_HLISTITEM CFWL_ListBox::CFWL_ListBoxDP::GetItem(IFWL_Widget *pWidget, FX_INT return (FWL_HLISTITEM)m_arrItem[nIndex]; } } -FX_INT32 CFWL_ListBox::CFWL_ListBoxDP::GetItemIndex(IFWL_Widget *pWidget, FWL_HLISTITEM hItem) +int32_t CFWL_ListBox::CFWL_ListBoxDP::GetItemIndex(IFWL_Widget *pWidget, FWL_HLISTITEM hItem) { return m_arrItem.Find(hItem); } -FX_BOOL CFWL_ListBox::CFWL_ListBoxDP::SetItemIndex(IFWL_Widget *pWidget, FWL_HLISTITEM hItem, FX_INT32 nIndex) +FX_BOOL CFWL_ListBox::CFWL_ListBoxDP::SetItemIndex(IFWL_Widget *pWidget, FWL_HLISTITEM hItem, int32_t nIndex) { return m_arrItem.SetAt(nIndex, hItem); } diff --git a/xfa/src/fwl/src/lightwidget/picturebox.cpp b/xfa/src/fwl/src/lightwidget/picturebox.cpp index e7d21de90e..619a473c21 100644 --- a/xfa/src/fwl/src/lightwidget/picturebox.cpp +++ b/xfa/src/fwl/src/lightwidget/picturebox.cpp @@ -53,20 +53,20 @@ FWL_ERR CFWL_PictureBox::SetRotation(FX_FLOAT fRotation) m_PictureBoxDP.m_fRotation = fRotation; return FWL_ERR_Succeeded; } -FX_INT32 CFWL_PictureBox::GetFlipMode() +int32_t CFWL_PictureBox::GetFlipMode() { return m_PictureBoxDP.GetFlipMode((IFWL_Widget*)this); } -FWL_ERR CFWL_PictureBox::SetFlipMode(FX_INT32 iFlipMode) +FWL_ERR CFWL_PictureBox::SetFlipMode(int32_t iFlipMode) { m_PictureBoxDP.m_iFlipMode = iFlipMode; return FWL_ERR_Succeeded; } -FX_INT32 CFWL_PictureBox::GetOpacity() +int32_t CFWL_PictureBox::GetOpacity() { return m_PictureBoxDP.GetOpacity((IFWL_Widget*)this); } -FWL_ERR CFWL_PictureBox::SetOpacity(FX_INT32 iOpacity) +FWL_ERR CFWL_PictureBox::SetOpacity(int32_t iOpacity) { m_PictureBoxDP.m_iOpacity = iOpacity; return FWL_ERR_Succeeded; @@ -120,7 +120,7 @@ CFX_DIBitmap* CFWL_PictureBox::CFWL_PictureBoxDP::GetInitialPicture(IFWL_Widget { return m_pBitmap; } -FX_INT32 CFWL_PictureBox::CFWL_PictureBoxDP::GetOpacity(IFWL_Widget *pWidget) +int32_t CFWL_PictureBox::CFWL_PictureBoxDP::GetOpacity(IFWL_Widget *pWidget) { return m_iOpacity; } @@ -138,7 +138,7 @@ FWL_ERR CFWL_PictureBox::CFWL_PictureBoxDP::GetMatrix(IFWL_Widget *pWidget, CFX_ matrix.Translate(m_fOffSetX, m_fOffSetY); return FWL_ERR_Succeeded; } -FX_INT32 CFWL_PictureBox::CFWL_PictureBoxDP::GetFlipMode(IFWL_Widget *pWidget) +int32_t CFWL_PictureBox::CFWL_PictureBoxDP::GetFlipMode(IFWL_Widget *pWidget) { return m_iFlipMode; } diff --git a/xfa/src/fwl/src/lightwidget/theme.cpp b/xfa/src/fwl/src/lightwidget/theme.cpp index a631b37f88..84925f562e 100644 --- a/xfa/src/fwl/src/lightwidget/theme.cpp +++ b/xfa/src/fwl/src/lightwidget/theme.cpp @@ -18,9 +18,9 @@ FX_DWORD CFWL_Theme::GetThemeID(IFWL_Widget *pWidget) } FX_DWORD CFWL_Theme::SetThemeID(IFWL_Widget *pWidget, FX_DWORD dwThemeID, FX_BOOL bChildren ) { - FX_INT32 iCount = m_arrThemes.GetSize(); + int32_t iCount = m_arrThemes.GetSize(); FX_DWORD dwID; - for (FX_INT32 i = 0; i < iCount; i ++) { + for (int32_t i = 0; i < iCount; i ++) { CFWL_WidgetTP *pTheme = (CFWL_WidgetTP*)m_arrThemes[i]; dwID = pTheme->GetThemeID(pWidget); pTheme->SetThemeID(pWidget, dwThemeID, FALSE); @@ -79,8 +79,8 @@ FX_BOOL CFWL_Theme::CalcTextRect(CFWL_ThemeText *pParams, CFX_RectF &rect) } FWL_ERR CFWL_Theme::Initialize() { - FX_INT32 iCount = m_arrThemes.GetSize(); - for (FX_INT32 i = 0; i < iCount; i ++) { + int32_t iCount = m_arrThemes.GetSize(); + for (int32_t i = 0; i < iCount; i ++) { CFWL_WidgetTP *pTheme = (CFWL_WidgetTP*)m_arrThemes[i]; pTheme->Initialize(); } @@ -89,8 +89,8 @@ FWL_ERR CFWL_Theme::Initialize() } FWL_ERR CFWL_Theme::Finalize() { - FX_INT32 iCount = m_arrThemes.GetSize(); - for (FX_INT32 i = 0; i < iCount; i ++) { + int32_t iCount = m_arrThemes.GetSize(); + for (int32_t i = 0; i < iCount; i ++) { CFWL_WidgetTP *pTheme = (CFWL_WidgetTP*)m_arrThemes[i]; pTheme->Finalize(); } @@ -126,8 +126,8 @@ CFWL_Theme::CFWL_Theme() } CFWL_Theme::~CFWL_Theme() { - FX_INT32 iCount = m_arrThemes.GetSize(); - for (FX_INT32 i = 0; i < iCount; i ++) { + int32_t iCount = m_arrThemes.GetSize(); + for (int32_t i = 0; i < iCount; i ++) { CFWL_WidgetTP *pTheme = (CFWL_WidgetTP*)m_arrThemes[i]; delete pTheme; } @@ -135,8 +135,8 @@ CFWL_Theme::~CFWL_Theme() } FWL_ERR CFWL_Theme::SetFont(IFWL_Widget *pWidget, FX_LPCWSTR strFont, FX_FLOAT fFontSize, FX_ARGB rgbFont) { - FX_INT32 iCount = m_arrThemes.GetSize(); - for (FX_INT32 i = 0; i < iCount; i ++) { + int32_t iCount = m_arrThemes.GetSize(); + for (int32_t i = 0; i < iCount; i ++) { CFWL_WidgetTP *pTheme = (CFWL_WidgetTP*)m_arrThemes[i]; pTheme->SetFont(pWidget, strFont, fFontSize, rgbFont); } @@ -144,8 +144,8 @@ FWL_ERR CFWL_Theme::SetFont(IFWL_Widget *pWidget, FX_LPCWSTR strFont, FX_FLOAT f } CFWL_WidgetTP* CFWL_Theme::GetTheme(IFWL_Widget* pWidget) { - FX_INT32 iCount = m_arrThemes.GetSize(); - for (FX_INT32 i = 0; i < iCount; i ++) { + int32_t iCount = m_arrThemes.GetSize(); + for (int32_t i = 0; i < iCount; i ++) { CFWL_WidgetTP *pTheme = (CFWL_WidgetTP*)m_arrThemes[i]; if (pTheme->IsValidWidget(pWidget)) { return pTheme; diff --git a/xfa/src/fwl/src/lightwidget/tooltipctrl.cpp b/xfa/src/fwl/src/lightwidget/tooltipctrl.cpp index 9397013c07..5fc3d5a4f3 100644 --- a/xfa/src/fwl/src/lightwidget/tooltipctrl.cpp +++ b/xfa/src/fwl/src/lightwidget/tooltipctrl.cpp @@ -51,20 +51,20 @@ FWL_ERR CFWL_ToolTip::SetCaption(FX_WSTR wsCaption) m_tooltipData.m_wsCaption = wsCaption; return FWL_ERR_Succeeded; } -FX_INT32 CFWL_ToolTip::GetInitialDelay() +int32_t CFWL_ToolTip::GetInitialDelay() { return m_tooltipData.m_nInitDelayTime; } -FX_INT32 CFWL_ToolTip::SetInitialDelay(FX_INT32 nDelayTime) +int32_t CFWL_ToolTip::SetInitialDelay(int32_t nDelayTime) { m_tooltipData.m_nInitDelayTime = nDelayTime; return FWL_ERR_Succeeded; } -FX_INT32 CFWL_ToolTip::GetAutoPopDelay() +int32_t CFWL_ToolTip::GetAutoPopDelay() { return m_tooltipData.m_nAutoPopDelayTime; } -FX_INT32 CFWL_ToolTip::SetAutoPopDelay(FX_INT32 nDelayTime) +int32_t CFWL_ToolTip::SetAutoPopDelay(int32_t nDelayTime) { m_tooltipData.m_nAutoPopDelayTime = nDelayTime; return FWL_ERR_Succeeded; @@ -119,11 +119,11 @@ FWL_ERR CFWL_ToolTip::CFWL_ToolTipDP::GetCaption(IFWL_Widget *pWidget, CFX_WideS wsCaption = m_wsCaption; return FWL_ERR_Succeeded; } -FX_INT32 CFWL_ToolTip::CFWL_ToolTipDP::GetInitialDelay(IFWL_Widget *pWidget) +int32_t CFWL_ToolTip::CFWL_ToolTipDP::GetInitialDelay(IFWL_Widget *pWidget) { return m_nInitDelayTime; } -FX_INT32 CFWL_ToolTip::CFWL_ToolTipDP::GetAutoPopDelay(IFWL_Widget *pWidget) +int32_t CFWL_ToolTip::CFWL_ToolTipDP::GetAutoPopDelay(IFWL_Widget *pWidget) { return m_nAutoPopDelayTime; } diff --git a/xfa/src/fwl/src/lightwidget/widget.cpp b/xfa/src/fwl/src/lightwidget/widget.cpp index f080d691bc..6171eecf31 100644 --- a/xfa/src/fwl/src/lightwidget/widget.cpp +++ b/xfa/src/fwl/src/lightwidget/widget.cpp @@ -302,7 +302,7 @@ void CFWL_Widget::DispatchEvent(CFWL_Event *pEvent) #define FWL_WGT_CalcHeight 2048 #define FWL_WGT_CalcWidth 2048 #define FWL_WGT_CalcMultiLineDefWidth 120.0f -CFX_SizeF CFWL_Widget::CalcTextSize(const CFX_WideString &wsText, FX_BOOL bMultiLine , FX_INT32 iLineWidth ) +CFX_SizeF CFWL_Widget::CalcTextSize(const CFX_WideString &wsText, FX_BOOL bMultiLine , int32_t iLineWidth ) { CFX_SizeF sz; sz.Set(0, 0); @@ -330,7 +330,7 @@ CFWL_WidgetDelegate::CFWL_WidgetDelegate() CFWL_WidgetDelegate::~CFWL_WidgetDelegate() { } -FX_INT32 CFWL_WidgetDelegate::OnProcessMessage(CFWL_Message *pMessage) +int32_t CFWL_WidgetDelegate::OnProcessMessage(CFWL_Message *pMessage) { return 1; } diff --git a/xfa/src/fwl/src/theme/checkboxtp.cpp b/xfa/src/fwl/src/theme/checkboxtp.cpp index 32e74e4a44..bba56e69ed 100644 --- a/xfa/src/fwl/src/theme/checkboxtp.cpp +++ b/xfa/src/fwl/src/theme/checkboxtp.cpp @@ -101,7 +101,7 @@ FWL_ERR CFWL_CheckBoxTP::Finalize() void CFWL_CheckBoxTP::DrawBoxBk(IFWL_Widget *pWidget, CFX_Graphics *pGraphics, const CFX_RectF *pRect, FX_DWORD dwStates, CFX_Matrix *pMatrix ) { dwStates &= 0x03; - FX_INT32 fillMode = FXFILL_WINDING; + int32_t fillMode = FXFILL_WINDING; FX_DWORD dwStyleEx = pWidget->GetStylesEx(); dwStyleEx &= FWL_STYLEEXT_CKB_ShapeMask; CFX_Path path; @@ -137,7 +137,7 @@ void CFWL_CheckBoxTP::DrawBoxBk(IFWL_Widget *pWidget, CFX_Graphics *pGraphics, c path.AddEllipse(rtClip); } } - FX_INT32 iTheme = 1; + int32_t iTheme = 1; if ((dwStates & FWL_PARTSTATE_CKB_Mask1) == FWL_PARTSTATE_CKB_Hovered) { iTheme = 2; } else if ((dwStates & FWL_PARTSTATE_CKB_Mask1) == FWL_PARTSTATE_CKB_Pressed) { @@ -303,14 +303,14 @@ void CFWL_CheckBoxTP::DrawSignStar(CFX_Graphics *pGraphics, const CFX_RectF *pRt ptCenter.Set((pRtSign->left + pRtSign->right()) / 2.0f, (pRtSign->top + fBottom) / 2.0f); FX_FLOAT px[5], py[5]; FX_FLOAT fAngel = FX_PI / 10.0f; - for (FX_INT32 i = 0; i < 5; i++) { + for (int32_t i = 0; i < 5; i++) { px[i] = ptCenter.x + fRadius * (FX_FLOAT)cos(fAngel); py[i] = ptCenter.y + fRadius * (FX_FLOAT)sin(fAngel); fAngel += FX_PI * 2 / 5.0f; } path.MoveTo(px[0], py[0]); - FX_INT32 nNext = 0; - for (FX_INT32 j = 0; j < 5; j++) { + int32_t nNext = 0; + for (int32_t j = 0; j < 5; j++) { nNext += 2; if (nNext >= 5) { nNext -= 5; diff --git a/xfa/src/fwl/src/theme/formtp.cpp b/xfa/src/fwl/src/theme/formtp.cpp index 5a6633d3ea..ce12c15e78 100644 --- a/xfa/src/fwl/src/theme/formtp.cpp +++ b/xfa/src/fwl/src/theme/formtp.cpp @@ -71,7 +71,7 @@ FX_DWORD CFWL_FormTP::SetThemeID(IFWL_Widget *pWidget, FX_DWORD dwThemeID, FX_BO FX_BOOL CFWL_FormTP::DrawBackground(CFWL_ThemeBackground *pParams) { _FWL_RETURN_VALUE_IF_FAIL(pParams, FALSE); - FX_INT32 iActive = 0; + int32_t iActive = 0; if (pParams->m_dwStates & FWL_PARTSTATE_FRM_Inactive) { iActive = 1; } @@ -285,7 +285,7 @@ void CFWL_FormTP::CalCaption(IFWL_Widget *pWidget, CFX_RectF &rect) void CFWL_FormTP::CalIcon(IFWL_Widget *pWidget, CFX_RectF &rect) { } -void CFWL_FormTP::DrawFormBorder(CFX_Graphics *pGraphics, const CFX_RectF *pRect, FWLTHEME_STATE eState, CFX_Matrix *pMatrix, FX_INT32 iActive) +void CFWL_FormTP::DrawFormBorder(CFX_Graphics *pGraphics, const CFX_RectF *pRect, FWLTHEME_STATE eState, CFX_Matrix *pMatrix, int32_t iActive) { CFX_RectF rt; rt.Set(pRect->left, pRect->top, 1, pRect->height); @@ -332,7 +332,7 @@ void CFWL_FormTP::DrawFormBorder(CFX_Graphics *pGraphics, const CFX_RectF *pRect m_rtDisBBorder.Set(pRect->left, pRect->bottom() - 4, pRect->width, 4); m_rtDisCaption.Set(pRect->left, pRect->top, pRect->width, 29); } -void CFWL_FormTP::DrawCaption(CFX_Graphics *pGraphics, const CFX_RectF *pRect, FWLTHEME_STATE eState, CFX_Matrix *pMatrix, FX_INT32 iActive) +void CFWL_FormTP::DrawCaption(CFX_Graphics *pGraphics, const CFX_RectF *pRect, FWLTHEME_STATE eState, CFX_Matrix *pMatrix, int32_t iActive) { CFX_RectF rt; FX_FLOAT fBottom, fRight; @@ -368,10 +368,10 @@ void CFWL_FormTP::DrawCaption(CFX_Graphics *pGraphics, const CFX_RectF *pRect, pGraphics->StretchImage(m_pDeactivebitmap, rect, pMatrix); } } -void CFWL_FormTP::DrawNarrowCaption(CFX_Graphics *pGraphics, const CFX_RectF *pRect, FWLTHEME_STATE eState, CFX_Matrix *pMatrix, FX_INT32 iActive) +void CFWL_FormTP::DrawNarrowCaption(CFX_Graphics *pGraphics, const CFX_RectF *pRect, FWLTHEME_STATE eState, CFX_Matrix *pMatrix, int32_t iActive) { } -void CFWL_FormTP::DrawCloseBox(CFX_Graphics *pGraphics, const CFX_RectF *pRect, FWLTHEME_STATE eState, CFX_Matrix *pMatrix, FX_INT32 iActive) +void CFWL_FormTP::DrawCloseBox(CFX_Graphics *pGraphics, const CFX_RectF *pRect, FWLTHEME_STATE eState, CFX_Matrix *pMatrix, int32_t iActive) { FX_FLOAT fRight = pRect->right(); FX_FLOAT fBottom = pRect->bottom(); @@ -438,7 +438,7 @@ void CFWL_FormTP::DrawCloseBox(CFX_Graphics *pGraphics, const CFX_RectF *pRect, pGraphics->StrokePath(&path, pMatrix); pGraphics->RestoreGraphState(); } -void CFWL_FormTP::DrawMinMaxBoxCommon(CFX_Graphics *pGraphics, const CFX_RectF *pRect, FWLTHEME_STATE eState, CFX_Matrix *pMatrix, FX_INT32 iActive) +void CFWL_FormTP::DrawMinMaxBoxCommon(CFX_Graphics *pGraphics, const CFX_RectF *pRect, FWLTHEME_STATE eState, CFX_Matrix *pMatrix, int32_t iActive) { pGraphics->SaveGraphState(); FX_FLOAT fRight = pRect->right(); @@ -489,14 +489,14 @@ void CFWL_FormTP::DrawMinMaxBoxCommon(CFX_Graphics *pGraphics, const CFX_RectF * m_pThemeData->clrNormalBtBKEnd[iActive][eState - 1], &path, FXFILL_WINDING, pMatrix); } -void CFWL_FormTP::DrawMinimizeBox(CFX_Graphics *pGraphics, const CFX_RectF *pRect, FWLTHEME_STATE eState, CFX_Matrix *pMatrix, FX_INT32 iActive) +void CFWL_FormTP::DrawMinimizeBox(CFX_Graphics *pGraphics, const CFX_RectF *pRect, FWLTHEME_STATE eState, CFX_Matrix *pMatrix, int32_t iActive) { DrawMinMaxBoxCommon(pGraphics, pRect, eState, pMatrix); CFX_RectF rtMin; rtMin.Set(pRect->left + 5, pRect->top + 13, pRect->width - 14, pRect->height - 18); FillSoildRect(pGraphics, 0xFFFFFFFF, &rtMin, pMatrix); } -void CFWL_FormTP::DrawMaximizeBox(CFX_Graphics *pGraphics, const CFX_RectF *pRect, FWLTHEME_STATE eState, FX_BOOL bMax, CFX_Matrix *pMatrix, FX_INT32 iActive) +void CFWL_FormTP::DrawMaximizeBox(CFX_Graphics *pGraphics, const CFX_RectF *pRect, FWLTHEME_STATE eState, FX_BOOL bMax, CFX_Matrix *pMatrix, int32_t iActive) { DrawMinMaxBoxCommon(pGraphics, pRect, eState, pMatrix); FX_FLOAT fWidth = pRect->width; @@ -534,7 +534,7 @@ void CFWL_FormTP::DrawMaximizeBox(CFX_Graphics *pGraphics, const CFX_RectF *pRec pGraphics->RestoreGraphState(); } } -void CFWL_FormTP::DrawIconImage(CFX_Graphics *pGraphics, CFX_DIBitmap *pDIBitmap, const CFX_RectF *pRect, FWLTHEME_STATE eState, CFX_Matrix *pMatrix, FX_INT32 iActive) +void CFWL_FormTP::DrawIconImage(CFX_Graphics *pGraphics, CFX_DIBitmap *pDIBitmap, const CFX_RectF *pRect, FWLTHEME_STATE eState, CFX_Matrix *pMatrix, int32_t iActive) { pGraphics->StretchImage(pDIBitmap, *pRect, pMatrix); } @@ -739,8 +739,8 @@ void CFWL_FormTP::DeactiveForm() } void CFWL_FormTP::TransModeColor(FX_ARGB clrFore, FX_ARGB &clrBack) { - FX_INT32 iAlfaF, iRF, iGF, iBF; - FX_INT32 iAlfaB, iRB, iGB, iBB; + int32_t iAlfaF, iRF, iGF, iBF; + int32_t iAlfaB, iRB, iGB, iBB; ArgbDecode(clrFore, iAlfaF, iRF, iGF, iBF); ArgbDecode(clrBack, iAlfaB, iRB, iGB, iBB); clrBack = ArgbEncode(0xff, diff --git a/xfa/src/fwl/src/theme/pushbuttontp.cpp b/xfa/src/fwl/src/theme/pushbuttontp.cpp index 13c5eef567..8194b249be 100644 --- a/xfa/src/fwl/src/theme/pushbuttontp.cpp +++ b/xfa/src/fwl/src/theme/pushbuttontp.cpp @@ -63,7 +63,7 @@ FX_BOOL CFWL_PushButtonTP::DrawBackground(CFWL_ThemeBackground *pParams) PUSHBUTTON_SIZE_Corner, PUSHBUTTON_SIZE_Corner); fillPath.AddRectangle(rtInner.left, rtInner.top, rtInner.width, rtInner.height); - FX_INT32 iColor = GetColorID(pParams->m_dwStates); + int32_t iColor = GetColorID(pParams->m_dwStates); DrawAxialShading(pGraphics, rect.left + PUSHBUTTON_SIZE_Corner, rect.top, @@ -159,7 +159,7 @@ void CFWL_PushButtonTP::SetThemeData(FX_DWORD dwID) m_pThemeData->clrFill[4] = ArgbEncode(255, 245, 244, 234); } } -FX_INT32 CFWL_PushButtonTP::GetColorID(FX_DWORD dwStates) +int32_t CFWL_PushButtonTP::GetColorID(FX_DWORD dwStates) { return dwStates &= FWL_PARTSTATE_PSB_Mask; } diff --git a/xfa/src/fwl/src/theme/widgettp.cpp b/xfa/src/fwl/src/theme/widgettp.cpp index 5e186b74ab..aac6516799 100644 --- a/xfa/src/fwl/src/theme/widgettp.cpp +++ b/xfa/src/fwl/src/theme/widgettp.cpp @@ -57,7 +57,7 @@ FX_BOOL CFWL_WidgetTP::DrawText(CFWL_ThemeText *pParams) if (!m_pTextOut) { InitTTO(); } - FX_INT32 iLen = pParams->m_wsText.GetLength(); + int32_t iLen = pParams->m_wsText.GetLength(); _FWL_RETURN_VALUE_IF_FAIL(iLen > 0, FALSE) CFX_Graphics *pGraphics = pParams->m_pGraphics; m_pTextOut->SetRenderDevice(pGraphics->GetRenderDevice()); @@ -434,7 +434,7 @@ void CFWL_WidgetTP::FillSoildRect(CFX_Graphics *pGraphics, FX_ARGB fillColor, co pGraphics->FillPath(&path, FXFILL_WINDING, pMatrix); pGraphics->RestoreGraphState(); } -void CFWL_WidgetTP::DrawAxialShading(CFX_Graphics *pGraphics, FX_FLOAT fx1, FX_FLOAT fy1, FX_FLOAT fx2, FX_FLOAT fy2, FX_ARGB beginColor, FX_ARGB endColor, CFX_Path *path, FX_INT32 fillMode, CFX_Matrix *pMatrix ) +void CFWL_WidgetTP::DrawAxialShading(CFX_Graphics *pGraphics, FX_FLOAT fx1, FX_FLOAT fy1, FX_FLOAT fx2, FX_FLOAT fy2, FX_ARGB beginColor, FX_ARGB endColor, CFX_Path *path, int32_t fillMode, CFX_Matrix *pMatrix ) { _FWL_RETURN_IF_FAIL(pGraphics); _FWL_RETURN_IF_FAIL(path); @@ -636,14 +636,14 @@ void CFWL_WidgetTP::DrawArrowBtn(CFX_Graphics *pGraphics, const CFX_RectF *pRect CFWL_ArrowData::CColorData *pColorData = CFWL_ArrowData::GetInstance()->m_pColorData; DrawArrow(pGraphics, pRect, eDict, pColorData->clrSign[eState - 1], pMatrix); } -FWLCOLOR CFWL_WidgetTP::BlendColor(FWLCOLOR srcColor, FWLCOLOR renderColor, FX_BYTE scale) +FWLCOLOR CFWL_WidgetTP::BlendColor(FWLCOLOR srcColor, FWLCOLOR renderColor, uint8_t scale) { FWLCOLOR dstColor; - FX_BYTE n = 255 - scale; - dstColor.a = (FX_BYTE)(((FX_WORD)srcColor.a * n + (FX_WORD)renderColor.a * scale) >> 8); - dstColor.r = (FX_BYTE)(((FX_WORD)srcColor.r * n + (FX_WORD)renderColor.r * scale) >> 8); - dstColor.g = (FX_BYTE)(((FX_WORD)srcColor.g * n + (FX_WORD)renderColor.g * scale) >> 8); - dstColor.b = (FX_BYTE)(((FX_WORD)srcColor.b * n + (FX_WORD)renderColor.b * scale) >> 8); + uint8_t n = 255 - scale; + dstColor.a = (uint8_t)(((FX_WORD)srcColor.a * n + (FX_WORD)renderColor.a * scale) >> 8); + dstColor.r = (uint8_t)(((FX_WORD)srcColor.r * n + (FX_WORD)renderColor.r * scale) >> 8); + dstColor.g = (uint8_t)(((FX_WORD)srcColor.g * n + (FX_WORD)renderColor.g * scale) >> 8); + dstColor.b = (uint8_t)(((FX_WORD)srcColor.b * n + (FX_WORD)renderColor.b * scale) >> 8); return dstColor; } CFWL_ArrowData::CFWL_ArrowData() @@ -713,8 +713,8 @@ CFWL_FontManager::CFWL_FontManager() } CFWL_FontManager::~CFWL_FontManager() { - FX_INT32 count = m_arrFonts.GetSize(); - for (FX_INT32 i = 0; i < count; i ++) { + int32_t count = m_arrFonts.GetSize(); + for (int32_t i = 0; i < count; i ++) { CFWL_FontData *data = (CFWL_FontData*)m_arrFonts[i]; delete data; } @@ -722,8 +722,8 @@ CFWL_FontManager::~CFWL_FontManager() } IFX_Font* CFWL_FontManager::FindFont(FX_WSTR wsFontFamily, FX_DWORD dwFontStyles, FX_WORD wCodePage) { - FX_INT32 count = m_arrFonts.GetSize(); - for (FX_INT32 i = 0; i < count; i ++) { + int32_t count = m_arrFonts.GetSize(); + for (int32_t i = 0; i < count; i ++) { CFWL_FontData *data = (CFWL_FontData*)m_arrFonts[i]; if (data->Equal(wsFontFamily, dwFontStyles, wCodePage)) { return data->GetFont(); -- cgit v1.2.3