chore(image): reduce warning level for src being NULL (#8394)

Signed-off-by: pengyiqiang <pengyiqiang@xiaomi.com>
Co-authored-by: pengyiqiang <pengyiqiang@xiaomi.com>
This commit is contained in:
VIFEX
2025-06-10 18:18:28 +08:00
committed by GitHub
parent afd44dfda9
commit 4fa57ef01e
+5 -4
View File
@@ -820,6 +820,11 @@ static void draw_image(lv_event_t * e)
if(img->h == 0 || img->w == 0) return;
if(img->scale_x == 0 || img->scale_y == 0) return;
if(img->src == NULL) {
/*Do not need to draw image when src is NULL*/
LV_LOG_TRACE("image source is NULL");
return;
}
lv_layer_t * layer = lv_event_get_layer(e);
@@ -905,10 +910,6 @@ static void draw_image(lv_event_t * e)
}
lv_draw_label(layer, &label_dsc, coords);
}
else if(img->src == NULL) {
/*Do not need to draw image when src is NULL*/
LV_LOG_WARN("image source is NULL");
}
else {
/*Trigger the error handler of image draw*/
LV_LOG_WARN("image source type is unknown");