forked from enlightenment/efl
elementary: reduce event trigger during object creation stage in Efl.Ui.CollectionView.
Once the object are created, the CollectionView will do a few modifiction on them before giving this object to the position manager to deal with. Reducing events should slightly improve performance. Reviewed-by: SangHyeon Jade Lee <sh10233.lee@samsung.com> Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de> Differential Revision: https://phab.enlightenment.org/D10686
This commit is contained in:
parent
b9e0d25a4c
commit
d62e2585bb
|
@ -520,6 +520,10 @@ _entity_fetched_cb(Eo *obj, void *data, const Eina_Value v)
|
|||
unsigned int i, len;
|
||||
uint64_t updated_size_start_id = 0, updated_entity_start_id = 0;
|
||||
Eina_Bool updated_size = EINA_FALSE, updated_entity = EINA_FALSE;
|
||||
Evas *e;
|
||||
|
||||
e = evas_object_evas_get(obj);
|
||||
evas_event_freeze(e);
|
||||
|
||||
EINA_VALUE_ARRAY_FOREACH(&v, len, i, child)
|
||||
{
|
||||
|
@ -627,6 +631,9 @@ _entity_fetched_cb(Eo *obj, void *data, const Eina_Value v)
|
|||
}
|
||||
}
|
||||
|
||||
evas_event_thaw(e);
|
||||
evas_event_thaw_eval(e);
|
||||
|
||||
// Currently position manager will flush its entire size cache on update, so only do
|
||||
// it when necessary to improve performance.
|
||||
if (updated_size || request->need_size)
|
||||
|
|
Loading…
Reference in New Issue