remove dirty callback for deskmirror clients upon creating visual
if another callback triggered the creation of a deskmirror visual while the dirty callback was in place, a second mirror object would be created leading to an orphaned mirror object which retained references to the dm client and eventually resulting in a crash
This commit is contained in:
parent
44b7790cce
commit
ea64775132
|
@ -523,6 +523,7 @@ _comp_object_check(Mirror *m)
|
|||
if ((w < 2) || (h < 2)) return EINA_FALSE;
|
||||
m->mirror = e_comp_object_util_mirror_add(m->comp_object);
|
||||
if (!m->mirror) return EINA_FALSE;
|
||||
evas_object_smart_callback_del(m->comp_object, "dirty", _comp_object_dirty);
|
||||
evas_object_name_set(m->mirror, "m->mirror");
|
||||
_e_deskmirror_mirror_setup(m);
|
||||
return EINA_TRUE;
|
||||
|
@ -580,10 +581,9 @@ _comp_object_configure(Mirror *m, Evas *e EINA_UNUSED, Evas_Object *obj EINA_UNU
|
|||
}
|
||||
|
||||
static void
|
||||
_comp_object_dirty(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
|
||||
_comp_object_dirty(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
|
||||
{
|
||||
if (_comp_object_check(data))
|
||||
evas_object_smart_callback_del(obj, "dirty", _comp_object_dirty);
|
||||
_comp_object_check(data);
|
||||
}
|
||||
|
||||
static Mirror *
|
||||
|
|
Loading…
Reference in New Issue