Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(976)

Unified Diff: xfa/fwl/theme/cfwl_pushbuttontp.cpp

Issue 2435603003: Cleanup unused methods and return values in FWL code. (Closed)
Patch Set: Fix typo Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « xfa/fwl/theme/cfwl_pushbuttontp.h ('k') | xfa/fwl/theme/cfwl_scrollbartp.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: xfa/fwl/theme/cfwl_pushbuttontp.cpp
diff --git a/xfa/fwl/theme/cfwl_pushbuttontp.cpp b/xfa/fwl/theme/cfwl_pushbuttontp.cpp
index 62b8ffef6568dad8c7586cb997b53b2d66d3d818..20446da54b5da71b8a86d627c8d779918bf22659 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)
« no previous file with comments | « xfa/fwl/theme/cfwl_pushbuttontp.h ('k') | xfa/fwl/theme/cfwl_scrollbartp.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698