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.
This commit is contained in:
2016-10-05 15:23:07 +02:00
parent ebf2e65b38
commit 0f6e8e1f5d

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)
{
clear();
shadow_w = shadow_width;
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;
}