forked from enlightenment/efl
evas: update to new eo_parent_get/set API.
This commit is contained in:
parent
5166bab675
commit
b37494503f
|
@ -318,10 +318,15 @@ _constructor(Eo *eo_obj, void *class_data, va_list *list EINA_UNUSED)
|
|||
{
|
||||
Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJ_CLASS);
|
||||
Evas_Object_Image *o = class_data;
|
||||
Evas *eo_e = evas_object_evas_get(eo_parent_get(eo_obj));
|
||||
Evas *eo_e;
|
||||
Eo *parent;
|
||||
Evas_Colorspace cspace;
|
||||
|
||||
eo_do_super(eo_obj, MY_CLASS, eo_constructor());
|
||||
|
||||
eo_do(eo_obj, eo_parent_get(&parent));
|
||||
eo_e = evas_object_evas_get(parent);
|
||||
|
||||
evas_object_image_init(eo_obj);
|
||||
evas_object_inject(eo_obj, obj, eo_e);
|
||||
|
||||
|
|
|
@ -244,13 +244,18 @@ evas_object_line_init(Evas_Object *eo_obj)
|
|||
static void
|
||||
_constructor(Eo *eo_obj, void *class_data, va_list *list EINA_UNUSED)
|
||||
{
|
||||
Evas_Object_Protected_Data *obj;
|
||||
Evas_Object_Line *o;
|
||||
Eo *parent;
|
||||
|
||||
eo_do_super(eo_obj, MY_CLASS, eo_constructor());
|
||||
|
||||
Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJ_CLASS);
|
||||
obj = eo_data_scope_get(eo_obj, EVAS_OBJ_CLASS);
|
||||
evas_object_line_init(eo_obj);
|
||||
evas_object_inject(eo_obj, obj, evas_object_evas_get(eo_parent_get(eo_obj)));
|
||||
eo_do(eo_obj, eo_parent_get(&parent));
|
||||
evas_object_inject(eo_obj, obj, evas_object_evas_get(parent));
|
||||
|
||||
Evas_Object_Line *o = class_data;
|
||||
o = class_data;
|
||||
/* alloc obj private data */
|
||||
o->cur.x1 = 0;
|
||||
o->cur.y1 = 0;
|
||||
|
|
|
@ -607,7 +607,7 @@ evas_object_del(Evas_Object *eo_obj)
|
|||
|
||||
obj->eo_del_called = EINA_TRUE;
|
||||
|
||||
eo_parent_set(eo_obj, NULL);
|
||||
eo_do(eo_obj, eo_parent_set(NULL));
|
||||
// eo_del(eo_obj);
|
||||
}
|
||||
|
||||
|
|
|
@ -109,11 +109,15 @@ evas_object_polygon_add(Evas *e)
|
|||
static void
|
||||
_constructor(Eo *eo_obj, void *class_data EINA_UNUSED, va_list *list EINA_UNUSED)
|
||||
{
|
||||
Evas_Object_Protected_Data *obj;
|
||||
Eo *parent;
|
||||
|
||||
eo_do_super(eo_obj, MY_CLASS, eo_constructor());
|
||||
|
||||
Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJ_CLASS);
|
||||
obj = eo_data_scope_get(eo_obj, EVAS_OBJ_CLASS);
|
||||
evas_object_polygon_init(eo_obj);
|
||||
evas_object_inject(eo_obj, obj, evas_object_evas_get(eo_parent_get(eo_obj)));
|
||||
eo_do(eo_obj, eo_parent_get(&parent));
|
||||
evas_object_inject(eo_obj, obj, evas_object_evas_get(parent));
|
||||
}
|
||||
|
||||
EAPI void
|
||||
|
|
|
@ -97,11 +97,15 @@ evas_object_rectangle_add(Evas *e)
|
|||
static void
|
||||
_constructor(Eo *eo_obj, void *class_data EINA_UNUSED, va_list *list EINA_UNUSED)
|
||||
{
|
||||
Eo *parent;
|
||||
|
||||
eo_do_super(eo_obj, MY_CLASS, eo_constructor());
|
||||
|
||||
Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJ_CLASS);
|
||||
evas_object_rectangle_init(eo_obj);
|
||||
evas_object_inject(eo_obj, obj, evas_object_evas_get(eo_parent_get(eo_obj)));
|
||||
|
||||
eo_do(eo_obj, eo_parent_get(&parent));
|
||||
evas_object_inject(eo_obj, obj, evas_object_evas_get(parent));
|
||||
}
|
||||
|
||||
/* all nice and private */
|
||||
|
|
|
@ -661,15 +661,19 @@ evas_object_smart_add(Evas *eo_e, Evas_Smart *s)
|
|||
static void
|
||||
_constructor(Eo *eo_obj, void *class_data, va_list *list EINA_UNUSED)
|
||||
{
|
||||
Evas_Object_Protected_Data *obj;
|
||||
Evas_Object_Smart *smart;
|
||||
Eo *parent;
|
||||
|
||||
smart = class_data;
|
||||
smart->object = eo_obj;
|
||||
|
||||
eo_do_super(eo_obj, MY_CLASS, eo_constructor());
|
||||
evas_object_smart_init(eo_obj);
|
||||
Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJ_CLASS);
|
||||
evas_object_inject(eo_obj, obj, evas_object_evas_get(eo_parent_get(eo_obj)));
|
||||
|
||||
obj = eo_data_scope_get(eo_obj, EVAS_OBJ_CLASS);
|
||||
eo_do(eo_obj, eo_parent_get(&parent));
|
||||
evas_object_inject(eo_obj, obj, evas_object_evas_get(parent));
|
||||
eo_do(eo_obj,
|
||||
evas_obj_type_set(MY_CLASS_NAME),
|
||||
evas_obj_smart_add());
|
||||
|
|
|
@ -363,7 +363,10 @@ _constructor(Eo *eo_obj, void *class_data EINA_UNUSED, va_list *list EINA_UNUSED
|
|||
eo_do_super(eo_obj, MY_CLASS, eo_constructor());
|
||||
evas_object_text_init(eo_obj);
|
||||
Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJ_CLASS);
|
||||
evas_object_inject(eo_obj, obj, evas_object_evas_get(eo_parent_get(eo_obj)));
|
||||
Eo *parent;
|
||||
|
||||
eo_do(eo_obj, eo_parent_get(&parent));
|
||||
evas_object_inject(eo_obj, obj, evas_object_evas_get(parent));
|
||||
}
|
||||
|
||||
EAPI void
|
||||
|
|
|
@ -5350,6 +5350,7 @@ _constructor(Eo *eo_obj, void *class_data EINA_UNUSED, va_list *list EINA_UNUSED
|
|||
{
|
||||
Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJ_CLASS);
|
||||
Evas_Object_Textblock *o;
|
||||
Eo *eo_parent;
|
||||
|
||||
eo_do_super(eo_obj, MY_CLASS, eo_constructor());
|
||||
|
||||
|
@ -5362,7 +5363,9 @@ _constructor(Eo *eo_obj, void *class_data EINA_UNUSED, va_list *list EINA_UNUSED
|
|||
o->cursor = calloc(1, sizeof(Evas_Textblock_Cursor));
|
||||
_format_command_init();
|
||||
evas_object_textblock_init(eo_obj);
|
||||
evas_object_inject(eo_obj, obj, evas_object_evas_get(eo_parent_get(eo_obj)));
|
||||
|
||||
eo_do(eo_obj, eo_parent_get(&eo_parent));
|
||||
evas_object_inject(eo_obj, obj, evas_object_evas_get(eo_parent));
|
||||
}
|
||||
|
||||
EAPI Evas_Textblock_Style *
|
||||
|
|
|
@ -1043,11 +1043,15 @@ evas_object_textgrid_add(Evas *e)
|
|||
static void
|
||||
_constructor(Eo *eo_obj, void *class_data EINA_UNUSED, va_list *list EINA_UNUSED)
|
||||
{
|
||||
Eo *eo_parent;
|
||||
|
||||
eo_do_super(eo_obj, MY_CLASS, eo_constructor());
|
||||
|
||||
Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJ_CLASS);
|
||||
evas_object_textgrid_init(eo_obj);
|
||||
evas_object_inject(eo_obj, obj, evas_object_evas_get(eo_parent_get(eo_obj)));
|
||||
|
||||
eo_do(eo_obj, eo_parent_get(&eo_parent));
|
||||
evas_object_inject(eo_obj, obj, evas_object_evas_get(eo_parent));
|
||||
}
|
||||
|
||||
EAPI void
|
||||
|
|
|
@ -31,9 +31,14 @@ static void
|
|||
_constructor(Eo *eo_obj, void *_pd, va_list *list EINA_UNUSED)
|
||||
{
|
||||
Evas_Out_Public_Data *eo_dat = _pd;
|
||||
Eo *eo_parent = eo_parent_get(eo_obj);
|
||||
Evas_Public_Data *e = eo_data_scope_get(eo_parent, EVAS_CLASS);
|
||||
Eo *eo_parent;
|
||||
Evas_Public_Data *e;
|
||||
|
||||
eo_do(eo_obj, eo_parent_get(&eo_parent));
|
||||
e = eo_data_scope_get(eo_parent, EVAS_CLASS);
|
||||
|
||||
eo_do_super(eo_obj, MY_CLASS, eo_constructor());
|
||||
|
||||
if (!e) return;
|
||||
e->outputs = eina_list_append(e->outputs, eo_obj);
|
||||
if (e->engine.func->info) eo_dat->info = e->engine.func->info(eo_parent);
|
||||
|
@ -52,8 +57,11 @@ static void
|
|||
_destructor(Eo *eo_obj, void *_pd, va_list *list EINA_UNUSED)
|
||||
{
|
||||
Evas_Out_Public_Data *eo_dat = _pd;
|
||||
Eo *eo_parent = eo_parent_get(eo_obj);
|
||||
Evas_Public_Data *e = eo_data_scope_get(eo_parent, EVAS_CLASS);
|
||||
Eo *eo_parent;
|
||||
Evas_Public_Data *e;
|
||||
|
||||
eo_do(eo_obj, eo_parent_get(&eo_parent));
|
||||
e = eo_data_scope_get(eo_parent, EVAS_CLASS);
|
||||
// XXX: need to free output and context one they get allocated one day
|
||||
// e->engine.func->context_free(eo_dat->output, eo_dat->context);
|
||||
// e->engine.func->output_free(eo_dat->output);
|
||||
|
|
Loading…
Reference in New Issue