Index: xfa/fwl/theme/cfwl_monthcalendartp.cpp |
diff --git a/xfa/fwl/theme/cfwl_monthcalendartp.cpp b/xfa/fwl/theme/cfwl_monthcalendartp.cpp |
index 01d2854c2dc7a3a5cdb795e91a0e73f3df128f69..b554483dcdd232f94c53a0c7c6548af591be806b 100644 |
--- a/xfa/fwl/theme/cfwl_monthcalendartp.cpp |
+++ b/xfa/fwl/theme/cfwl_monthcalendartp.cpp |
@@ -66,9 +66,10 @@ uint32_t CFWL_MonthCalendarTP::SetThemeID(IFWL_Widget* pWidget, |
return CFWL_WidgetTP::SetThemeID(pWidget, dwThemeID); |
} |
-FX_BOOL CFWL_MonthCalendarTP::DrawBackground(CFWL_ThemeBackground* pParams) { |
+void CFWL_MonthCalendarTP::DrawBackground(CFWL_ThemeBackground* pParams) { |
if (!pParams) |
- return FALSE; |
+ return; |
+ |
switch (pParams->m_iPart) { |
case CFWL_Part::Border: { |
DrawBorder(pParams->m_pGraphics, &pParams->m_rtPart, &pParams->m_matrix); |
@@ -119,13 +120,15 @@ FX_BOOL CFWL_MonthCalendarTP::DrawBackground(CFWL_ThemeBackground* pParams) { |
DrawWeekNumSep(pParams, &pParams->m_matrix); |
break; |
} |
- default: {} |
+ default: |
+ break; |
} |
- return TRUE; |
} |
-FX_BOOL CFWL_MonthCalendarTP::DrawText(CFWL_ThemeText* pParams) { |
+ |
+void CFWL_MonthCalendarTP::DrawText(CFWL_ThemeText* pParams) { |
if (!m_pTextOut) |
- return FALSE; |
+ return; |
+ |
if ((pParams->m_iPart == CFWL_Part::DatesIn) && |
!(pParams->m_dwStates & FWL_ITEMSTATE_MCD_Flag) && |
(pParams->m_dwStates & |
@@ -136,8 +139,9 @@ FX_BOOL CFWL_MonthCalendarTP::DrawText(CFWL_ThemeText* pParams) { |
} else { |
m_pTextOut->SetTextColor(0xFF000000); |
} |
- return CFWL_WidgetTP::DrawText(pParams); |
+ CFWL_WidgetTP::DrawText(pParams); |
} |
+ |
void* CFWL_MonthCalendarTP::GetCapacity(CFWL_ThemePart* pThemePart, |
CFWL_WidgetCapacity dwCapacity) { |
FX_BOOL bDefPro = FALSE; |
@@ -336,26 +340,30 @@ void* CFWL_MonthCalendarTP::GetCapacity(CFWL_ThemePart* pThemePart, |
wsResource = L"Today"; |
return &wsResource; |
} |
- default: { bDefPro = TRUE; } |
+ default: |
+ bDefPro = TRUE; |
+ break; |
} |
if (!bDefPro) { |
- if (bDwordVal) { |
+ if (bDwordVal) |
return &m_dwValue; |
- } |
return &m_fValue; |
} |
return CFWL_WidgetTP::GetCapacity(pThemePart, dwCapacity); |
} |
-FWL_Error CFWL_MonthCalendarTP::Initialize() { |
+ |
+void CFWL_MonthCalendarTP::Initialize() { |
InitTTO(); |
- return CFWL_WidgetTP::Initialize(); |
+ CFWL_WidgetTP::Initialize(); |
} |
-FWL_Error CFWL_MonthCalendarTP::Finalize() { |
+ |
+void CFWL_MonthCalendarTP::Finalize() { |
FinalizeTTO(); |
- return CFWL_WidgetTP::Finalize(); |
+ CFWL_WidgetTP::Finalize(); |
} |
-FX_BOOL CFWL_MonthCalendarTP::DrawTotalBK(CFWL_ThemeBackground* pParams, |
- CFX_Matrix* pMatrix) { |
+ |
+void CFWL_MonthCalendarTP::DrawTotalBK(CFWL_ThemeBackground* pParams, |
+ CFX_Matrix* pMatrix) { |
CFX_Path path; |
path.Create(); |
CFX_RectF rtTotal(pParams->m_rtPart); |
@@ -365,10 +373,10 @@ FX_BOOL CFWL_MonthCalendarTP::DrawTotalBK(CFWL_ThemeBackground* pParams, |
pParams->m_pGraphics->SetFillColor(&clrBK); |
pParams->m_pGraphics->FillPath(&path, FXFILL_WINDING, pMatrix); |
pParams->m_pGraphics->RestoreGraphState(); |
- return TRUE; |
} |
-FX_BOOL CFWL_MonthCalendarTP::DrawHeadBk(CFWL_ThemeBackground* pParams, |
- CFX_Matrix* pMatrix) { |
+ |
+void CFWL_MonthCalendarTP::DrawHeadBk(CFWL_ThemeBackground* pParams, |
+ CFX_Matrix* pMatrix) { |
CFX_Path path; |
path.Create(); |
CFX_RectF rtHead = pParams->m_rtPart; |
@@ -378,10 +386,10 @@ FX_BOOL CFWL_MonthCalendarTP::DrawHeadBk(CFWL_ThemeBackground* pParams, |
pParams->m_pGraphics->SetFillColor(&clrHeadBK); |
pParams->m_pGraphics->FillPath(&path, FXFILL_WINDING, pMatrix); |
pParams->m_pGraphics->RestoreGraphState(); |
- return TRUE; |
} |
-FX_BOOL CFWL_MonthCalendarTP::DrawLButton(CFWL_ThemeBackground* pParams, |
- CFX_Matrix* pMatrix) { |
+ |
+void CFWL_MonthCalendarTP::DrawLButton(CFWL_ThemeBackground* pParams, |
+ CFX_Matrix* pMatrix) { |
CFX_Path path; |
path.Create(); |
CFX_RectF rtLBtn; |
@@ -410,10 +418,10 @@ FX_BOOL CFWL_MonthCalendarTP::DrawLButton(CFWL_ThemeBackground* pParams, |
pParams->m_pGraphics->SetStrokeColor(&clrFlag); |
pParams->m_pGraphics->StrokePath(&path, pMatrix); |
pParams->m_pGraphics->RestoreGraphState(); |
- return TRUE; |
} |
-FX_BOOL CFWL_MonthCalendarTP::DrawRButton(CFWL_ThemeBackground* pParams, |
- CFX_Matrix* pMatrix) { |
+ |
+void CFWL_MonthCalendarTP::DrawRButton(CFWL_ThemeBackground* pParams, |
+ CFX_Matrix* pMatrix) { |
CFX_Path path; |
path.Create(); |
CFX_RectF rtRBtn; |
@@ -442,10 +450,10 @@ FX_BOOL CFWL_MonthCalendarTP::DrawRButton(CFWL_ThemeBackground* pParams, |
pParams->m_pGraphics->SetStrokeColor(&clrFlag); |
pParams->m_pGraphics->StrokePath(&path, pMatrix); |
pParams->m_pGraphics->RestoreGraphState(); |
- return TRUE; |
} |
-FX_BOOL CFWL_MonthCalendarTP::DrawHSeperator(CFWL_ThemeBackground* pParams, |
- CFX_Matrix* pMatrix) { |
+ |
+void CFWL_MonthCalendarTP::DrawHSeperator(CFWL_ThemeBackground* pParams, |
+ CFX_Matrix* pMatrix) { |
CFX_Path path; |
path.Create(); |
CFX_RectF rtHSep; |
@@ -457,11 +465,10 @@ FX_BOOL CFWL_MonthCalendarTP::DrawHSeperator(CFWL_ThemeBackground* pParams, |
pParams->m_pGraphics->SetStrokeColor(&clrHSep); |
pParams->m_pGraphics->StrokePath(&path, pMatrix); |
pParams->m_pGraphics->RestoreGraphState(); |
- return TRUE; |
} |
-FX_BOOL CFWL_MonthCalendarTP::DrawWeekNumSep(CFWL_ThemeBackground* pParams, |
- CFX_Matrix* pMatrix) { |
+void CFWL_MonthCalendarTP::DrawWeekNumSep(CFWL_ThemeBackground* pParams, |
+ CFX_Matrix* pMatrix) { |
CFX_Path path; |
path.Create(); |
CFX_RectF rtWeekSep; |
@@ -473,11 +480,10 @@ FX_BOOL CFWL_MonthCalendarTP::DrawWeekNumSep(CFWL_ThemeBackground* pParams, |
pParams->m_pGraphics->SetStrokeColor(&clrHSep); |
pParams->m_pGraphics->StrokePath(&path, pMatrix); |
pParams->m_pGraphics->RestoreGraphState(); |
- return TRUE; |
} |
-FX_BOOL CFWL_MonthCalendarTP::DrawDatesInBK(CFWL_ThemeBackground* pParams, |
- CFX_Matrix* pMatrix) { |
+void CFWL_MonthCalendarTP::DrawDatesInBK(CFWL_ThemeBackground* pParams, |
+ CFX_Matrix* pMatrix) { |
pParams->m_pGraphics->SaveGraphState(); |
if (pParams->m_dwStates & CFWL_PartState_Selected) { |
CFX_Path path; |
@@ -501,11 +507,10 @@ FX_BOOL CFWL_MonthCalendarTP::DrawDatesInBK(CFWL_ThemeBackground* pParams, |
pParams->m_pGraphics->FillPath(&path, FXFILL_WINDING, pMatrix); |
} |
pParams->m_pGraphics->RestoreGraphState(); |
- return FALSE; |
} |
-FX_BOOL CFWL_MonthCalendarTP::DrawDatesInCircle(CFWL_ThemeBackground* pParams, |
- CFX_Matrix* pMatrix) { |
+void CFWL_MonthCalendarTP::DrawDatesInCircle(CFWL_ThemeBackground* pParams, |
+ CFX_Matrix* pMatrix) { |
CFX_Path path; |
path.Create(); |
CFX_RectF rtSelDay; |
@@ -517,11 +522,10 @@ FX_BOOL CFWL_MonthCalendarTP::DrawDatesInCircle(CFWL_ThemeBackground* pParams, |
pParams->m_pGraphics->SetStrokeColor(&clrSelDayBK); |
pParams->m_pGraphics->StrokePath(&path, pMatrix); |
pParams->m_pGraphics->RestoreGraphState(); |
- return TRUE; |
} |
-FX_BOOL CFWL_MonthCalendarTP::DrawTodayCircle(CFWL_ThemeBackground* pParams, |
- CFX_Matrix* pMatrix) { |
+void CFWL_MonthCalendarTP::DrawTodayCircle(CFWL_ThemeBackground* pParams, |
+ CFX_Matrix* pMatrix) { |
CFX_Path path; |
path.Create(); |
CFX_RectF rtTodayCircle; |
@@ -533,7 +537,6 @@ FX_BOOL CFWL_MonthCalendarTP::DrawTodayCircle(CFWL_ThemeBackground* pParams, |
pParams->m_pGraphics->SetStrokeColor(&clrTodayCircle); |
pParams->m_pGraphics->StrokePath(&path, pMatrix); |
pParams->m_pGraphics->RestoreGraphState(); |
- return TRUE; |
} |
FWLTHEME_STATE CFWL_MonthCalendarTP::GetState(uint32_t dwFWLStates) { |