From 2c489cc41023a40648dfde988d11b8ec2b66c7d0 Mon Sep 17 00:00:00 2001 From: dsinclair Date: Wed, 23 Nov 2016 16:17:20 -0800 Subject: Merge IFWL and CFWL classes. This CL merges the IFWL hierarchy into the CFWL hierachy. All CFWL proxy methods have been replaced by the IFWL implementations. Review-Url: https://codereview.chromium.org/2524173002 --- xfa/fwl/core/cfwl_combolist.cpp | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) (limited to 'xfa/fwl/core/cfwl_combolist.cpp') diff --git a/xfa/fwl/core/cfwl_combolist.cpp b/xfa/fwl/core/cfwl_combolist.cpp index e98f38e81a..0476498388 100644 --- a/xfa/fwl/core/cfwl_combolist.cpp +++ b/xfa/fwl/core/cfwl_combolist.cpp @@ -10,18 +10,18 @@ #include #include "third_party/base/ptr_util.h" +#include "xfa/fwl/core/cfwl_combobox.h" #include "xfa/fwl/core/cfwl_comboedit.h" +#include "xfa/fwl/core/cfwl_listbox.h" #include "xfa/fwl/core/cfwl_msgkey.h" #include "xfa/fwl/core/cfwl_msgkillfocus.h" #include "xfa/fwl/core/cfwl_msgmouse.h" -#include "xfa/fwl/core/ifwl_combobox.h" -#include "xfa/fwl/core/ifwl_listbox.h" CFWL_ComboList::CFWL_ComboList( const CFWL_App* app, std::unique_ptr properties, - IFWL_Widget* pOuter) - : IFWL_ListBox(app, std::move(properties), pOuter), m_bNotifyOwner(true) { + CFWL_Widget* pOuter) + : CFWL_ListBox(app, std::move(properties), pOuter), m_bNotifyOwner(true) { ASSERT(pOuter); } @@ -68,7 +68,7 @@ void CFWL_ComboList::ChangeSelected(int32_t iSel) { void CFWL_ComboList::ClientToOuter(FX_FLOAT& fx, FX_FLOAT& fy) { fx += m_pProperties->m_rtWidget.left, fy += m_pProperties->m_rtWidget.top; - IFWL_Widget* pOwner = GetOwner(); + CFWL_Widget* pOwner = GetOwner(); if (!pOwner) return; pOwner->TransformTo(m_pOuter, fx, fy); @@ -119,7 +119,7 @@ void CFWL_ComboList::OnProcessMessage(CFWL_Message* pMessage) { backDefault = !OnDropListKey(static_cast(pMessage)); } if (backDefault) - IFWL_ListBox::OnProcessMessage(pMessage); + CFWL_ListBox::OnProcessMessage(pMessage); } void CFWL_ComboList::OnDropListFocusChanged(CFWL_Message* pMsg, bool bSet) { @@ -127,7 +127,7 @@ void CFWL_ComboList::OnDropListFocusChanged(CFWL_Message* pMsg, bool bSet) { return; CFWL_MsgKillFocus* pKill = static_cast(pMsg); - IFWL_ComboBox* pOuter = static_cast(m_pOuter); + CFWL_ComboBox* pOuter = static_cast(m_pOuter); if (pKill->m_pSetFocus == m_pOuter || pKill->m_pSetFocus == pOuter->GetComboEdit()) { pOuter->ShowDropList(false); @@ -154,7 +154,7 @@ void CFWL_ComboList::OnDropListMouseMove(CFWL_MsgMouse* pMsg) { ChangeSelected(GetItemIndex(this, hItem)); } else if (m_bNotifyOwner) { ClientToOuter(pMsg->m_fx, pMsg->m_fy); - IFWL_ComboBox* pOuter = static_cast(m_pOuter); + CFWL_ComboBox* pOuter = static_cast(m_pOuter); pOuter->GetDelegate()->OnProcessMessage(pMsg); } } @@ -163,12 +163,12 @@ void CFWL_ComboList::OnDropListLButtonDown(CFWL_MsgMouse* pMsg) { if (GetRTClient().Contains(pMsg->m_fx, pMsg->m_fy)) return; - IFWL_ComboBox* pOuter = static_cast(m_pOuter); + CFWL_ComboBox* pOuter = static_cast(m_pOuter); pOuter->ShowDropList(false); } void CFWL_ComboList::OnDropListLButtonUp(CFWL_MsgMouse* pMsg) { - IFWL_ComboBox* pOuter = static_cast(m_pOuter); + CFWL_ComboBox* pOuter = static_cast(m_pOuter); if (m_bNotifyOwner) { ClientToOuter(pMsg->m_fx, pMsg->m_fy); pOuter->GetDelegate()->OnProcessMessage(pMsg); @@ -190,7 +190,7 @@ void CFWL_ComboList::OnDropListLButtonUp(CFWL_MsgMouse* pMsg) { } bool CFWL_ComboList::OnDropListKey(CFWL_MsgKey* pKey) { - IFWL_ComboBox* pOuter = static_cast(m_pOuter); + CFWL_ComboBox* pOuter = static_cast(m_pOuter); bool bPropagate = false; if (pKey->m_dwCmd == FWL_KeyCommand::KeyDown) { uint32_t dwKeyCode = pKey->m_dwKeyCode; @@ -229,7 +229,7 @@ void CFWL_ComboList::OnDropListKeyDown(CFWL_MsgKey* pKey) { case FWL_VKEY_Down: case FWL_VKEY_Home: case FWL_VKEY_End: { - IFWL_ComboBox* pOuter = static_cast(m_pOuter); + CFWL_ComboBox* pOuter = static_cast(m_pOuter); CFWL_ListItem* hItem = GetItem(this, pOuter->GetCurrentSelection()); hItem = GetListItem(hItem, dwKeyCode); if (!hItem) -- cgit v1.2.3