forked from enlightenment/efl
efl_access: add free functions to efl_acces_object types
there are owned types in eolian, therefore a free function should be defined on the types that are owned. Reviewed-by: Lukasz Stanislawski <l.stanislaws@samsung.com> Differential Revision: https://phab.enlightenment.org/D7711
This commit is contained in:
parent
256367384a
commit
062bc5f25c
|
@ -383,14 +383,20 @@ _efl_access_object_relations_get(const Eo *obj EINA_UNUSED, Efl_Access_Object_Da
|
||||||
return eina_list_iterator_new(pd->relations);
|
return eina_list_iterator_new(pd->relations);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
EAPI void
|
||||||
|
efl_access_attribute_free(Efl_Access_Attribute *attr)
|
||||||
|
{
|
||||||
|
eina_stringshare_del(attr->key);
|
||||||
|
eina_stringshare_del(attr->value);
|
||||||
|
free(attr);
|
||||||
|
}
|
||||||
|
|
||||||
EAPI void efl_access_attributes_list_free(Eina_List *list)
|
EAPI void efl_access_attributes_list_free(Eina_List *list)
|
||||||
{
|
{
|
||||||
Efl_Access_Attribute *attr;
|
Efl_Access_Attribute *attr;
|
||||||
EINA_LIST_FREE(list, attr)
|
EINA_LIST_FREE(list, attr)
|
||||||
{
|
{
|
||||||
eina_stringshare_del(attr->key);
|
efl_access_attribute_free(attr);
|
||||||
eina_stringshare_del(attr->value);
|
|
||||||
free(attr);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -225,7 +225,7 @@ struct Efl.Access.Event.Children_Changed.Data
|
||||||
child: Efl.Object; [[Child object]]
|
child: Efl.Object; [[Child object]]
|
||||||
}
|
}
|
||||||
|
|
||||||
struct Efl.Access.Attribute
|
struct @free(efl_access_attribute_free) Efl.Access.Attribute
|
||||||
{
|
{
|
||||||
[[Accessibility Attribute]]
|
[[Accessibility Attribute]]
|
||||||
key: string; [[Attribute key]]
|
key: string; [[Attribute key]]
|
||||||
|
|
|
@ -30,6 +30,12 @@
|
||||||
*/
|
*/
|
||||||
EAPI void efl_access_attributes_list_free(Eina_List *list);
|
EAPI void efl_access_attributes_list_free(Eina_List *list);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Free the Efl_Access_Attribute type
|
||||||
|
*/
|
||||||
|
EAPI void
|
||||||
|
efl_access_attribute_free(Efl_Access_Attribute *attr);
|
||||||
|
|
||||||
#ifdef EFL_EO_API_SUPPORT
|
#ifdef EFL_EO_API_SUPPORT
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -20,7 +20,7 @@ enum Efl.Access.Text_Clip_Type
|
||||||
both [[Both clip types]]
|
both [[Both clip types]]
|
||||||
}
|
}
|
||||||
|
|
||||||
struct Efl.Access.Text_Attribute
|
struct @free(elm_atspi_text_text_attribute_free) Efl.Access.Text_Attribute
|
||||||
{
|
{
|
||||||
[[Text attribute]]
|
[[Text attribute]]
|
||||||
name: string; [[Text attribute name]]
|
name: string; [[Text attribute name]]
|
||||||
|
|
Loading…
Reference in New Issue