Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(602)

Unified Diff: xfa/fwl/core/cfwl_combolist.cpp

Issue 2530993002: Cleanup FWL Event and Message code. (Closed)
Patch Set: Review feedback Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: xfa/fwl/core/cfwl_combolist.cpp
diff --git a/xfa/fwl/core/cfwl_combolist.cpp b/xfa/fwl/core/cfwl_combolist.cpp
index e333cda18a8fd083edebc81724172f81e51d80b0..ad80ac04757fa1da27f5a6e0f333131b137d90fb 100644
--- a/xfa/fwl/core/cfwl_combolist.cpp
+++ b/xfa/fwl/core/cfwl_combolist.cpp
@@ -77,12 +77,12 @@ void CFWL_ComboList::OnProcessMessage(CFWL_Message* pMessage) {
if (!pMessage)
return;
- CFWL_MessageType dwHashCode = pMessage->GetClassID();
+ CFWL_Message::Type type = pMessage->GetType();
bool backDefault = true;
- if (dwHashCode == CFWL_MessageType::SetFocus ||
- dwHashCode == CFWL_MessageType::KillFocus) {
- OnDropListFocusChanged(pMessage, dwHashCode == CFWL_MessageType::SetFocus);
- } else if (dwHashCode == CFWL_MessageType::Mouse) {
+ if (type == CFWL_Message::Type::SetFocus ||
+ type == CFWL_Message::Type::KillFocus) {
+ OnDropListFocusChanged(pMessage, type == CFWL_Message::Type::SetFocus);
+ } else if (type == CFWL_Message::Type::Mouse) {
CFWL_MsgMouse* pMsg = static_cast<CFWL_MsgMouse*>(pMessage);
CFWL_ScrollBar* vertSB = GetVertScrollBar();
if (IsShowScrollBar(true) && vertSB) {
@@ -114,7 +114,7 @@ void CFWL_ComboList::OnProcessMessage(CFWL_Message* pMessage) {
default:
break;
}
- } else if (dwHashCode == CFWL_MessageType::Key) {
+ } else if (type == CFWL_Message::Type::Key) {
backDefault = !OnDropListKey(static_cast<CFWL_MsgKey*>(pMessage));
}
if (backDefault)

Powered by Google App Engine
This is Rietveld 408576698