mirror of
https://github.com/lvgl/lvgl.git
synced 2025-01-28 07:03:00 +08:00
lv_imgbtn: update img_draw calles to the new prototype
This commit is contained in:
parent
75f27bbeae
commit
e76b5d58b5
@ -324,7 +324,7 @@ static lv_design_res_t lv_imgbtn_design(lv_obj_t * imgbtn, const lv_area_t * cli
|
||||
coords.y1 = imgbtn->coords.y1;
|
||||
coords.x2 = coords.x1 + header.w - 1;
|
||||
coords.y2 = coords.y1 + header.h - 1;
|
||||
lv_draw_img(&coords, clip_area, src, style, 0, opa_scale);
|
||||
lv_draw_img(&coords, clip_area, src, style, 0, LV_IMG_ZOOM_NONE, false, opa_scale);
|
||||
}
|
||||
|
||||
src = ext->img_src_right[state];
|
||||
@ -335,7 +335,7 @@ static lv_design_res_t lv_imgbtn_design(lv_obj_t * imgbtn, const lv_area_t * cli
|
||||
coords.y1 = imgbtn->coords.y1;
|
||||
coords.x2 = imgbtn->coords.x2;
|
||||
coords.y2 = imgbtn->coords.y1 + header.h - 1;
|
||||
lv_draw_img(&coords, clip_area, src, style, 0, opa_scale);
|
||||
lv_draw_img(&coords, clip_area, src, style, 0, LV_IMG_ZOOM_NONE, false, opa_scale);
|
||||
}
|
||||
|
||||
src = ext->img_src_mid[state];
|
||||
@ -360,7 +360,7 @@ static lv_design_res_t lv_imgbtn_design(lv_obj_t * imgbtn, const lv_area_t * cli
|
||||
coords.y2 = imgbtn->coords.y1 + header.h - 1;
|
||||
|
||||
for(i = 0; i < obj_w - right_w - left_w; i += header.w) {
|
||||
lv_draw_img(&coords, &clip_center_area, src, style, 0, opa_scale);
|
||||
lv_draw_img(&coords, &clip_center_area, src, style, 0, LV_IMG_ZOOM_NONE, false, opa_scale);
|
||||
coords.x1 = coords.x2 + 1;
|
||||
coords.x2 += header.w;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user