summaryrefslogtreecommitdiff
path: root/xfa/fwl/core/ifwl_combobox.cpp
diff options
context:
space:
mode:
authordsinclair <dsinclair@chromium.org>2016-11-23 10:49:33 -0800
committerCommit bot <commit-bot@chromium.org>2016-11-23 10:49:33 -0800
commit7c47e1d3172ce6f625b93be50aac2ebf86a45d0c (patch)
treebb7beae7637635cd0c631f015411a63fd2892486 /xfa/fwl/core/ifwl_combobox.cpp
parent7172b71a005c181e9f103ac0e19f6675bf3bc8e8 (diff)
downloadpdfium-7c47e1d3172ce6f625b93be50aac2ebf86a45d0c.tar.xz
Remove DataProvider from CFWL_WidgetPropertieschromium/2931chromium/2930
This CL removes the generic DataProvider code from CFWL_WidgetProperties and adds the specific providers to the two classes that require them. Review-Url: https://codereview.chromium.org/2527683002
Diffstat (limited to 'xfa/fwl/core/ifwl_combobox.cpp')
-rw-r--r--xfa/fwl/core/ifwl_combobox.cpp10
1 files changed, 4 insertions, 6 deletions
diff --git a/xfa/fwl/core/ifwl_combobox.cpp b/xfa/fwl/core/ifwl_combobox.cpp
index 19d1c3f87f..7917b4eabf 100644
--- a/xfa/fwl/core/ifwl_combobox.cpp
+++ b/xfa/fwl/core/ifwl_combobox.cpp
@@ -50,14 +50,14 @@ IFWL_ComboBox::IFWL_ComboBox(const CFWL_App* app,
return;
}
- auto prop =
- pdfium::MakeUnique<CFWL_WidgetProperties>(m_pProperties->m_pDataProvider);
+ auto prop = pdfium::MakeUnique<CFWL_WidgetProperties>();
prop->m_pThemeProvider = m_pProperties->m_pThemeProvider;
prop->m_dwStyles |= FWL_WGTSTYLE_Border | FWL_WGTSTYLE_VScroll;
if (m_pProperties->m_dwStyleExes & FWL_STYLEEXT_CMB_ListItemIconText)
prop->m_dwStyleExes |= FWL_STYLEEXT_LTB_Icon;
+ m_pListBox =
+ pdfium::MakeUnique<IFWL_ComboList>(m_pOwnerApp, std::move(prop), this);
- m_pListBox.reset(new IFWL_ComboList(m_pOwnerApp, std::move(prop), this));
if ((m_pProperties->m_dwStyleExes & FWL_STYLEEXT_CMB_DropDown) && !m_pEdit) {
m_pEdit.reset(new IFWL_ComboEdit(
m_pOwnerApp, pdfium::MakeUnique<CFWL_WidgetProperties>(), this));
@@ -590,13 +590,11 @@ void IFWL_ComboBox::DisForm_InitComboList() {
if (m_pListBox)
return;
- auto prop =
- pdfium::MakeUnique<CFWL_WidgetProperties>(m_pProperties->m_pDataProvider);
+ auto prop = pdfium::MakeUnique<CFWL_WidgetProperties>();
prop->m_pParent = this;
prop->m_dwStyles = FWL_WGTSTYLE_Border | FWL_WGTSTYLE_VScroll;
prop->m_dwStates = FWL_WGTSTATE_Invisible;
prop->m_pThemeProvider = m_pProperties->m_pThemeProvider;
-
m_pListBox =
pdfium::MakeUnique<IFWL_ComboList>(m_pOwnerApp, std::move(prop), this);
}