summaryrefslogtreecommitdiff
path: root/xfa/fwl/theme/cfwl_pushbuttontp.cpp
diff options
context:
space:
mode:
authordsinclair <dsinclair@chromium.org>2016-10-20 07:19:43 -0700
committerCommit bot <commit-bot@chromium.org>2016-10-20 07:19:43 -0700
commit73895de7dea3737d1a25801001b8efe186c6f5a3 (patch)
tree8754626255699818c34d336fccc75926a5958345 /xfa/fwl/theme/cfwl_pushbuttontp.cpp
parent2a38a02b0492de0576c2e5b5e7d550f969367f9d (diff)
downloadpdfium-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_pushbuttontp.cpp')
-rw-r--r--xfa/fwl/theme/cfwl_pushbuttontp.cpp20
1 files changed, 13 insertions, 7 deletions
diff --git a/xfa/fwl/theme/cfwl_pushbuttontp.cpp b/xfa/fwl/theme/cfwl_pushbuttontp.cpp
index 62b8ffef65..20446da54b 100644
--- a/xfa/fwl/theme/cfwl_pushbuttontp.cpp
+++ b/xfa/fwl/theme/cfwl_pushbuttontp.cpp
@@ -29,7 +29,8 @@ uint32_t CFWL_PushButtonTP::SetThemeID(IFWL_Widget* pWidget,
SetThemeData(FWL_GetThemeColor(dwThemeID));
return CFWL_WidgetTP::SetThemeID(pWidget, dwThemeID);
}
-FX_BOOL CFWL_PushButtonTP::DrawBackground(CFWL_ThemeBackground* pParams) {
+
+void CFWL_PushButtonTP::DrawBackground(CFWL_ThemeBackground* pParams) {
switch (pParams->m_iPart) {
case CFWL_Part::Border: {
DrawBorder(pParams->m_pGraphics, &pParams->m_rtPart, &pParams->m_matrix);
@@ -87,10 +88,11 @@ FX_BOOL CFWL_PushButtonTP::DrawBackground(CFWL_ThemeBackground* pParams) {
pGraphics->RestoreGraphState();
break;
}
- default: {}
+ default:
+ break;
}
- return TRUE;
}
+
void* CFWL_PushButtonTP::GetCapacity(CFWL_ThemePart* pThemePart,
CFWL_WidgetCapacity dwCapacity) {
if (dwCapacity == CFWL_WidgetCapacity::Margin) {
@@ -99,14 +101,17 @@ void* CFWL_PushButtonTP::GetCapacity(CFWL_ThemePart* pThemePart,
}
return CFWL_WidgetTP::GetCapacity(pThemePart, dwCapacity);
}
-FWL_Error CFWL_PushButtonTP::Initialize() {
+
+void CFWL_PushButtonTP::Initialize() {
InitTTO();
- return CFWL_WidgetTP::Initialize();
+ CFWL_WidgetTP::Initialize();
}
-FWL_Error CFWL_PushButtonTP::Finalize() {
+
+void CFWL_PushButtonTP::Finalize() {
FinalizeTTO();
- return CFWL_WidgetTP::Finalize();
+ CFWL_WidgetTP::Finalize();
}
+
void CFWL_PushButtonTP::SetThemeData(uint32_t dwID) {
if (dwID) {
m_pThemeData->clrBorder[0] = ArgbEncode(255, 55, 98, 6);
@@ -152,6 +157,7 @@ void CFWL_PushButtonTP::SetThemeData(uint32_t dwID) {
m_pThemeData->clrFill[4] = ArgbEncode(255, 245, 244, 234);
}
}
+
int32_t CFWL_PushButtonTP::GetColorID(uint32_t dwStates) const {
int32_t color = 0;
if (dwStates & CFWL_PartState_Disabled)