summaryrefslogtreecommitdiff
path: root/src/lib/evas/canvas
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/evas/canvas')
-rw-r--r--src/lib/evas/canvas/efl_canvas_vg_object.c4
-rw-r--r--src/lib/evas/canvas/evas_object_box.c4
-rw-r--r--src/lib/evas/canvas/evas_object_grid.c4
-rw-r--r--src/lib/evas/canvas/evas_object_line.c4
-rw-r--r--src/lib/evas/canvas/evas_object_polygon.c4
-rw-r--r--src/lib/evas/canvas/evas_object_rectangle.c4
-rw-r--r--src/lib/evas/canvas/evas_object_smart.c4
-rw-r--r--src/lib/evas/canvas/evas_object_table.c4
-rw-r--r--src/lib/evas/canvas/evas_object_text.c4
-rw-r--r--src/lib/evas/canvas/evas_object_textgrid.c4
10 files changed, 10 insertions, 30 deletions
diff --git a/src/lib/evas/canvas/efl_canvas_vg_object.c b/src/lib/evas/canvas/efl_canvas_vg_object.c
index cfd1898326..f9decd0a21 100644
--- a/src/lib/evas/canvas/efl_canvas_vg_object.c
+++ b/src/lib/evas/canvas/efl_canvas_vg_object.c
@@ -124,9 +124,7 @@ _evas_vg_resize(void *data, const Efl_Event *ev)
124EAPI Evas_Object * 124EAPI Evas_Object *
125evas_object_vg_add(Evas *e) 125evas_object_vg_add(Evas *e)
126{ 126{
127 MAGIC_CHECK(e, Evas, MAGIC_EVAS); 127 EINA_SAFETY_ON_FALSE_RETURN_VAL(efl_isa(e, EVAS_CANVAS_CLASS), NULL);
128 return NULL;
129 MAGIC_CHECK_END();
130 // TODO: Ask backend to return the main Ector_Surface 128 // TODO: Ask backend to return the main Ector_Surface
131 return efl_add(MY_CLASS, evas_find(e), efl_canvas_object_legacy_ctor(efl_added)); 129 return efl_add(MY_CLASS, evas_find(e), efl_canvas_object_legacy_ctor(efl_added));
132} 130}
diff --git a/src/lib/evas/canvas/evas_object_box.c b/src/lib/evas/canvas/evas_object_box.c
index 53e945118d..391f849468 100644
--- a/src/lib/evas/canvas/evas_object_box.c
+++ b/src/lib/evas/canvas/evas_object_box.c
@@ -475,9 +475,7 @@ _evas_box_efl_canvas_group_group_calculate(Eo *o, Evas_Object_Box_Data *priv)
475EAPI Evas_Object * 475EAPI Evas_Object *
476evas_object_box_add(Evas *evas) 476evas_object_box_add(Evas *evas)
477{ 477{
478 MAGIC_CHECK(evas, Evas, MAGIC_EVAS); 478 EINA_SAFETY_ON_FALSE_RETURN_VAL(efl_isa(evas, EVAS_CANVAS_CLASS), NULL);
479 return NULL;
480 MAGIC_CHECK_END();
481 return efl_add(MY_CLASS, evas_find(evas), efl_canvas_object_legacy_ctor(efl_added)); 479 return efl_add(MY_CLASS, evas_find(evas), efl_canvas_object_legacy_ctor(efl_added));
482} 480}
483 481
diff --git a/src/lib/evas/canvas/evas_object_grid.c b/src/lib/evas/canvas/evas_object_grid.c
index b954bf2dce..2ff261961c 100644
--- a/src/lib/evas/canvas/evas_object_grid.c
+++ b/src/lib/evas/canvas/evas_object_grid.c
@@ -273,9 +273,7 @@ _evas_object_grid_smart_set_user(Evas_Smart_Class *sc)
273EAPI Evas_Object * 273EAPI Evas_Object *
274evas_object_grid_add(Evas *evas) 274evas_object_grid_add(Evas *evas)
275{ 275{
276 MAGIC_CHECK(evas, Evas, MAGIC_EVAS); 276 EINA_SAFETY_ON_FALSE_RETURN_VAL(efl_isa(evas, EVAS_CANVAS_CLASS), NULL);
277 return NULL;
278 MAGIC_CHECK_END();
279 return efl_add(MY_CLASS, evas_find(evas), efl_canvas_object_legacy_ctor(efl_added)); 277 return efl_add(MY_CLASS, evas_find(evas), efl_canvas_object_legacy_ctor(efl_added));
280} 278}
281 279
diff --git a/src/lib/evas/canvas/evas_object_line.c b/src/lib/evas/canvas/evas_object_line.c
index e26ea6677b..f506f758cb 100644
--- a/src/lib/evas/canvas/evas_object_line.c
+++ b/src/lib/evas/canvas/evas_object_line.c
@@ -94,9 +94,7 @@ static const Evas_Object_Func object_func =
94EAPI Evas_Object * 94EAPI Evas_Object *
95evas_object_line_add(Evas *e) 95evas_object_line_add(Evas *e)
96{ 96{
97 MAGIC_CHECK(e, Evas, MAGIC_EVAS); 97 EINA_SAFETY_ON_FALSE_RETURN_VAL(efl_isa(e, EVAS_CANVAS_CLASS), NULL);
98 return NULL;
99 MAGIC_CHECK_END();
100 return efl_add(EVAS_LINE_CLASS, evas_find(e), efl_canvas_object_legacy_ctor(efl_added)); 98 return efl_add(EVAS_LINE_CLASS, evas_find(e), efl_canvas_object_legacy_ctor(efl_added));
101} 99}
102 100
diff --git a/src/lib/evas/canvas/evas_object_polygon.c b/src/lib/evas/canvas/evas_object_polygon.c
index 90c05dda42..8f65277be7 100644
--- a/src/lib/evas/canvas/evas_object_polygon.c
+++ b/src/lib/evas/canvas/evas_object_polygon.c
@@ -84,9 +84,7 @@ static const Evas_Object_Func object_func =
84EAPI Evas_Object * 84EAPI Evas_Object *
85evas_object_polygon_add(Evas *e) 85evas_object_polygon_add(Evas *e)
86{ 86{
87 MAGIC_CHECK(e, Evas, MAGIC_EVAS); 87 EINA_SAFETY_ON_FALSE_RETURN_VAL(efl_isa(e, EVAS_CANVAS_CLASS), NULL);
88 return NULL;
89 MAGIC_CHECK_END();
90 return efl_add(MY_CLASS, evas_find(e), efl_canvas_object_legacy_ctor(efl_added)); 88 return efl_add(MY_CLASS, evas_find(e), efl_canvas_object_legacy_ctor(efl_added));
91} 89}
92 90
diff --git a/src/lib/evas/canvas/evas_object_rectangle.c b/src/lib/evas/canvas/evas_object_rectangle.c
index c5d8253aee..5a8baddd3b 100644
--- a/src/lib/evas/canvas/evas_object_rectangle.c
+++ b/src/lib/evas/canvas/evas_object_rectangle.c
@@ -92,9 +92,7 @@ static const Evas_Object_Func object_func =
92EAPI Evas_Object * 92EAPI Evas_Object *
93evas_object_rectangle_add(Evas *e) 93evas_object_rectangle_add(Evas *e)
94{ 94{
95 MAGIC_CHECK(e, Evas, MAGIC_EVAS); 95 EINA_SAFETY_ON_FALSE_RETURN_VAL(efl_isa(e, EVAS_CANVAS_CLASS), NULL);
96 return NULL;
97 MAGIC_CHECK_END();
98 return efl_add(EFL_CANVAS_RECTANGLE_CLASS, evas_find(e), efl_canvas_object_legacy_ctor(efl_added)); 96 return efl_add(EFL_CANVAS_RECTANGLE_CLASS, evas_find(e), efl_canvas_object_legacy_ctor(efl_added));
99} 97}
100 98
diff --git a/src/lib/evas/canvas/evas_object_smart.c b/src/lib/evas/canvas/evas_object_smart.c
index 6223792cae..7feea17d38 100644
--- a/src/lib/evas/canvas/evas_object_smart.c
+++ b/src/lib/evas/canvas/evas_object_smart.c
@@ -675,9 +675,7 @@ evas_object_smart_add(Evas *eo_e, Evas_Smart *s)
675{ 675{
676 Evas_Object *eo_obj; 676 Evas_Object *eo_obj;
677 677
678 MAGIC_CHECK(eo_e, Evas, MAGIC_EVAS); 678 EINA_SAFETY_ON_FALSE_RETURN_VAL(efl_isa(eo_e, EVAS_CANVAS_CLASS), NULL);
679 return NULL;
680 MAGIC_CHECK_END();
681 eo_obj = efl_add(EFL_CANVAS_GROUP_CLASS, evas_find(eo_e), efl_canvas_object_legacy_ctor(efl_added)); 679 eo_obj = efl_add(EFL_CANVAS_GROUP_CLASS, evas_find(eo_e), efl_canvas_object_legacy_ctor(efl_added));
682 evas_object_smart_attach(eo_obj, s); 680 evas_object_smart_attach(eo_obj, s);
683 return eo_obj; 681 return eo_obj;
diff --git a/src/lib/evas/canvas/evas_object_table.c b/src/lib/evas/canvas/evas_object_table.c
index 97ba008266..3b8837f6cc 100644
--- a/src/lib/evas/canvas/evas_object_table.c
+++ b/src/lib/evas/canvas/evas_object_table.c
@@ -979,9 +979,7 @@ _evas_table_efl_canvas_group_group_calculate(Eo *o, Evas_Table_Data *priv)
979EAPI Evas_Object * 979EAPI Evas_Object *
980evas_object_table_add(Evas *evas) 980evas_object_table_add(Evas *evas)
981{ 981{
982 MAGIC_CHECK(evas, Evas, MAGIC_EVAS); 982 EINA_SAFETY_ON_FALSE_RETURN_VAL(efl_isa(evas, EVAS_CANVAS_CLASS), NULL);
983 return NULL;
984 MAGIC_CHECK_END();
985 return efl_add(MY_CLASS, evas_find(evas), efl_canvas_object_legacy_ctor(efl_added)); 983 return efl_add(MY_CLASS, evas_find(evas), efl_canvas_object_legacy_ctor(efl_added));
986} 984}
987 985
diff --git a/src/lib/evas/canvas/evas_object_text.c b/src/lib/evas/canvas/evas_object_text.c
index 315b7ce015..5aae419759 100644
--- a/src/lib/evas/canvas/evas_object_text.c
+++ b/src/lib/evas/canvas/evas_object_text.c
@@ -376,9 +376,7 @@ _evas_object_text_vert_advance_get(const Evas_Object *obj EINA_UNUSED,
376EAPI Evas_Object * 376EAPI Evas_Object *
377evas_object_text_add(Evas *e) 377evas_object_text_add(Evas *e)
378{ 378{
379 MAGIC_CHECK(e, Evas, MAGIC_EVAS); 379 EINA_SAFETY_ON_FALSE_RETURN_VAL(efl_isa(e, EVAS_CANVAS_CLASS), NULL);
380 return NULL;
381 MAGIC_CHECK_END();
382 return efl_add(EVAS_TEXT_CLASS, evas_find(e), efl_canvas_object_legacy_ctor(efl_added)); 380 return efl_add(EVAS_TEXT_CLASS, evas_find(e), efl_canvas_object_legacy_ctor(efl_added));
383} 381}
384 382
diff --git a/src/lib/evas/canvas/evas_object_textgrid.c b/src/lib/evas/canvas/evas_object_textgrid.c
index d817d94e46..8c5cd63fa1 100644
--- a/src/lib/evas/canvas/evas_object_textgrid.c
+++ b/src/lib/evas/canvas/evas_object_textgrid.c
@@ -899,9 +899,7 @@ _evas_textgrid_efl_gfx_entity_scale_set(Evas_Object *eo_obj, Evas_Textgrid_Data
899EAPI Evas_Object * 899EAPI Evas_Object *
900evas_object_textgrid_add(Evas *e) 900evas_object_textgrid_add(Evas *e)
901{ 901{
902 MAGIC_CHECK(e, Evas, MAGIC_EVAS); 902 EINA_SAFETY_ON_FALSE_RETURN_VAL(efl_isa(e, EVAS_CANVAS_CLASS), NULL);
903 return NULL;
904 MAGIC_CHECK_END();
905 return efl_add(EVAS_TEXTGRID_CLASS, evas_find(e), efl_canvas_object_legacy_ctor(efl_added)); 903 return efl_add(EVAS_TEXTGRID_CLASS, evas_find(e), efl_canvas_object_legacy_ctor(efl_added));
906} 904}
907 905