CComponentsButton: remove clear()-methode and initVarButton()

clear() killed all button object with all key values and key properties.
So return values of messeage objects was killed.

initVarButton() contains Oobjekt intits to already existant object.
Bad idea, if we init again or pre init with NULL.

Mode pass was missed.


Origin commit data
------------------
Commit: 0f6e8e1f5d
Author: Thilo Graf <dbt@novatux.de>
Date: 2016-10-05 (Wed, 05 Oct 2016)
This commit is contained in:
2016-10-05 15:23:07 +02:00
parent 93e0dd143c
commit dabba34177

View File

@@ -293,8 +293,7 @@ void CComponentsButton::paint(bool do_save_bg)
void CComponentsButton::enableShadow(int mode, const int& shadow_width, bool force_paint) void CComponentsButton::enableShadow(int mode, const int& shadow_width, bool force_paint)
{ {
clear();
shadow_w = shadow_width; shadow_w = shadow_width;
shadow_force = force_paint; shadow_force = force_paint;
initVarButton(x, y, width, height, cc_btn_capt, cc_btn_icon, cc_parent, cc_item_selected, cc_item_enabled, mode, col_frame, col_body, col_shadow); shadow = mode;
} }