lv_btn: run rel. action on Select, Inc. Dec.
@@ -188,10 +188,12 @@ bool lv_btn_signal(lv_obj_t * btn, lv_signal_t sign, void * param)
} else if(sign == LV_SIGNAL_INCREASE) {
if(lv_btn_get_tgl(btn) != false) {
lv_btn_set_state(btn, LV_BTN_STATE_TREL);
+ if(ext->rel_action != NULL) valid = ext->rel_action(btn, param);
}
} else if(sign == LV_SIGNAL_DECREASE) {
if(lv_btn_get_tgl(btn) != false) {
lv_btn_set_state(btn, LV_BTN_STATE_REL);
+ if(ext->rel_action != NULL) valid = ext->rel_action(btn, param);
}
} else if(sign == LV_SIGNAL_SELECT) {
if(lv_btn_get_tgl(btn) != false) {
@@ -200,6 +202,7 @@ bool lv_btn_signal(lv_obj_t * btn, lv_signal_t sign, void * param)
else if(state == LV_BTN_STATE_PR) lv_btn_set_state(btn, LV_BTN_STATE_TPR);
else if(state == LV_BTN_STATE_TREL) lv_btn_set_state(btn, LV_BTN_STATE_REL);
else if(state == LV_BTN_STATE_TPR) lv_btn_set_state(btn, LV_BTN_STATE_PR);
+ if(ext->rel_action != NULL) valid = ext->rel_action(btn, param);
}
}
}
