1
0
mirror of https://github.com/lvgl/lvgl.git synced 2025-01-21 06:53:01 +08:00

fix warning in lv_draw_mask_angle_init

This commit is contained in:
Gabor Kiss-Vamosi 2019-11-01 16:39:19 +01:00
parent bdd0acf53a
commit 07317f771e
2 changed files with 5 additions and 4 deletions

View File

@ -234,17 +234,17 @@ void lv_draw_mask_angle_init(lv_draw_mask_param_t * param, lv_coord_t origo_x, l
p->origo.y = origo_y;
p->cb = lv_draw_mask_angle;
if(start_angle > 0 && start_angle < 180) {
if(start_angle >= 0 && start_angle < 180) {
start_side = LV_DRAW_MASK_LINE_SIDE_LEFT;
}
else if(start_angle > 180 && start_angle < 360) {
else if(start_angle >= 180 && start_angle < 360) {
start_side = LV_DRAW_MASK_LINE_SIDE_RIGHT;
}
if(end_angle > 0 && end_angle < 180) {
if(end_angle >= 0 && end_angle < 180) {
end_side = LV_DRAW_MASK_LINE_SIDE_RIGHT;
}
else if(end_angle > 180 && end_angle < 360) {
else if(end_angle >= 180 && end_angle < 360) {
end_side = LV_DRAW_MASK_LINE_SIDE_LEFT;
}

View File

@ -184,6 +184,7 @@ void lv_mbox_set_text(lv_obj_t * mbox, const char * txt)
lv_mbox_ext_t * ext = lv_obj_get_ext_attr(mbox);
lv_label_set_text(ext->text, txt);
lv_label_set_align(ext->text, LV_LABEL_ALIGN_LEFT);
mbox_realign(mbox);
}