diff options
author | dsinclair <dsinclair@chromium.org> | 2016-10-20 07:19:43 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-10-20 07:19:43 -0700 |
commit | 73895de7dea3737d1a25801001b8efe186c6f5a3 (patch) | |
tree | 8754626255699818c34d336fccc75926a5958345 /xfa/fwl/theme/cfwl_checkboxtp.cpp | |
parent | 2a38a02b0492de0576c2e5b5e7d550f969367f9d (diff) | |
download | pdfium-73895de7dea3737d1a25801001b8efe186c6f5a3.tar.xz |
Cleanup unused methods and return values in FWL code.
This CL does an initial pass to remove unused methods and return values
in the FWL code base.
Review-Url: https://chromiumcodereview.appspot.com/2435603003
Diffstat (limited to 'xfa/fwl/theme/cfwl_checkboxtp.cpp')
-rw-r--r-- | xfa/fwl/theme/cfwl_checkboxtp.cpp | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/xfa/fwl/theme/cfwl_checkboxtp.cpp b/xfa/fwl/theme/cfwl_checkboxtp.cpp index b3dffdccf8..da3790a1df 100644 --- a/xfa/fwl/theme/cfwl_checkboxtp.cpp +++ b/xfa/fwl/theme/cfwl_checkboxtp.cpp @@ -45,23 +45,24 @@ uint32_t CFWL_CheckBoxTP::SetThemeID(IFWL_Widget* pWidget, uint32_t dwThemeID) { return CFWL_WidgetTP::SetThemeID(pWidget, dwThemeID); } -FX_BOOL CFWL_CheckBoxTP::DrawText(CFWL_ThemeText* pParams) { +void CFWL_CheckBoxTP::DrawText(CFWL_ThemeText* pParams) { if (!m_pTextOut) - return FALSE; + return; + m_pTextOut->SetTextColor(pParams->m_dwStates & CFWL_PartState_Disabled ? FWLTHEME_CAPACITY_TextDisColor : FWLTHEME_CAPACITY_TextColor); - return CFWL_WidgetTP::DrawText(pParams); + CFWL_WidgetTP::DrawText(pParams); } -FWL_Error CFWL_CheckBoxTP::Initialize() { +void CFWL_CheckBoxTP::Initialize() { InitTTO(); - return CFWL_WidgetTP::Initialize(); + CFWL_WidgetTP::Initialize(); } -FWL_Error CFWL_CheckBoxTP::Finalize() { +void CFWL_CheckBoxTP::Finalize() { FinalizeTTO(); - return CFWL_WidgetTP::Finalize(); + CFWL_WidgetTP::Finalize(); } void CFWL_CheckBoxTP::DrawSignCheck(CFX_Graphics* pGraphics, @@ -322,16 +323,15 @@ void CFWL_CheckBoxTP::InitCheckPath(FX_FLOAT fCheckLen) { } } -FX_BOOL CFWL_CheckBoxTP::DrawBackground(CFWL_ThemeBackground* pParams) { - if (pParams->m_iPart != CFWL_Part::CheckBox) { - return FALSE; - } +void CFWL_CheckBoxTP::DrawBackground(CFWL_ThemeBackground* pParams) { + if (pParams->m_iPart != CFWL_Part::CheckBox) + return; + if ((pParams->m_dwStates & CFWL_PartState_Checked) || (pParams->m_dwStates & CFWL_PartState_Neutral)) { DrawCheckSign(pParams->m_pWidget, pParams->m_pGraphics, pParams->m_rtPart, pParams->m_dwStates, &pParams->m_matrix); } - return FALSE; } void CFWL_CheckBoxTP::DrawCheckSign(IFWL_Widget* pWidget, |