efl/timer: don't attempt instantiating timers until they're finalized

this will fail anyway so don't bother

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D10514
This commit is contained in:
Mike Blumenkrantz 2019-10-24 11:22:17 -04:00
parent a06979b096
commit 15b61bde13
1 changed files with 2 additions and 1 deletions

View File

@ -82,7 +82,8 @@ _check_timer_event_catcher_add(void *data, const Efl_Event *event)
if (array[i].desc == EFL_LOOP_TIMER_EVENT_TIMER_TICK)
{
if (timer->listening++ > 0) return;
_efl_loop_timer_util_instanciate(timer->loop_data, timer);
if (timer->finalized)
_efl_loop_timer_util_instanciate(timer->loop_data, timer);
// No need to walk more than once per array as you can not del
// a partial array
return;