summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordsinclair <dsinclair@chromium.org>2016-09-15 12:07:23 -0700
committerCommit bot <commit-bot@chromium.org>2016-09-15 12:07:23 -0700
commit72177dadac8f9765440b3aa01e2668f60a8b3f43 (patch)
treee7f5fb70bd9b228b66c7a5a4a874577528e27207
parent8f53f54a9ccada2ea8651f2786f1bbee323f09b7 (diff)
downloadpdfium-72177dadac8f9765440b3aa01e2668f60a8b3f43.tar.xz
Replace FX_UINT with unsigned int
Remove the FX_UINT typedef and update to use the actual unsigned int type. Review-Url: https://codereview.chromium.org/2343693002
-rw-r--r--fpdfsdk/cpdfsdk_document.cpp4
-rw-r--r--fpdfsdk/cpdfsdk_environment.cpp4
-rw-r--r--fpdfsdk/cpdfsdk_pageview.cpp10
-rw-r--r--fpdfsdk/cpdfsdk_widget.cpp20
-rw-r--r--fpdfsdk/formfiller/cffl_checkbox.cpp10
-rw-r--r--fpdfsdk/formfiller/cffl_checkbox.h10
-rw-r--r--fpdfsdk/formfiller/cffl_combobox.cpp4
-rw-r--r--fpdfsdk/formfiller/cffl_combobox.h4
-rw-r--r--fpdfsdk/formfiller/cffl_formfiller.cpp34
-rw-r--r--fpdfsdk/formfiller/cffl_formfiller.h34
-rw-r--r--fpdfsdk/formfiller/cffl_iformfiller.cpp40
-rw-r--r--fpdfsdk/formfiller/cffl_iformfiller.h40
-rw-r--r--fpdfsdk/formfiller/cffl_listbox.cpp4
-rw-r--r--fpdfsdk/formfiller/cffl_listbox.h4
-rw-r--r--fpdfsdk/formfiller/cffl_pushbutton.cpp4
-rw-r--r--fpdfsdk/formfiller/cffl_pushbutton.h4
-rw-r--r--fpdfsdk/formfiller/cffl_radiobutton.cpp10
-rw-r--r--fpdfsdk/formfiller/cffl_radiobutton.h10
-rw-r--r--fpdfsdk/formfiller/cffl_textfield.cpp4
-rw-r--r--fpdfsdk/formfiller/cffl_textfield.h4
-rw-r--r--fpdfsdk/include/cpdfsdk_document.h4
-rw-r--r--fpdfsdk/include/cpdfsdk_environment.h4
-rw-r--r--fpdfsdk/include/cpdfsdk_pageview.h14
-rw-r--r--fpdfsdk/include/fsdk_define.h12
-rw-r--r--fpdfsdk/javascript/app.cpp2
-rw-r--r--fpdfsdk/javascript/resource.cpp2
-rw-r--r--fpdfsdk/javascript/resource.h5
27 files changed, 156 insertions, 145 deletions
diff --git a/fpdfsdk/cpdfsdk_document.cpp b/fpdfsdk/cpdfsdk_document.cpp
index 339aeab8c6..9232da7b45 100644
--- a/fpdfsdk/cpdfsdk_document.cpp
+++ b/fpdfsdk/cpdfsdk_document.cpp
@@ -177,7 +177,7 @@ CPDFSDK_Annot* CPDFSDK_Document::GetFocusAnnot() {
return m_pFocusAnnot;
}
-FX_BOOL CPDFSDK_Document::SetFocusAnnot(CPDFSDK_Annot* pAnnot, FX_UINT nFlag) {
+FX_BOOL CPDFSDK_Document::SetFocusAnnot(CPDFSDK_Annot* pAnnot, uint32_t nFlag) {
if (m_bBeingDestroyed)
return FALSE;
@@ -214,7 +214,7 @@ FX_BOOL CPDFSDK_Document::SetFocusAnnot(CPDFSDK_Annot* pAnnot, FX_UINT nFlag) {
return FALSE;
}
-FX_BOOL CPDFSDK_Document::KillFocusAnnot(FX_UINT nFlag) {
+FX_BOOL CPDFSDK_Document::KillFocusAnnot(uint32_t nFlag) {
if (m_pFocusAnnot) {
CPDFSDK_AnnotHandlerMgr* pAnnotHandler = m_pEnv->GetAnnotHandlerMgr();
CPDFSDK_Annot* pFocusAnnot = m_pFocusAnnot;
diff --git a/fpdfsdk/cpdfsdk_environment.cpp b/fpdfsdk/cpdfsdk_environment.cpp
index 34f11d4142..12ef66997b 100644
--- a/fpdfsdk/cpdfsdk_environment.cpp
+++ b/fpdfsdk/cpdfsdk_environment.cpp
@@ -44,8 +44,8 @@ CPDFSDK_Environment::~CPDFSDK_Environment() {
int CPDFSDK_Environment::JS_appAlert(const FX_WCHAR* Msg,
const FX_WCHAR* Title,
- FX_UINT Type,
- FX_UINT Icon) {
+ uint32_t Type,
+ uint32_t Icon) {
if (!m_pInfo || !m_pInfo->m_pJsPlatform ||
!m_pInfo->m_pJsPlatform->app_alert) {
return -1;
diff --git a/fpdfsdk/cpdfsdk_pageview.cpp b/fpdfsdk/cpdfsdk_pageview.cpp
index a342e017e4..5989e29f64 100644
--- a/fpdfsdk/cpdfsdk_pageview.cpp
+++ b/fpdfsdk/cpdfsdk_pageview.cpp
@@ -317,7 +317,7 @@ CPDFSDK_Annot* CPDFSDK_PageView::GetAnnotByXFAWidget(CXFA_FFWidget* hWidget) {
#endif // PDF_ENABLE_XFA
FX_BOOL CPDFSDK_PageView::OnLButtonDown(const CFX_FloatPoint& point,
- FX_UINT nFlag) {
+ uint32_t nFlag) {
CPDFSDK_Environment* pEnv = m_pSDKDoc->GetEnv();
ASSERT(pEnv);
CPDFSDK_Annot* pFXAnnot = GetFXWidgetAtPoint(point.x, point.y);
@@ -336,7 +336,7 @@ FX_BOOL CPDFSDK_PageView::OnLButtonDown(const CFX_FloatPoint& point,
#ifdef PDF_ENABLE_XFA
FX_BOOL CPDFSDK_PageView::OnRButtonDown(const CFX_FloatPoint& point,
- FX_UINT nFlag) {
+ uint32_t nFlag) {
CPDFSDK_Environment* pEnv = m_pSDKDoc->GetEnv();
ASSERT(pEnv);
CPDFSDK_AnnotHandlerMgr* pAnnotHandlerMgr = pEnv->GetAnnotHandlerMgr();
@@ -354,7 +354,7 @@ FX_BOOL CPDFSDK_PageView::OnRButtonDown(const CFX_FloatPoint& point,
}
FX_BOOL CPDFSDK_PageView::OnRButtonUp(const CFX_FloatPoint& point,
- FX_UINT nFlag) {
+ uint32_t nFlag) {
CPDFSDK_Environment* pEnv = m_pSDKDoc->GetEnv();
ASSERT(pEnv);
CPDFSDK_AnnotHandlerMgr* pAnnotHandlerMgr = pEnv->GetAnnotHandlerMgr();
@@ -372,7 +372,7 @@ FX_BOOL CPDFSDK_PageView::OnRButtonUp(const CFX_FloatPoint& point,
#endif // PDF_ENABLE_XFA
FX_BOOL CPDFSDK_PageView::OnLButtonUp(const CFX_FloatPoint& point,
- FX_UINT nFlag) {
+ uint32_t nFlag) {
CPDFSDK_Environment* pEnv = m_pSDKDoc->GetEnv();
ASSERT(pEnv);
CPDFSDK_AnnotHandlerMgr* pAnnotHandlerMgr = pEnv->GetAnnotHandlerMgr();
@@ -432,7 +432,7 @@ FX_BOOL CPDFSDK_PageView::OnMouseWheel(double deltaX,
return FALSE;
}
-FX_BOOL CPDFSDK_PageView::OnChar(int nChar, FX_UINT nFlag) {
+FX_BOOL CPDFSDK_PageView::OnChar(int nChar, uint32_t nFlag) {
if (CPDFSDK_Annot* pAnnot = GetFocusAnnot()) {
CPDFSDK_Environment* pEnv = m_pSDKDoc->GetEnv();
CPDFSDK_AnnotHandlerMgr* pAnnotHandlerMgr = pEnv->GetAnnotHandlerMgr();
diff --git a/fpdfsdk/cpdfsdk_widget.cpp b/fpdfsdk/cpdfsdk_widget.cpp
index 9bc18fae04..d4fc5c7900 100644
--- a/fpdfsdk/cpdfsdk_widget.cpp
+++ b/fpdfsdk/cpdfsdk_widget.cpp
@@ -39,6 +39,17 @@
#include "xfa/fxfa/include/xfa_ffwidgethandler.h"
#endif // PDF_ENABLE_XFA
+namespace {
+
+// Convert a FX_ARGB to a FX_COLORREF.
+FX_COLORREF ARGBToColorRef(FX_ARGB argb) {
+ return (((static_cast<uint32_t>(argb) & 0x00FF0000) >> 16) |
+ (static_cast<uint32_t>(argb) & 0x0000FF00) |
+ ((static_cast<uint32_t>(argb) & 0x000000FF) << 16));
+}
+
+} // namespace
+
CPDFSDK_Widget::CPDFSDK_Widget(CPDF_Annot* pAnnot,
CPDFSDK_PageView* pPageView,
CPDFSDK_InterForm* pInterForm)
@@ -555,16 +566,14 @@ CFX_WideString CPDFSDK_Widget::GetName() const {
FX_BOOL CPDFSDK_Widget::GetFillColor(FX_COLORREF& color) const {
CPDF_FormControl* pFormCtrl = GetFormControl();
int iColorType = 0;
- color = FX_ARGBTOCOLORREF(pFormCtrl->GetBackgroundColor(iColorType));
-
+ color = ARGBToColorRef(pFormCtrl->GetBackgroundColor(iColorType));
return iColorType != COLORTYPE_TRANSPARENT;
}
FX_BOOL CPDFSDK_Widget::GetBorderColor(FX_COLORREF& color) const {
CPDF_FormControl* pFormCtrl = GetFormControl();
int iColorType = 0;
- color = FX_ARGBTOCOLORREF(pFormCtrl->GetBorderColor(iColorType));
-
+ color = ARGBToColorRef(pFormCtrl->GetBorderColor(iColorType));
return iColorType != COLORTYPE_TRANSPARENT;
}
@@ -577,8 +586,7 @@ FX_BOOL CPDFSDK_Widget::GetTextColor(FX_COLORREF& color) const {
FX_ARGB argb;
int iColorType = COLORTYPE_TRANSPARENT;
da.GetColor(argb, iColorType);
- color = FX_ARGBTOCOLORREF(argb);
-
+ color = ARGBToColorRef(argb);
return iColorType != COLORTYPE_TRANSPARENT;
}
diff --git a/fpdfsdk/formfiller/cffl_checkbox.cpp b/fpdfsdk/formfiller/cffl_checkbox.cpp
index df5e7bfbca..9b9245d410 100644
--- a/fpdfsdk/formfiller/cffl_checkbox.cpp
+++ b/fpdfsdk/formfiller/cffl_checkbox.cpp
@@ -26,8 +26,8 @@ CPWL_Wnd* CFFL_CheckBox::NewPDFWindow(const PWL_CREATEPARAM& cp,
}
FX_BOOL CFFL_CheckBox::OnKeyDown(CPDFSDK_Annot* pAnnot,
- FX_UINT nKeyCode,
- FX_UINT nFlags) {
+ uint32_t nKeyCode,
+ uint32_t nFlags) {
switch (nKeyCode) {
case FWL_VKEY_Return:
case FWL_VKEY_Space:
@@ -37,8 +37,8 @@ FX_BOOL CFFL_CheckBox::OnKeyDown(CPDFSDK_Annot* pAnnot,
}
}
FX_BOOL CFFL_CheckBox::OnChar(CPDFSDK_Annot* pAnnot,
- FX_UINT nChar,
- FX_UINT nFlags) {
+ uint32_t nChar,
+ uint32_t nFlags) {
switch (nChar) {
case FWL_VKEY_Return:
case FWL_VKEY_Space: {
@@ -73,7 +73,7 @@ FX_BOOL CFFL_CheckBox::OnChar(CPDFSDK_Annot* pAnnot,
FX_BOOL CFFL_CheckBox::OnLButtonUp(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point) {
CFFL_Button::OnLButtonUp(pPageView, pAnnot, nFlags, point);
diff --git a/fpdfsdk/formfiller/cffl_checkbox.h b/fpdfsdk/formfiller/cffl_checkbox.h
index 9dd0827356..c82d3338ee 100644
--- a/fpdfsdk/formfiller/cffl_checkbox.h
+++ b/fpdfsdk/formfiller/cffl_checkbox.h
@@ -18,12 +18,14 @@ class CFFL_CheckBox : public CFFL_Button {
CPWL_Wnd* NewPDFWindow(const PWL_CREATEPARAM& cp,
CPDFSDK_PageView* pPageView) override;
FX_BOOL OnKeyDown(CPDFSDK_Annot* pAnnot,
- FX_UINT nKeyCode,
- FX_UINT nFlags) override;
- FX_BOOL OnChar(CPDFSDK_Annot* pAnnot, FX_UINT nChar, FX_UINT nFlags) override;
+ uint32_t nKeyCode,
+ uint32_t nFlags) override;
+ FX_BOOL OnChar(CPDFSDK_Annot* pAnnot,
+ uint32_t nChar,
+ uint32_t nFlags) override;
FX_BOOL OnLButtonUp(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point) override;
FX_BOOL IsDataChanged(CPDFSDK_PageView* pPageView) override;
void SaveData(CPDFSDK_PageView* pPageView) override;
diff --git a/fpdfsdk/formfiller/cffl_combobox.cpp b/fpdfsdk/formfiller/cffl_combobox.cpp
index 448b0d94b9..40e5c346b2 100644
--- a/fpdfsdk/formfiller/cffl_combobox.cpp
+++ b/fpdfsdk/formfiller/cffl_combobox.cpp
@@ -74,8 +74,8 @@ CPWL_Wnd* CFFL_ComboBox::NewPDFWindow(const PWL_CREATEPARAM& cp,
}
FX_BOOL CFFL_ComboBox::OnChar(CPDFSDK_Annot* pAnnot,
- FX_UINT nChar,
- FX_UINT nFlags) {
+ uint32_t nChar,
+ uint32_t nFlags) {
return CFFL_FormFiller::OnChar(pAnnot, nChar, nFlags);
}
diff --git a/fpdfsdk/formfiller/cffl_combobox.h b/fpdfsdk/formfiller/cffl_combobox.h
index b9e7430636..31e4d8bba8 100644
--- a/fpdfsdk/formfiller/cffl_combobox.h
+++ b/fpdfsdk/formfiller/cffl_combobox.h
@@ -28,7 +28,9 @@ class CFFL_ComboBox : public CFFL_FormFiller, public IPWL_FocusHandler {
PWL_CREATEPARAM GetCreateParam() override;
CPWL_Wnd* NewPDFWindow(const PWL_CREATEPARAM& cp,
CPDFSDK_PageView* pPageView) override;
- FX_BOOL OnChar(CPDFSDK_Annot* pAnnot, FX_UINT nChar, FX_UINT nFlags) override;
+ FX_BOOL OnChar(CPDFSDK_Annot* pAnnot,
+ uint32_t nChar,
+ uint32_t nFlags) override;
FX_BOOL IsDataChanged(CPDFSDK_PageView* pPageView) override;
void SaveData(CPDFSDK_PageView* pPageView) override;
void GetActionData(CPDFSDK_PageView* pPageView,
diff --git a/fpdfsdk/formfiller/cffl_formfiller.cpp b/fpdfsdk/formfiller/cffl_formfiller.cpp
index 3248c3b6c5..f91a1f4141 100644
--- a/fpdfsdk/formfiller/cffl_formfiller.cpp
+++ b/fpdfsdk/formfiller/cffl_formfiller.cpp
@@ -125,7 +125,7 @@ void CFFL_FormFiller::OnMouseExit(CPDFSDK_PageView* pPageView,
FX_BOOL CFFL_FormFiller::OnLButtonDown(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point) {
if (CPWL_Wnd* pWnd = GetPDFWindow(pPageView, TRUE)) {
m_bValid = TRUE;
@@ -143,7 +143,7 @@ FX_BOOL CFFL_FormFiller::OnLButtonDown(CPDFSDK_PageView* pPageView,
FX_BOOL CFFL_FormFiller::OnLButtonUp(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point) {
CPWL_Wnd* pWnd = GetPDFWindow(pPageView, FALSE);
if (!pWnd)
@@ -157,7 +157,7 @@ FX_BOOL CFFL_FormFiller::OnLButtonUp(CPDFSDK_PageView* pPageView,
FX_BOOL CFFL_FormFiller::OnLButtonDblClk(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point) {
CPWL_Wnd* pWnd = GetPDFWindow(pPageView, FALSE);
if (!pWnd)
@@ -169,7 +169,7 @@ FX_BOOL CFFL_FormFiller::OnLButtonDblClk(CPDFSDK_PageView* pPageView,
FX_BOOL CFFL_FormFiller::OnMouseMove(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point) {
if (m_ptOldPos != point)
m_ptOldPos = point;
@@ -184,7 +184,7 @@ FX_BOOL CFFL_FormFiller::OnMouseMove(CPDFSDK_PageView* pPageView,
FX_BOOL CFFL_FormFiller::OnMouseWheel(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
short zDelta,
const CFX_FloatPoint& point) {
if (!IsValid())
@@ -196,7 +196,7 @@ FX_BOOL CFFL_FormFiller::OnMouseWheel(CPDFSDK_PageView* pPageView,
FX_BOOL CFFL_FormFiller::OnRButtonDown(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point) {
CPWL_Wnd* pWnd = GetPDFWindow(pPageView, TRUE);
if (!pWnd)
@@ -208,7 +208,7 @@ FX_BOOL CFFL_FormFiller::OnRButtonDown(CPDFSDK_PageView* pPageView,
FX_BOOL CFFL_FormFiller::OnRButtonUp(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point) {
CPWL_Wnd* pWnd = GetPDFWindow(pPageView, FALSE);
if (!pWnd)
@@ -219,8 +219,8 @@ FX_BOOL CFFL_FormFiller::OnRButtonUp(CPDFSDK_PageView* pPageView,
}
FX_BOOL CFFL_FormFiller::OnKeyDown(CPDFSDK_Annot* pAnnot,
- FX_UINT nKeyCode,
- FX_UINT nFlags) {
+ uint32_t nKeyCode,
+ uint32_t nFlags) {
if (IsValid()) {
CPDFSDK_PageView* pPageView = GetCurPageView(true);
ASSERT(pPageView);
@@ -234,8 +234,8 @@ FX_BOOL CFFL_FormFiller::OnKeyDown(CPDFSDK_Annot* pAnnot,
}
FX_BOOL CFFL_FormFiller::OnChar(CPDFSDK_Annot* pAnnot,
- FX_UINT nChar,
- FX_UINT nFlags) {
+ uint32_t nChar,
+ uint32_t nFlags) {
if (IsValid()) {
CPDFSDK_PageView* pPageView = GetCurPageView(true);
ASSERT(pPageView);
@@ -248,7 +248,7 @@ FX_BOOL CFFL_FormFiller::OnChar(CPDFSDK_Annot* pAnnot,
return FALSE;
}
-void CFFL_FormFiller::SetFocusForAnnot(CPDFSDK_Annot* pAnnot, FX_UINT nFlag) {
+void CFFL_FormFiller::SetFocusForAnnot(CPDFSDK_Annot* pAnnot, uint32_t nFlag) {
CPDFSDK_Widget* pWidget = (CPDFSDK_Widget*)pAnnot;
UnderlyingPageType* pPage = pWidget->GetUnderlyingPage();
CPDFSDK_Document* pDoc = m_pApp->GetSDKDocument();
@@ -261,7 +261,7 @@ void CFFL_FormFiller::SetFocusForAnnot(CPDFSDK_Annot* pAnnot, FX_UINT nFlag) {
InvalidateRect(rcRect.left, rcRect.top, rcRect.right, rcRect.bottom);
}
-void CFFL_FormFiller::KillFocusForAnnot(CPDFSDK_Annot* pAnnot, FX_UINT nFlag) {
+void CFFL_FormFiller::KillFocusForAnnot(CPDFSDK_Annot* pAnnot, uint32_t nFlag) {
if (!IsValid())
return;
@@ -521,7 +521,7 @@ CFX_FloatRect CFFL_FormFiller::FFLtoWnd(CPDFSDK_PageView* pPageView,
}
FX_BOOL CFFL_FormFiller::CommitData(CPDFSDK_PageView* pPageView,
- FX_UINT nFlag) {
+ uint32_t nFlag) {
if (IsDataChanged(pPageView)) {
FX_BOOL bRC = TRUE;
FX_BOOL bExit = FALSE;
@@ -642,7 +642,7 @@ void CFFL_Button::OnMouseExit(CPDFSDK_PageView* pPageView,
FX_BOOL CFFL_Button::OnLButtonDown(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point) {
CFX_FloatRect rcAnnot = pAnnot->GetRect();
if (!rcAnnot.Contains(point.x, point.y))
@@ -657,7 +657,7 @@ FX_BOOL CFFL_Button::OnLButtonDown(CPDFSDK_PageView* pPageView,
FX_BOOL CFFL_Button::OnLButtonUp(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point) {
CFX_FloatRect rcAnnot = pAnnot->GetRect();
if (!rcAnnot.Contains(point.x, point.y))
@@ -673,7 +673,7 @@ FX_BOOL CFFL_Button::OnLButtonUp(CPDFSDK_PageView* pPageView,
FX_BOOL CFFL_Button::OnMouseMove(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point) {
ASSERT(m_pApp);
diff --git a/fpdfsdk/formfiller/cffl_formfiller.h b/fpdfsdk/formfiller/cffl_formfiller.h
index 6a41185c39..9d2b66b769 100644
--- a/fpdfsdk/formfiller/cffl_formfiller.h
+++ b/fpdfsdk/formfiller/cffl_formfiller.h
@@ -43,41 +43,43 @@ class CFFL_FormFiller : public IPWL_Provider, public CPWL_TimerHandler {
virtual FX_BOOL OnLButtonDown(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point);
virtual FX_BOOL OnLButtonUp(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point);
virtual FX_BOOL OnLButtonDblClk(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point);
virtual FX_BOOL OnMouseMove(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point);
virtual FX_BOOL OnMouseWheel(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
short zDelta,
const CFX_FloatPoint& point);
virtual FX_BOOL OnRButtonDown(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point);
virtual FX_BOOL OnRButtonUp(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point);
virtual FX_BOOL OnKeyDown(CPDFSDK_Annot* pAnnot,
- FX_UINT nKeyCode,
- FX_UINT nFlags);
- virtual FX_BOOL OnChar(CPDFSDK_Annot* pAnnot, FX_UINT nChar, FX_UINT nFlags);
+ uint32_t nKeyCode,
+ uint32_t nFlags);
+ virtual FX_BOOL OnChar(CPDFSDK_Annot* pAnnot,
+ uint32_t nChar,
+ uint32_t nFlags);
- void SetFocusForAnnot(CPDFSDK_Annot* pAnnot, FX_UINT nFlag);
- void KillFocusForAnnot(CPDFSDK_Annot* pAnnot, FX_UINT nFlag);
+ void SetFocusForAnnot(CPDFSDK_Annot* pAnnot, uint32_t nFlag);
+ void KillFocusForAnnot(CPDFSDK_Annot* pAnnot, uint32_t nFlag);
// CPWL_TimerHandler
void TimerProc() override;
@@ -119,7 +121,7 @@ class CFFL_FormFiller : public IPWL_Provider, public CPWL_TimerHandler {
const CFX_FloatRect& rcWindow);
CFX_FloatRect GetWindowRect(CPDFSDK_PageView* pPageView);
- FX_BOOL CommitData(CPDFSDK_PageView* pPageView, FX_UINT nFlag);
+ FX_BOOL CommitData(CPDFSDK_PageView* pPageView, uint32_t nFlag);
virtual FX_BOOL IsDataChanged(CPDFSDK_PageView* pPageView);
virtual void SaveData(CPDFSDK_PageView* pPageView);
@@ -180,15 +182,15 @@ class CFFL_Button : public CFFL_FormFiller {
void OnMouseExit(CPDFSDK_PageView* pPageView, CPDFSDK_Annot* pAnnot) override;
FX_BOOL OnLButtonDown(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point) override;
FX_BOOL OnLButtonUp(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point) override;
FX_BOOL OnMouseMove(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point) override;
void OnDraw(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
diff --git a/fpdfsdk/formfiller/cffl_iformfiller.cpp b/fpdfsdk/formfiller/cffl_iformfiller.cpp
index 5bbc6aff9c..a81b486865 100644
--- a/fpdfsdk/formfiller/cffl_iformfiller.cpp
+++ b/fpdfsdk/formfiller/cffl_iformfiller.cpp
@@ -123,7 +123,7 @@ void CFFL_IFormFiller::OnDelete(CPDFSDK_Annot* pAnnot) {
void CFFL_IFormFiller::OnMouseEnter(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlag) {
+ uint32_t nFlag) {
ASSERT(pAnnot->GetPDFAnnot()->GetSubtype() == CPDF_Annot::Subtype::WIDGET);
if (!m_bNotifying) {
@@ -159,7 +159,7 @@ void CFFL_IFormFiller::OnMouseEnter(CPDFSDK_PageView* pPageView,
void CFFL_IFormFiller::OnMouseExit(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlag) {
+ uint32_t nFlag) {
ASSERT(pAnnot->GetPDFAnnot()->GetSubtype() == CPDF_Annot::Subtype::WIDGET);
if (!m_bNotifying) {
@@ -195,7 +195,7 @@ void CFFL_IFormFiller::OnMouseExit(CPDFSDK_PageView* pPageView,
FX_BOOL CFFL_IFormFiller::OnLButtonDown(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point) {
ASSERT(pAnnot->GetPDFAnnot()->GetSubtype() == CPDF_Annot::Subtype::WIDGET);
@@ -237,7 +237,7 @@ FX_BOOL CFFL_IFormFiller::OnLButtonDown(CPDFSDK_PageView* pPageView,
FX_BOOL CFFL_IFormFiller::OnLButtonUp(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point) {
ASSERT(pAnnot->GetPDFAnnot()->GetSubtype() == CPDF_Annot::Subtype::WIDGET);
CPDFSDK_Widget* pWidget = (CPDFSDK_Widget*)pAnnot;
@@ -280,7 +280,7 @@ void CFFL_IFormFiller::OnButtonUp(CPDFSDK_Widget* pWidget,
CPDFSDK_PageView* pPageView,
FX_BOOL& bReset,
FX_BOOL& bExit,
- FX_UINT nFlag) {
+ uint32_t nFlag) {
ASSERT(pWidget);
if (!m_bNotifying) {
@@ -317,7 +317,7 @@ void CFFL_IFormFiller::OnButtonUp(CPDFSDK_Widget* pWidget,
FX_BOOL CFFL_IFormFiller::OnLButtonDblClk(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point) {
ASSERT(pAnnot->GetPDFAnnot()->GetSubtype() == CPDF_Annot::Subtype::WIDGET);
@@ -330,7 +330,7 @@ FX_BOOL CFFL_IFormFiller::OnLButtonDblClk(CPDFSDK_PageView* pPageView,
FX_BOOL CFFL_IFormFiller::OnMouseMove(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point) {
ASSERT(pAnnot->GetPDFAnnot()->GetSubtype() == CPDF_Annot::Subtype::WIDGET);
@@ -344,7 +344,7 @@ FX_BOOL CFFL_IFormFiller::OnMouseMove(CPDFSDK_PageView* pPageView,
FX_BOOL CFFL_IFormFiller::OnMouseWheel(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
short zDelta,
const CFX_FloatPoint& point) {
ASSERT(pAnnot->GetPDFAnnot()->GetSubtype() == CPDF_Annot::Subtype::WIDGET);
@@ -358,7 +358,7 @@ FX_BOOL CFFL_IFormFiller::OnMouseWheel(CPDFSDK_PageView* pPageView,
FX_BOOL CFFL_IFormFiller::OnRButtonDown(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point) {
ASSERT(pAnnot->GetPDFAnnot()->GetSubtype() == CPDF_Annot::Subtype::WIDGET);
@@ -371,7 +371,7 @@ FX_BOOL CFFL_IFormFiller::OnRButtonDown(CPDFSDK_PageView* pPageView,
FX_BOOL CFFL_IFormFiller::OnRButtonUp(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point) {
ASSERT(pAnnot->GetPDFAnnot()->GetSubtype() == CPDF_Annot::Subtype::WIDGET);
@@ -383,8 +383,8 @@ FX_BOOL CFFL_IFormFiller::OnRButtonUp(CPDFSDK_PageView* pPageView,
}
FX_BOOL CFFL_IFormFiller::OnKeyDown(CPDFSDK_Annot* pAnnot,
- FX_UINT nKeyCode,
- FX_UINT nFlags) {
+ uint32_t nKeyCode,
+ uint32_t nFlags) {
ASSERT(pAnnot->GetPDFAnnot()->GetSubtype() == CPDF_Annot::Subtype::WIDGET);
if (CFFL_FormFiller* pFormFiller = GetFormFiller(pAnnot, FALSE)) {
@@ -395,8 +395,8 @@ FX_BOOL CFFL_IFormFiller::OnKeyDown(CPDFSDK_Annot* pAnnot,
}
FX_BOOL CFFL_IFormFiller::OnChar(CPDFSDK_Annot* pAnnot,
- FX_UINT nChar,
- FX_UINT nFlags) {
+ uint32_t nChar,
+ uint32_t nFlags) {
ASSERT(pAnnot->GetPDFAnnot()->GetSubtype() == CPDF_Annot::Subtype::WIDGET);
if (nChar == FWL_VKEY_Tab)
return TRUE;
@@ -407,7 +407,7 @@ FX_BOOL CFFL_IFormFiller::OnChar(CPDFSDK_Annot* pAnnot,
return FALSE;
}
-FX_BOOL CFFL_IFormFiller::OnSetFocus(CPDFSDK_Annot* pAnnot, FX_UINT nFlag) {
+FX_BOOL CFFL_IFormFiller::OnSetFocus(CPDFSDK_Annot* pAnnot, uint32_t nFlag) {
if (!pAnnot)
return FALSE;
@@ -451,7 +451,7 @@ FX_BOOL CFFL_IFormFiller::OnSetFocus(CPDFSDK_Annot* pAnnot, FX_UINT nFlag) {
return TRUE;
}
-FX_BOOL CFFL_IFormFiller::OnKillFocus(CPDFSDK_Annot* pAnnot, FX_UINT nFlag) {
+FX_BOOL CFFL_IFormFiller::OnKillFocus(CPDFSDK_Annot* pAnnot, uint32_t nFlag) {
if (!pAnnot)
return FALSE;
ASSERT(pAnnot->GetPDFAnnot()->GetSubtype() == CPDF_Annot::Subtype::WIDGET);
@@ -739,7 +739,7 @@ void CFFL_IFormFiller::OnClick(CPDFSDK_Widget* pWidget,
CPDFSDK_PageView* pPageView,
FX_BOOL& bReset,
FX_BOOL& bExit,
- FX_UINT nFlag) {
+ uint32_t nFlag) {
if (!m_bNotifying) {
if (pWidget->HasXFAAAction(PDFSDK_XFA_Click)) {
m_bNotifying = TRUE;
@@ -774,7 +774,7 @@ void CFFL_IFormFiller::OnFull(CPDFSDK_Widget* pWidget,
CPDFSDK_PageView* pPageView,
FX_BOOL& bReset,
FX_BOOL& bExit,
- FX_UINT nFlag) {
+ uint32_t nFlag) {
if (!m_bNotifying) {
if (pWidget->HasXFAAAction(PDFSDK_XFA_Full)) {
m_bNotifying = TRUE;
@@ -841,7 +841,7 @@ void CFFL_IFormFiller::OnPreOpen(CPDFSDK_Widget* pWidget,
CPDFSDK_PageView* pPageView,
FX_BOOL& bReset,
FX_BOOL& bExit,
- FX_UINT nFlag) {
+ uint32_t nFlag) {
if (!m_bNotifying) {
if (pWidget->HasXFAAAction(PDFSDK_XFA_PreOpen)) {
m_bNotifying = TRUE;
@@ -876,7 +876,7 @@ void CFFL_IFormFiller::OnPostOpen(CPDFSDK_Widget* pWidget,
CPDFSDK_PageView* pPageView,
FX_BOOL& bReset,
FX_BOOL& bExit,
- FX_UINT nFlag) {
+ uint32_t nFlag) {
if (!m_bNotifying) {
if (pWidget->HasXFAAAction(PDFSDK_XFA_PostOpen)) {
m_bNotifying = TRUE;
diff --git a/fpdfsdk/formfiller/cffl_iformfiller.h b/fpdfsdk/formfiller/cffl_iformfiller.h
index 26638f8334..ff942bedf1 100644
--- a/fpdfsdk/formfiller/cffl_iformfiller.h
+++ b/fpdfsdk/formfiller/cffl_iformfiller.h
@@ -40,48 +40,50 @@ class CFFL_IFormFiller : public IPWL_Filler_Notify {
virtual void OnMouseEnter(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlag);
+ uint32_t nFlag);
virtual void OnMouseExit(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlag);
+ uint32_t nFlag);
virtual FX_BOOL OnLButtonDown(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point);
virtual FX_BOOL OnLButtonUp(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point);
virtual FX_BOOL OnLButtonDblClk(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point);
virtual FX_BOOL OnMouseMove(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point);
virtual FX_BOOL OnMouseWheel(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
short zDelta,
const CFX_FloatPoint& point);
virtual FX_BOOL OnRButtonDown(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point);
virtual FX_BOOL OnRButtonUp(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point);
virtual FX_BOOL OnKeyDown(CPDFSDK_Annot* pAnnot,
- FX_UINT nKeyCode,
- FX_UINT nFlags);
- virtual FX_BOOL OnChar(CPDFSDK_Annot* pAnnot, FX_UINT nChar, FX_UINT nFlags);
+ uint32_t nKeyCode,
+ uint32_t nFlags);
+ virtual FX_BOOL OnChar(CPDFSDK_Annot* pAnnot,
+ uint32_t nChar,
+ uint32_t nFlags);
- virtual FX_BOOL OnSetFocus(CPDFSDK_Annot* pAnnot, FX_UINT nFlag);
- virtual FX_BOOL OnKillFocus(CPDFSDK_Annot* pAnnot, FX_UINT nFlag);
+ virtual FX_BOOL OnSetFocus(CPDFSDK_Annot* pAnnot, uint32_t nFlag);
+ virtual FX_BOOL OnKillFocus(CPDFSDK_Annot* pAnnot, uint32_t nFlag);
CFFL_FormFiller* GetFormFiller(CPDFSDK_Annot* pAnnot, FX_BOOL bRegister);
void RemoveFormFiller(CPDFSDK_Annot* pAnnot);
@@ -115,28 +117,28 @@ class CFFL_IFormFiller : public IPWL_Filler_Notify {
CPDFSDK_PageView* pPageView,
FX_BOOL& bReset,
FX_BOOL& bExit,
- FX_UINT nFlag);
+ uint32_t nFlag);
#ifdef PDF_ENABLE_XFA
void OnClick(CPDFSDK_Widget* pWidget,
CPDFSDK_PageView* pPageView,
FX_BOOL& bReset,
FX_BOOL& bExit,
- FX_UINT nFlag);
+ uint32_t nFlag);
void OnFull(CPDFSDK_Widget* pWidget,
CPDFSDK_PageView* pPageView,
FX_BOOL& bReset,
FX_BOOL& bExit,
- FX_UINT nFlag);
+ uint32_t nFlag);
void OnPreOpen(CPDFSDK_Widget* pWidget,
CPDFSDK_PageView* pPageView,
FX_BOOL& bReset,
FX_BOOL& bExit,
- FX_UINT nFlag);
+ uint32_t nFlag);
void OnPostOpen(CPDFSDK_Widget* pWidget,
CPDFSDK_PageView* pPageView,
FX_BOOL& bReset,
FX_BOOL& bExit,
- FX_UINT nFlag);
+ uint32_t nFlag);
#endif // PDF_ENABLE_XFA
private:
diff --git a/fpdfsdk/formfiller/cffl_listbox.cpp b/fpdfsdk/formfiller/cffl_listbox.cpp
index e9627cb4e4..a089432477 100644
--- a/fpdfsdk/formfiller/cffl_listbox.cpp
+++ b/fpdfsdk/formfiller/cffl_listbox.cpp
@@ -83,8 +83,8 @@ CPWL_Wnd* CFFL_ListBox::NewPDFWindow(const PWL_CREATEPARAM& cp,
}
FX_BOOL CFFL_ListBox::OnChar(CPDFSDK_Annot* pAnnot,
- FX_UINT nChar,
- FX_UINT nFlags) {
+ uint32_t nChar,
+ uint32_t nFlags) {
return CFFL_FormFiller::OnChar(pAnnot, nChar, nFlags);
}
diff --git a/fpdfsdk/formfiller/cffl_listbox.h b/fpdfsdk/formfiller/cffl_listbox.h
index 29d0884af0..8d8ed0d5ab 100644
--- a/fpdfsdk/formfiller/cffl_listbox.h
+++ b/fpdfsdk/formfiller/cffl_listbox.h
@@ -23,7 +23,9 @@ class CFFL_ListBox : public CFFL_FormFiller {
PWL_CREATEPARAM GetCreateParam() override;
CPWL_Wnd* NewPDFWindow(const PWL_CREATEPARAM& cp,
CPDFSDK_PageView* pPageView) override;
- FX_BOOL OnChar(CPDFSDK_Annot* pAnnot, FX_UINT nChar, FX_UINT nFlags) override;
+ FX_BOOL OnChar(CPDFSDK_Annot* pAnnot,
+ uint32_t nChar,
+ uint32_t nFlags) override;
FX_BOOL IsDataChanged(CPDFSDK_PageView* pPageView) override;
void SaveData(CPDFSDK_PageView* pPageView) override;
void GetActionData(CPDFSDK_PageView* pPageView,
diff --git a/fpdfsdk/formfiller/cffl_pushbutton.cpp b/fpdfsdk/formfiller/cffl_pushbutton.cpp
index 630b2d52d1..4b147fbfb1 100644
--- a/fpdfsdk/formfiller/cffl_pushbutton.cpp
+++ b/fpdfsdk/formfiller/cffl_pushbutton.cpp
@@ -24,8 +24,8 @@ CPWL_Wnd* CFFL_PushButton::NewPDFWindow(const PWL_CREATEPARAM& cp,
}
FX_BOOL CFFL_PushButton::OnChar(CPDFSDK_Annot* pAnnot,
- FX_UINT nChar,
- FX_UINT nFlags) {
+ uint32_t nChar,
+ uint32_t nFlags) {
return CFFL_FormFiller::OnChar(pAnnot, nChar, nFlags);
}
diff --git a/fpdfsdk/formfiller/cffl_pushbutton.h b/fpdfsdk/formfiller/cffl_pushbutton.h
index cc49ed8332..cac09047e6 100644
--- a/fpdfsdk/formfiller/cffl_pushbutton.h
+++ b/fpdfsdk/formfiller/cffl_pushbutton.h
@@ -17,7 +17,9 @@ class CFFL_PushButton : public CFFL_Button {
// CFFL_Button
CPWL_Wnd* NewPDFWindow(const PWL_CREATEPARAM& cp,
CPDFSDK_PageView* pPageView) override;
- FX_BOOL OnChar(CPDFSDK_Annot* pAnnot, FX_UINT nChar, FX_UINT nFlags) override;
+ FX_BOOL OnChar(CPDFSDK_Annot* pAnnot,
+ uint32_t nChar,
+ uint32_t nFlags) override;
void OnDraw(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
CFX_RenderDevice* pDevice,
diff --git a/fpdfsdk/formfiller/cffl_radiobutton.cpp b/fpdfsdk/formfiller/cffl_radiobutton.cpp
index ddb3d2765d..ec3aee3d8c 100644
--- a/fpdfsdk/formfiller/cffl_radiobutton.cpp
+++ b/fpdfsdk/formfiller/cffl_radiobutton.cpp
@@ -29,8 +29,8 @@ CPWL_Wnd* CFFL_RadioButton::NewPDFWindow(const PWL_CREATEPARAM& cp,
}
FX_BOOL CFFL_RadioButton::OnKeyDown(CPDFSDK_Annot* pAnnot,
- FX_UINT nKeyCode,
- FX_UINT nFlags) {
+ uint32_t nKeyCode,
+ uint32_t nFlags) {
switch (nKeyCode) {
case FWL_VKEY_Return:
case FWL_VKEY_Space:
@@ -41,8 +41,8 @@ FX_BOOL CFFL_RadioButton::OnKeyDown(CPDFSDK_Annot* pAnnot,
}
FX_BOOL CFFL_RadioButton::OnChar(CPDFSDK_Annot* pAnnot,
- FX_UINT nChar,
- FX_UINT nFlags) {
+ uint32_t nChar,
+ uint32_t nFlags) {
switch (nChar) {
case FWL_VKEY_Return:
case FWL_VKEY_Space: {
@@ -75,7 +75,7 @@ FX_BOOL CFFL_RadioButton::OnChar(CPDFSDK_Annot* pAnnot,
FX_BOOL CFFL_RadioButton::OnLButtonUp(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point) {
CFFL_Button::OnLButtonUp(pPageView, pAnnot, nFlags, point);
diff --git a/fpdfsdk/formfiller/cffl_radiobutton.h b/fpdfsdk/formfiller/cffl_radiobutton.h
index 52b1276e3a..28dd412100 100644
--- a/fpdfsdk/formfiller/cffl_radiobutton.h
+++ b/fpdfsdk/formfiller/cffl_radiobutton.h
@@ -18,12 +18,14 @@ class CFFL_RadioButton : public CFFL_Button {
CPWL_Wnd* NewPDFWindow(const PWL_CREATEPARAM& cp,
CPDFSDK_PageView* pPageView) override;
FX_BOOL OnKeyDown(CPDFSDK_Annot* pAnnot,
- FX_UINT nKeyCode,
- FX_UINT nFlags) override;
- FX_BOOL OnChar(CPDFSDK_Annot* pAnnot, FX_UINT nChar, FX_UINT nFlags) override;
+ uint32_t nKeyCode,
+ uint32_t nFlags) override;
+ FX_BOOL OnChar(CPDFSDK_Annot* pAnnot,
+ uint32_t nChar,
+ uint32_t nFlags) override;
FX_BOOL OnLButtonUp(CPDFSDK_PageView* pPageView,
CPDFSDK_Annot* pAnnot,
- FX_UINT nFlags,
+ uint32_t nFlags,
const CFX_FloatPoint& point) override;
FX_BOOL IsDataChanged(CPDFSDK_PageView* pPageView) override;
void SaveData(CPDFSDK_PageView* pPageView) override;
diff --git a/fpdfsdk/formfiller/cffl_textfield.cpp b/fpdfsdk/formfiller/cffl_textfield.cpp
index f7a2740bd8..9aad1894ae 100644
--- a/fpdfsdk/formfiller/cffl_textfield.cpp
+++ b/fpdfsdk/formfiller/cffl_textfield.cpp
@@ -104,8 +104,8 @@ CPWL_Wnd* CFFL_TextField::NewPDFWindow(const PWL_CREATEPARAM& cp,
}
FX_BOOL CFFL_TextField::OnChar(CPDFSDK_Annot* pAnnot,
- FX_UINT nChar,
- FX_UINT nFlags) {
+ uint32_t nChar,
+ uint32_t nFlags) {
switch (nChar) {
case FWL_VKEY_Return:
if (!(m_pWidget->GetFieldFlags() & FIELDFLAG_MULTILINE)) {
diff --git a/fpdfsdk/formfiller/cffl_textfield.h b/fpdfsdk/formfiller/cffl_textfield.h
index 717f6d3c61..5c94b2e55d 100644
--- a/fpdfsdk/formfiller/cffl_textfield.h
+++ b/fpdfsdk/formfiller/cffl_textfield.h
@@ -34,7 +34,9 @@ class CFFL_TextField : public CFFL_FormFiller, public IPWL_FocusHandler {
PWL_CREATEPARAM GetCreateParam() override;
CPWL_Wnd* NewPDFWindow(const PWL_CREATEPARAM& cp,
CPDFSDK_PageView* pPageView) override;
- FX_BOOL OnChar(CPDFSDK_Annot* pAnnot, FX_UINT nChar, FX_UINT nFlags) override;
+ FX_BOOL OnChar(CPDFSDK_Annot* pAnnot,
+ uint32_t nChar,
+ uint32_t nFlags) override;
FX_BOOL IsDataChanged(CPDFSDK_PageView* pPageView) override;
void SaveData(CPDFSDK_PageView* pPageView) override;
void GetActionData(CPDFSDK_PageView* pPageView,
diff --git a/fpdfsdk/include/cpdfsdk_document.h b/fpdfsdk/include/cpdfsdk_document.h
index 9f6ac79202..5a83b74296 100644
--- a/fpdfsdk/include/cpdfsdk_document.h
+++ b/fpdfsdk/include/cpdfsdk_document.h
@@ -68,8 +68,8 @@ class CPDFSDK_Document : public CFX_Observable<CPDFSDK_Document> {
IJS_Runtime* GetJsRuntime();
- FX_BOOL SetFocusAnnot(CPDFSDK_Annot* pAnnot, FX_UINT nFlag = 0);
- FX_BOOL KillFocusAnnot(FX_UINT nFlag = 0);
+ FX_BOOL SetFocusAnnot(CPDFSDK_Annot* pAnnot, uint32_t nFlag = 0);
+ FX_BOOL KillFocusAnnot(uint32_t nFlag = 0);
FX_BOOL ExtractPages(const std::vector<uint16_t>& arrExtraPages,
CPDF_Document* pDstDoc);
diff --git a/fpdfsdk/include/cpdfsdk_environment.h b/fpdfsdk/include/cpdfsdk_environment.h
index fe63ecad13..59b260859a 100644
--- a/fpdfsdk/include/cpdfsdk_environment.h
+++ b/fpdfsdk/include/cpdfsdk_environment.h
@@ -359,8 +359,8 @@ class CPDFSDK_Environment final {
int JS_appAlert(const FX_WCHAR* Msg,
const FX_WCHAR* Title,
- FX_UINT Type,
- FX_UINT Icon);
+ uint32_t Type,
+ uint32_t Icon);
int JS_appResponse(const FX_WCHAR* Question,
const FX_WCHAR* Title,
const FX_WCHAR* Default,
diff --git a/fpdfsdk/include/cpdfsdk_pageview.h b/fpdfsdk/include/cpdfsdk_pageview.h
index a496334c2d..d22b6b48a0 100644
--- a/fpdfsdk/include/cpdfsdk_pageview.h
+++ b/fpdfsdk/include/cpdfsdk_pageview.h
@@ -39,10 +39,10 @@ class CPDFSDK_PageView final : public CPDF_Page::View {
const CPDF_Annot* GetPDFWidgetAtPoint(FX_FLOAT pageX, FX_FLOAT pageY);
CPDFSDK_Annot* GetFXWidgetAtPoint(FX_FLOAT pageX, FX_FLOAT pageY);
CPDFSDK_Annot* GetFocusAnnot();
- void SetFocusAnnot(CPDFSDK_Annot* pSDKAnnot, FX_UINT nFlag = 0) {
+ void SetFocusAnnot(CPDFSDK_Annot* pSDKAnnot, uint32_t nFlag = 0) {
m_pSDKDoc->SetFocusAnnot(pSDKAnnot, nFlag);
}
- FX_BOOL KillFocusAnnot(FX_UINT nFlag = 0) {
+ FX_BOOL KillFocusAnnot(uint32_t nFlag = 0) {
return m_pSDKDoc->KillFocusAnnot(nFlag);
}
void KillFocusAnnotIfNeeded();
@@ -65,13 +65,13 @@ class CPDFSDK_PageView final : public CPDF_Page::View {
CPDF_Page* GetPDFPage() const;
CPDF_Document* GetPDFDocument();
CPDFSDK_Document* GetSDKDocument() { return m_pSDKDoc; }
- FX_BOOL OnLButtonDown(const CFX_FloatPoint& point, FX_UINT nFlag);
- FX_BOOL OnLButtonUp(const CFX_FloatPoint& point, FX_UINT nFlag);
+ FX_BOOL OnLButtonDown(const CFX_FloatPoint& point, uint32_t nFlag);
+ FX_BOOL OnLButtonUp(const CFX_FloatPoint& point, uint32_t nFlag);
#ifdef PDF_ENABLE_XFA
- FX_BOOL OnRButtonDown(const CFX_FloatPoint& point, FX_UINT nFlag);
- FX_BOOL OnRButtonUp(const CFX_FloatPoint& point, FX_UINT nFlag);
+ FX_BOOL OnRButtonDown(const CFX_FloatPoint& point, uint32_t nFlag);
+ FX_BOOL OnRButtonUp(const CFX_FloatPoint& point, uint32_t nFlag);
#endif // PDF_ENABLE_XFA
- FX_BOOL OnChar(int nChar, FX_UINT nFlag);
+ FX_BOOL OnChar(int nChar, uint32_t nFlag);
FX_BOOL OnKeyDown(int nKeyCode, int nFlag);
FX_BOOL OnKeyUp(int nKeyCode, int nFlag);
diff --git a/fpdfsdk/include/fsdk_define.h b/fpdfsdk/include/fsdk_define.h
index 909cbbd9d2..cb4e5c34a6 100644
--- a/fpdfsdk/include/fsdk_define.h
+++ b/fpdfsdk/include/fsdk_define.h
@@ -20,18 +20,6 @@
#include <tchar.h>
#endif
-// Convert a #FX_ARGB to a #FX_COLORREF.
-#define FX_ARGBTOCOLORREF(argb) \
- ((((uint32_t)argb & 0x00FF0000) >> 16) | ((uint32_t)argb & 0x0000FF00) | \
- (((uint32_t)argb & 0x000000FF) << 16))
-
-// Convert a #FX_COLORREF to a #FX_ARGB.
-#define FX_COLORREFTOARGB(rgb) \
- ((uint32_t)0xFF000000 | (((uint32_t)rgb & 0x000000FF) << 16) | \
- ((uint32_t)rgb & 0x0000FF00) | (((uint32_t)rgb & 0x00FF0000) >> 16))
-
-typedef unsigned int FX_UINT;
-
class CPDF_Annot;
class CPDF_Page;
class CPDF_PageRenderContext;
diff --git a/fpdfsdk/javascript/app.cpp b/fpdfsdk/javascript/app.cpp
index 6e5dc4a2c7..fc2a440da9 100644
--- a/fpdfsdk/javascript/app.cpp
+++ b/fpdfsdk/javascript/app.cpp
@@ -43,7 +43,7 @@ class GlobalTimer {
CFX_WideString GetJScript() const { return m_swJScript; }
private:
- using TimerMap = std::map<FX_UINT, GlobalTimer*>;
+ using TimerMap = std::map<uint32_t, GlobalTimer*>;
static TimerMap* GetGlobalTimerMap();
uint32_t m_nTimerID;
diff --git a/fpdfsdk/javascript/resource.cpp b/fpdfsdk/javascript/resource.cpp
index c4edeae905..6113c54338 100644
--- a/fpdfsdk/javascript/resource.cpp
+++ b/fpdfsdk/javascript/resource.cpp
@@ -6,7 +6,7 @@
#include "fpdfsdk/javascript/resource.h"
-CFX_WideString JSGetStringFromID(FX_UINT id) {
+CFX_WideString JSGetStringFromID(uint32_t id) {
switch (id) {
case IDS_STRING_JSALERT:
return L"Alert";
diff --git a/fpdfsdk/javascript/resource.h b/fpdfsdk/javascript/resource.h
index d775e94c5e..7f041cd21a 100644
--- a/fpdfsdk/javascript/resource.h
+++ b/fpdfsdk/javascript/resource.h
@@ -7,8 +7,7 @@
#ifndef FPDFSDK_JAVASCRIPT_RESOURCE_H_
#define FPDFSDK_JAVASCRIPT_RESOURCE_H_
-#include "core/fxcrt/include/fx_string.h" // For CFX_WideString.
-#include "fpdfsdk/include/fsdk_define.h" // For FX_UINT.
+#include "core/fxcrt/include/fx_string.h"
class CJS_Context;
@@ -33,7 +32,7 @@ class CJS_Context;
#define IDS_STRING_JSNOPERMISSION 25639
#define IDS_STRING_JSBADOBJECT 25640
-CFX_WideString JSGetStringFromID(FX_UINT id);
+CFX_WideString JSGetStringFromID(uint32_t id);
CFX_WideString JSFormatErrorString(const char* class_name,
const char* property_name,
const CFX_WideString& details);