elm: add container api for the two objects

this resolves unimplemented API by just mirroring the calls to different
API calls.

ref T5719

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D7749
This commit is contained in:
Marcel Hollerbach 2019-01-24 10:20:23 +01:00
parent 1763afb391
commit f00ae98a1d
4 changed files with 17 additions and 2 deletions

View File

@ -181,6 +181,14 @@ _efl_ui_box_efl_container_content_count(Eo *obj, Efl_Ui_Box_Data *pd EINA_UNUSED
return bd ? eina_list_count(bd->children) : 0;
}
EOLIAN static Eina_Bool
_efl_ui_box_efl_container_content_remove(Eo *obj EINA_UNUSED, Efl_Ui_Box_Data *pd EINA_UNUSED, Efl_Gfx_Entity *content)
{
ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd, 0);
return evas_object_box_remove(wd->resize_obj, content);
}
EOLIAN static Eina_Bool
_efl_ui_box_efl_pack_pack_clear(Eo *obj, Efl_Ui_Box_Data *pd)
{

View File

@ -18,7 +18,7 @@ class Efl.Ui.Box extends Efl.Ui.Widget implements Efl.Pack_Linear, Efl.Pack_Layo
implements {
Efl.Object.constructor;
Efl.Canvas.Group.group_calculate;
//Efl.Container.content_remove; // TODO
Efl.Container.content_remove;
Efl.Container.content_iterate;
Efl.Container.content_count;
Efl.Ui.Direction.direction { get; set; }

View File

@ -523,6 +523,13 @@ _efl_ui_table_efl_container_content_count(Eo *obj EINA_UNUSED, Efl_Ui_Table_Data
return pd->count;
}
EOLIAN static Eina_Bool
_efl_ui_table_efl_container_content_remove(Eo *obj, Efl_Ui_Table_Data *pd EINA_UNUSED, Efl_Gfx_Entity *content)
{
return efl_pack_unpack(obj, content);
}
EOLIAN static Eina_Iterator *
_efl_ui_table_efl_pack_table_table_contents_get(Eo *obj, Efl_Ui_Table_Data *pd EINA_UNUSED,
int col, int row, Eina_Bool below)

View File

@ -6,7 +6,7 @@ class Efl.Ui.Table extends Efl.Ui.Widget implements Efl.Pack_Table, Efl.Pack_Lay
Efl.Object.constructor;
Efl.Canvas.Group.group_calculate;
Efl.Ui.Widget.theme_apply;
//Efl.Container.content_remove; // TODO
Efl.Container.content_remove;
Efl.Container.content_iterate;
Efl.Container.content_count;
Efl.Ui.Direction.direction { get; set; }