forked from enlightenment/efl
edje_calc: Add unload file for already loaded vector lottie file.
Summary: Users can use multiple jsons per description in one part in edc. At that time, multiple files are loaded, if a file is already loaded, it must be unloaded. Test Plan: edje_cc -beta -id ./ json_edc.edc make ./test Push Change button -> shutdown application {F3882716} Reviewers: Hermet, herb, kimcinoo Reviewed By: Hermet Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D11820
This commit is contained in:
parent
d76a2a01f1
commit
0033f2b8ed
|
@ -3243,6 +3243,7 @@ _edje_vector_load_lottie(Edje *ed, Edje_Real_Part *ep, const char *key)
|
||||||
{
|
{
|
||||||
lottie_data[lottie_data_len] = '\0';
|
lottie_data[lottie_data_len] = '\0';
|
||||||
file = eina_file_virtualize(NULL, lottie_data, lottie_data_len + 1, EINA_FALSE);
|
file = eina_file_virtualize(NULL, lottie_data, lottie_data_len + 1, EINA_FALSE);
|
||||||
|
if (efl_file_loaded_get(ep->object)) efl_file_unload(ep->object);
|
||||||
efl_file_simple_mmap_load(ep->object, file, NULL);
|
efl_file_simple_mmap_load(ep->object, file, NULL);
|
||||||
|
|
||||||
if (ep->typedata.vector->lottie_virtual_file)
|
if (ep->typedata.vector->lottie_virtual_file)
|
||||||
|
|
Loading…
Reference in New Issue