mirror of
https://github.com/lvgl/lvgl.git
synced 2025-01-28 07:03:00 +08:00
fix lv_chart_set_point_count() bug (#2270)
Co-authored-by: guowei15 <guowei15@xiaomi.com>
This commit is contained in:
parent
5b9329fd5d
commit
f1cbf49718
@ -109,7 +109,9 @@ void lv_chart_set_point_count(lv_obj_t * obj, uint16_t cnt)
|
||||
if(cnt < 1) cnt = 1;
|
||||
|
||||
_LV_LL_READ_BACK(&chart->series_ll, ser) {
|
||||
if(!ser->x_ext_buf_assigned) new_points_alloc(obj, ser, cnt, &ser->x_points);
|
||||
if(chart->type == LV_CHART_TYPE_SCATTER) {
|
||||
if(!ser->x_ext_buf_assigned) new_points_alloc(obj, ser, cnt, &ser->x_points);
|
||||
}
|
||||
if(!ser->y_ext_buf_assigned) new_points_alloc(obj, ser, cnt, &ser->y_points);
|
||||
ser->start_point = 0;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user