improve vgcanvas_asset_manager

This commit is contained in:
lixianjing 2021-11-05 18:24:30 +08:00
parent 111024e95b
commit 2de5100464
2 changed files with 4 additions and 1 deletions

View File

@ -3,6 +3,7 @@
2021/11/05
* 增加了nanovg获取当前裁剪区的函数和增加矩形是否在裁剪区的函数以及统一修改相关判断是否在裁剪区的代码感谢智明提供补丁
* 修复在裁剪区下和高分屏情况下字体无法裁剪的情况(感谢智明提供补丁)。
* 修复离线画布和切换主题同时释放导致位图数据 多次释放的问题(感谢智明提供补丁)。
2021/11/03
* 增加 fs\_foreach\_file

View File

@ -308,7 +308,9 @@ static ret_t vgcanvas_asset_manager_remove_image_impl(vgcanvas_asset_manager_t*
int32_t index = darray_find_index(&(image->image_ctx_list), tk_pointer_from_int(vg_data->vg_id));
darray_remove_index(&(image->image_ctx_list), index);
if (image->image_ctx_list.size == 0) {
darray_remove(&(vgcanvas_asset_manager->image_list), image);
bitmap_t img;
img.buffer = buffer;
image_manager_unload_bitmap(image_manager(), &img);
}
}
return RET_OK;