summaryrefslogtreecommitdiff
path: root/xfa/fwl/core/ifwl_monthcalendar.cpp
diff options
context:
space:
mode:
authordsinclair <dsinclair@chromium.org>2016-11-10 09:40:14 -0800
committerCommit bot <commit-bot@chromium.org>2016-11-10 09:40:14 -0800
commit98329fe75b9c3e5422344a37d787fb22c89c2ca2 (patch)
treea1e7f3d35bc97695b074756ab7ef531c17c6262d /xfa/fwl/core/ifwl_monthcalendar.cpp
parent50feafc7f367a87b7e4e689421eb7ae1484660d9 (diff)
downloadpdfium-98329fe75b9c3e5422344a37d787fb22c89c2ca2.tar.xz
Cleanup IFWL_Widget visibility and virtual parameters
This Cl cleans up the IFWL_Widget class including: * Making members and methods private where possible * Removing virtual methods that are never overridden * Removing methods that do nothing * Removing unchecked FWL_Error return codes Review-Url: https://codereview.chromium.org/2488953003
Diffstat (limited to 'xfa/fwl/core/ifwl_monthcalendar.cpp')
-rw-r--r--xfa/fwl/core/ifwl_monthcalendar.cpp15
1 files changed, 6 insertions, 9 deletions
diff --git a/xfa/fwl/core/ifwl_monthcalendar.cpp b/xfa/fwl/core/ifwl_monthcalendar.cpp
index 28d529787d..7351e7e29a 100644
--- a/xfa/fwl/core/ifwl_monthcalendar.cpp
+++ b/xfa/fwl/core/ifwl_monthcalendar.cpp
@@ -157,7 +157,7 @@ FWL_Type IFWL_MonthCalendar::GetClassID() const {
return FWL_Type::MonthCalendar;
}
-FWL_Error IFWL_MonthCalendar::GetWidgetRect(CFX_RectF& rect, bool bAutoSize) {
+void IFWL_MonthCalendar::GetWidgetRect(CFX_RectF& rect, bool bAutoSize) {
if (bAutoSize) {
CFX_SizeF fs = CalcSize(true);
rect.Set(0, 0, fs.x, fs.y);
@@ -165,12 +165,11 @@ FWL_Error IFWL_MonthCalendar::GetWidgetRect(CFX_RectF& rect, bool bAutoSize) {
} else {
rect = m_pProperties->m_rtWidget;
}
- return FWL_Error::Succeeded;
}
-FWL_Error IFWL_MonthCalendar::Update() {
+void IFWL_MonthCalendar::Update() {
if (IsLocked()) {
- return FWL_Error::Indefinite;
+ return;
}
if (!m_pProperties->m_pThemeProvider) {
m_pProperties->m_pThemeProvider = GetAvailableTheme();
@@ -182,13 +181,12 @@ FWL_Error IFWL_MonthCalendar::Update() {
ClearDateItem();
ReSetDateItem();
LayOut();
- return FWL_Error::Succeeded;
}
-FWL_Error IFWL_MonthCalendar::DrawWidget(CFX_Graphics* pGraphics,
- const CFX_Matrix* pMatrix) {
+void IFWL_MonthCalendar::DrawWidget(CFX_Graphics* pGraphics,
+ const CFX_Matrix* pMatrix) {
if (!pGraphics)
- return FWL_Error::Indefinite;
+ return;
if (!m_pProperties->m_pThemeProvider) {
m_pProperties->m_pThemeProvider = GetAvailableTheme();
}
@@ -215,7 +213,6 @@ FWL_Error IFWL_MonthCalendar::DrawWidget(CFX_Graphics* pGraphics,
DrawWeekNumberSep(pGraphics, pTheme, pMatrix);
DrawWeekNumber(pGraphics, pTheme, pMatrix);
}
- return FWL_Error::Succeeded;
}
int32_t IFWL_MonthCalendar::CountSelect() {