summaryrefslogtreecommitdiff
path: root/xfa/fxfa/app/xfa_ffchoicelist.cpp
diff options
context:
space:
mode:
authordsinclair <dsinclair@chromium.org>2016-04-21 13:12:06 -0700
committerCommit bot <commit-bot@chromium.org>2016-04-21 13:12:06 -0700
commit5d9da0c1255a75dd9b7b2005f8b7d6ae4948feaf (patch)
treedf40bedc2582cab695e7bf4b2056bfddd4969908 /xfa/fxfa/app/xfa_ffchoicelist.cpp
parent0f6425fff33e4096b4e1fbfb954edae1349c0145 (diff)
downloadpdfium-5d9da0c1255a75dd9b7b2005f8b7d6ae4948feaf.tar.xz
Remove CFWL_Note.
This CL removes the CFWL_Note class. The two subclasses, CFWL_Event and CFWL_Message are distinct types and should not be related by the subclass. The code has been updated to pass the correct types as needed. The various FWL_EVTHASH and FWL_MSGHASH defines have all been removed and turned into an FWL_EventType and FWL_MessageType enum classes. BUG=pdfium:474 Review URL: https://codereview.chromium.org/1901183002
Diffstat (limited to 'xfa/fxfa/app/xfa_ffchoicelist.cpp')
-rw-r--r--xfa/fxfa/app/xfa_ffchoicelist.cpp24
1 files changed, 13 insertions, 11 deletions
diff --git a/xfa/fxfa/app/xfa_ffchoicelist.cpp b/xfa/fxfa/app/xfa_ffchoicelist.cpp
index a13c36d973..cfd78c2035 100644
--- a/xfa/fxfa/app/xfa_ffchoicelist.cpp
+++ b/xfa/fxfa/app/xfa_ffchoicelist.cpp
@@ -185,14 +185,14 @@ int32_t CXFA_FFListBox::OnProcessMessage(CFWL_Message* pMessage) {
}
FWL_ERR CXFA_FFListBox::OnProcessEvent(CFWL_Event* pEvent) {
CXFA_FFField::OnProcessEvent(pEvent);
- uint32_t dwEventID = pEvent->GetClassID();
- switch (dwEventID) {
- case FWL_EVTHASH_LTB_SelChanged: {
+ switch (pEvent->GetClassID()) {
+ case CFWL_EventType::SelectChanged: {
CFX_Int32Array arrSels;
OnSelectChanged(m_pNormalWidget->GetWidget(), arrSels);
break;
}
- default: {}
+ default:
+ break;
}
return m_pOldDelegate->OnProcessEvent(pEvent);
}
@@ -498,33 +498,35 @@ void CXFA_FFComboBox::OnPostOpen(IFWL_Widget* pWidget) {
int32_t CXFA_FFComboBox::OnProcessMessage(CFWL_Message* pMessage) {
return m_pOldDelegate->OnProcessMessage(pMessage);
}
+
FWL_ERR CXFA_FFComboBox::OnProcessEvent(CFWL_Event* pEvent) {
CXFA_FFField::OnProcessEvent(pEvent);
- uint32_t dwEventID = pEvent->GetClassID();
- switch (dwEventID) {
- case FWL_EVTHASH_CMB_SelChanged: {
+ switch (pEvent->GetClassID()) {
+ case CFWL_EventType::SelectChanged: {
CFWL_EvtCmbSelChanged* postEvent = (CFWL_EvtCmbSelChanged*)pEvent;
OnSelectChanged(m_pNormalWidget->GetWidget(), postEvent->iArraySels,
postEvent->bLButtonUp);
break;
}
- case FWL_EVTHASH_CMB_EditChanged: {
+ case CFWL_EventType::EditChanged: {
CFX_WideString wsChanged;
OnTextChanged(m_pNormalWidget->GetWidget(), wsChanged);
break;
}
- case FWL_EVTHASH_CMB_PreDropDown: {
+ case CFWL_EventType::PreDropDown: {
OnPreOpen(m_pNormalWidget->GetWidget());
break;
}
- case FWL_EVTHASH_CMB_PostDropDown: {
+ case CFWL_EventType::PostDropDown: {
OnPostOpen(m_pNormalWidget->GetWidget());
break;
}
- default: {}
+ default:
+ break;
}
return m_pOldDelegate->OnProcessEvent(pEvent);
}
+
FWL_ERR CXFA_FFComboBox::OnDrawWidget(CFX_Graphics* pGraphics,
const CFX_Matrix* pMatrix) {
return m_pOldDelegate->OnDrawWidget(pGraphics, pMatrix);