lv_mbox set_btn_styles: bugfix if set styles with still no button created
This commit is contained in:
@@ -238,6 +238,8 @@ void lv_mbox_set_styles_btn(lv_obj_t * mbox, lv_style_t * rel, lv_style_t * pr)
|
||||
|
||||
ext->style_btn_rel = rel;
|
||||
ext->style_btn_pr = pr;
|
||||
|
||||
if(ext->btnh != NULL) {
|
||||
lv_obj_t * btn = lv_obj_get_child(ext->btnh, NULL);
|
||||
|
||||
while(btn != NULL) {
|
||||
@@ -245,6 +247,7 @@ void lv_mbox_set_styles_btn(lv_obj_t * mbox, lv_style_t * rel, lv_style_t * pr)
|
||||
btn = lv_obj_get_child(mbox, btn);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Set close animation duration
|
||||
|
||||
Reference in New Issue
Block a user