summaryrefslogtreecommitdiff
path: root/xfa/fwl/basewidget/fwl_listboximp.cpp
diff options
context:
space:
mode:
authordsinclair <dsinclair@chromium.org>2016-10-17 18:14:25 -0700
committerCommit bot <commit-bot@chromium.org>2016-10-17 18:14:25 -0700
commit878dd5b121b38e6eaba5b3f3a90d0a9abf60feaf (patch)
tree6b490d5e54c0d2e213d18b5e4bfe106f61eb1390 /xfa/fwl/basewidget/fwl_listboximp.cpp
parent8021a646f18d76518be32c36907a04f213a0e21c (diff)
downloadpdfium-878dd5b121b38e6eaba5b3f3a90d0a9abf60feaf.tar.xz
Cleanup unneeded FWL theme code.
This CL removes FWL theme code methods which do not have implementations. Review-Url: https://codereview.chromium.org/2422373002
Diffstat (limited to 'xfa/fwl/basewidget/fwl_listboximp.cpp')
-rw-r--r--xfa/fwl/basewidget/fwl_listboximp.cpp20
1 files changed, 4 insertions, 16 deletions
diff --git a/xfa/fwl/basewidget/fwl_listboximp.cpp b/xfa/fwl/basewidget/fwl_listboximp.cpp
index 3f65837883..33a0a8d1ee 100644
--- a/xfa/fwl/basewidget/fwl_listboximp.cpp
+++ b/xfa/fwl/basewidget/fwl_listboximp.cpp
@@ -202,10 +202,6 @@ FWL_Error CFWL_ListBoxImp::SetThemeProvider(
IFWL_ThemeProvider* pThemeProvider) {
if (!pThemeProvider)
return FWL_Error::Indefinite;
- if (!pThemeProvider->IsValidWidget(m_pInterface)) {
- m_pScrollBarTP = pThemeProvider;
- return FWL_Error::Succeeded;
- }
m_pProperties->m_pThemeProvider = pThemeProvider;
return FWL_Error::Succeeded;
}
@@ -733,24 +729,16 @@ CFX_SizeF CFWL_ListBoxImp::CalcSize(FX_BOOL bAutoSize) {
int32_t iCount = pData->CountItems(m_pInterface);
for (int32_t i = 0; i < iCount; i++) {
IFWL_ListItem* pItem = pData->GetItem(m_pInterface, i);
- CFWL_ThemePart itemPart;
- itemPart.m_pWidget = m_pInterface;
- itemPart.m_iPart = CFWL_Part::ListItem;
- itemPart.m_pData = m_pProperties->m_pDataProvider;
- itemPart.m_bMaximize = i > 0;
- CFX_RectF r;
- m_pProperties->m_pThemeProvider->GetPartRect(&itemPart, r);
if (!bAutoSize) {
CFX_RectF rtItem;
- rtItem.Set(m_rtClient.left, m_rtClient.top + fs.y, r.width, r.height);
+ rtItem.Set(m_rtClient.left, m_rtClient.top + fs.y, 0, 0);
IFWL_ListBoxDP* pBox =
static_cast<IFWL_ListBoxDP*>(m_pProperties->m_pDataProvider);
pBox->SetItemRect(m_pInterface, pItem, rtItem);
}
- fs.y += r.height;
- if (fs.x < r.width) {
- fs.x = r.width;
- fWidth = r.width;
+ if (fs.x < 0) {
+ fs.x = 0;
+ fWidth = 0;
}
}
} else {