Adiciona tipo imagem (core) + tinyblocks-ppm e previa de imagem no balao
This commit is contained in:
1 parent
f794d8b8c7
commit
959a4027c3
16 files changed
+721
-10
No files matched your search
@@ -42,6 +42,8 @@ TinyBlocks_Value tb_value_clone(TinyBlocks_Value v)
|
||||
tb_vector_data_retain(v.as.vector);
|
||||
if (v.kind == TB_VALUE_JSON && v.as.json)
|
||||
tb_json_retain(v.as.json);
|
||||
if (v.kind == TB_VALUE_IMAGE && v.as.image)
|
||||
tb_image_retain(v.as.image);
|
||||
return v;
|
||||
}
|
||||
|
||||
@@ -57,6 +59,9 @@ void tb_value_free(TinyBlocks_Value* v)
|
||||
} else if (v->kind == TB_VALUE_JSON) {
|
||||
tb_json_release(v->as.json);
|
||||
v->as.json = NULL;
|
||||
} else if (v->kind == TB_VALUE_IMAGE) {
|
||||
tb_image_release(v->as.image);
|
||||
v->as.image = NULL;
|
||||
}
|
||||
v->kind = TB_VALUE_NONE;
|
||||
}
|
||||
Reference in new issue
Block a user