summaryrefslogtreecommitdiff
path: root/src/lib/elementary/elc_ctxpopup.c
diff options
context:
space:
mode:
authorTom Hacohen <tom@stosb.com>2016-08-15 14:44:41 +0100
committerTom Hacohen <tom@stosb.com>2016-08-15 15:07:42 +0100
commite65aae994e72c1d3f8ac6b5360d3772f177b77ef (patch)
tree7ecaf136e45470635889191aded2b47057720a98 /src/lib/elementary/elc_ctxpopup.c
parent35abb3c34d10a4826c98055fb85ecf93915e5ea8 (diff)
Eo: Finish the renaming of Eo to the EFL.
This renames all the rest of the API to the EFL namespace except for Eo_Event that will follow soon. Obviously breaks both API and ABI.
Diffstat (limited to 'src/lib/elementary/elc_ctxpopup.c')
-rw-r--r--src/lib/elementary/elc_ctxpopup.c46
1 files changed, 23 insertions, 23 deletions
diff --git a/src/lib/elementary/elc_ctxpopup.c b/src/lib/elementary/elc_ctxpopup.c
index 4955270..6fcebde 100644
--- a/src/lib/elementary/elc_ctxpopup.c
+++ b/src/lib/elementary/elc_ctxpopup.c
@@ -60,7 +60,7 @@ _elm_ctxpopup_elm_widget_translate(Eo *obj, Elm_Ctxpopup_Data *sd)
60 EINA_LIST_FOREACH(sd->items, l, it) 60 EINA_LIST_FOREACH(sd->items, l, it)
61 elm_wdg_item_translate(it); 61 elm_wdg_item_translate(it);
62 62
63 elm_obj_widget_translate(eo_super(obj, MY_CLASS)); 63 elm_obj_widget_translate(efl_super(obj, MY_CLASS));
64 64
65 return EINA_TRUE; 65 return EINA_TRUE;
66} 66}
@@ -228,7 +228,7 @@ _base_geometry_calc(Evas_Object *obj,
228 evas_object_geometry_get 228 evas_object_geometry_get
229 (sd->parent, &hover_area.x, &hover_area.y, &hover_area.w, 229 (sd->parent, &hover_area.x, &hover_area.y, &hover_area.w,
230 &hover_area.h); 230 &hover_area.h);
231 if (sd->parent && eo_isa(sd->parent, EFL_UI_WIN_CLASS)) 231 if (sd->parent && efl_isa(sd->parent, EFL_UI_WIN_CLASS))
232 hover_area.x = hover_area.y = 0; 232 hover_area.x = hover_area.y = 0;
233 233
234 evas_object_geometry_get(obj, &pos.x, &pos.y, NULL, NULL); 234 evas_object_geometry_get(obj, &pos.x, &pos.y, NULL, NULL);
@@ -750,7 +750,7 @@ _elm_ctxpopup_elm_widget_theme_apply(Eo *obj, Elm_Ctxpopup_Data *sd)
750{ 750{
751 Elm_Theme_Apply int_ret = ELM_THEME_APPLY_FAILED; 751 Elm_Theme_Apply int_ret = ELM_THEME_APPLY_FAILED;
752 752
753 int_ret = elm_obj_widget_theme_apply(eo_super(obj, MY_CLASS)); 753 int_ret = elm_obj_widget_theme_apply(efl_super(obj, MY_CLASS));
754 if (!int_ret) return ELM_THEME_APPLY_FAILED; 754 if (!int_ret) return ELM_THEME_APPLY_FAILED;
755 755
756 elm_widget_theme_object_set 756 elm_widget_theme_object_set
@@ -780,7 +780,7 @@ _elm_ctxpopup_content_set(Eo *obj, Elm_Ctxpopup_Data *sd, const char *part, Evas
780{ 780{
781 if ((part) && (strcmp(part, "default"))) 781 if ((part) && (strcmp(part, "default")))
782 { 782 {
783 return efl_content_set(efl_part(eo_super(obj, MY_CLASS), part), content); 783 return efl_content_set(efl_part(efl_super(obj, MY_CLASS), part), content);
784 } 784 }
785 785
786 if (!content) return EINA_FALSE; 786 if (!content) return EINA_FALSE;
@@ -810,7 +810,7 @@ static Evas_Object*
810_elm_ctxpopup_content_get(Eo *obj, Elm_Ctxpopup_Data *sd, const char *part) 810_elm_ctxpopup_content_get(Eo *obj, Elm_Ctxpopup_Data *sd, const char *part)
811{ 811{
812 if ((part) && (strcmp(part, "default"))) 812 if ((part) && (strcmp(part, "default")))
813 return efl_content_get(efl_part(eo_super(obj, MY_CLASS), part)); 813 return efl_content_get(efl_part(efl_super(obj, MY_CLASS), part));
814 814
815 return sd->content; 815 return sd->content;
816} 816}
@@ -821,7 +821,7 @@ _elm_ctxpopup_content_unset(Eo *obj, Elm_Ctxpopup_Data *sd, const char *part)
821 Evas_Object *content = NULL; 821 Evas_Object *content = NULL;
822 822
823 if ((part) && (strcmp(part, "default"))) 823 if ((part) && (strcmp(part, "default")))
824 return efl_content_unset(efl_part(eo_super(obj, MY_CLASS), part)); 824 return efl_content_unset(efl_part(efl_super(obj, MY_CLASS), part));
825 825
826 content = sd->content; 826 content = sd->content;
827 if (!content) return content; 827 if (!content) return content;
@@ -1049,7 +1049,7 @@ _elm_ctxpopup_item_efl_object_destructor(Eo *eo_ctxpopup_it,
1049 list = elm_object_item_widget_get(ctxpopup_it->list_item); 1049 list = elm_object_item_widget_get(ctxpopup_it->list_item);
1050 1050
1051 if (ctxpopup_it->list_item) 1051 if (ctxpopup_it->list_item)
1052 eo_unref(ctxpopup_it->list_item); 1052 efl_unref(ctxpopup_it->list_item);
1053 sd->items = eina_list_remove(sd->items, eo_ctxpopup_it); 1053 sd->items = eina_list_remove(sd->items, eo_ctxpopup_it);
1054 if (list && eina_list_count(elm_list_items_get(list)) < 2) 1054 if (list && eina_list_count(elm_list_items_get(list)) < 2)
1055 { 1055 {
@@ -1060,7 +1060,7 @@ _elm_ctxpopup_item_efl_object_destructor(Eo *eo_ctxpopup_it,
1060 if (sd->list_visible) elm_layout_sizing_eval(WIDGET(ctxpopup_it)); 1060 if (sd->list_visible) elm_layout_sizing_eval(WIDGET(ctxpopup_it));
1061 } 1061 }
1062 1062
1063 efl_destructor(eo_super(eo_ctxpopup_it, ELM_CTXPOPUP_ITEM_CLASS)); 1063 efl_destructor(efl_super(eo_ctxpopup_it, ELM_CTXPOPUP_ITEM_CLASS));
1064} 1064}
1065 1065
1066EOLIAN static Eina_Bool 1066EOLIAN static Eina_Bool
@@ -1068,7 +1068,7 @@ _elm_ctxpopup_elm_widget_disable(Eo *obj, Elm_Ctxpopup_Data *sd)
1068{ 1068{
1069 Eina_Bool int_ret = EINA_FALSE; 1069 Eina_Bool int_ret = EINA_FALSE;
1070 1070
1071 int_ret = elm_obj_widget_disable(eo_super(obj, MY_CLASS)); 1071 int_ret = elm_obj_widget_disable(efl_super(obj, MY_CLASS));
1072 if (!int_ret) return EINA_FALSE; 1072 if (!int_ret) return EINA_FALSE;
1073 if (sd->list) 1073 if (sd->list)
1074 elm_object_disabled_set(sd->list, elm_widget_disabled_get(obj)); 1074 elm_object_disabled_set(sd->list, elm_widget_disabled_get(obj));
@@ -1083,7 +1083,7 @@ _elm_ctxpopup_efl_canvas_group_group_add(Eo *obj, Elm_Ctxpopup_Data *priv)
1083{ 1083{
1084 ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd); 1084 ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd);
1085 1085
1086 efl_canvas_group_add(eo_super(obj, MY_CLASS)); 1086 efl_canvas_group_add(efl_super(obj, MY_CLASS));
1087 elm_widget_sub_object_parent_add(obj); 1087 elm_widget_sub_object_parent_add(obj);
1088 1088
1089 if (!elm_layout_theme_set 1089 if (!elm_layout_theme_set
@@ -1124,7 +1124,7 @@ _elm_ctxpopup_efl_canvas_group_group_add(Eo *obj, Elm_Ctxpopup_Data *priv)
1124 (priv->box, EVAS_CALLBACK_RESIZE, _on_content_resized, obj); 1124 (priv->box, EVAS_CALLBACK_RESIZE, _on_content_resized, obj);
1125 1125
1126 /* box will be our content placeholder, thus the parent's version call */ 1126 /* box will be our content placeholder, thus the parent's version call */
1127 efl_content_set(efl_part(eo_super(obj, MY_CLASS), "elm.swallow.content"), priv->box); 1127 efl_content_set(efl_part(efl_super(obj, MY_CLASS), "elm.swallow.content"), priv->box);
1128 1128
1129 evas_object_event_callback_add(obj, EVAS_CALLBACK_SHOW, _on_show, NULL); 1129 evas_object_event_callback_add(obj, EVAS_CALLBACK_SHOW, _on_show, NULL);
1130 evas_object_event_callback_add(obj, EVAS_CALLBACK_HIDE, _on_hide, NULL); 1130 evas_object_event_callback_add(obj, EVAS_CALLBACK_HIDE, _on_hide, NULL);
@@ -1149,7 +1149,7 @@ _elm_ctxpopup_efl_canvas_group_group_del(Eo *obj, Elm_Ctxpopup_Data *sd)
1149 EINA_LIST_FREE(sd->items, it) 1149 EINA_LIST_FREE(sd->items, it)
1150 efl_del(it); 1150 efl_del(it);
1151 1151
1152 efl_canvas_group_del(eo_super(obj, MY_CLASS)); 1152 efl_canvas_group_del(efl_super(obj, MY_CLASS));
1153} 1153}
1154 1154
1155EOLIAN static void 1155EOLIAN static void
@@ -1163,7 +1163,7 @@ EAPI Evas_Object *
1163elm_ctxpopup_add(Evas_Object *parent) 1163elm_ctxpopup_add(Evas_Object *parent)
1164{ 1164{
1165 EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL); 1165 EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
1166 Evas_Object *obj = eo_add(MY_CLASS, parent); 1166 Evas_Object *obj = efl_add(MY_CLASS, parent);
1167 1167
1168 /* access: parent could be any object such as elm_list which does 1168 /* access: parent could be any object such as elm_list which does
1169 not know elc_ctxpopup as its child object in the focus_next(); */ 1169 not know elc_ctxpopup as its child object in the focus_next(); */
@@ -1176,7 +1176,7 @@ elm_ctxpopup_add(Evas_Object *parent)
1176EOLIAN static Eo * 1176EOLIAN static Eo *
1177_elm_ctxpopup_efl_object_constructor(Eo *obj, Elm_Ctxpopup_Data *_pd EINA_UNUSED) 1177_elm_ctxpopup_efl_object_constructor(Eo *obj, Elm_Ctxpopup_Data *_pd EINA_UNUSED)
1178{ 1178{
1179 obj = efl_constructor(eo_super(obj, MY_CLASS)); 1179 obj = efl_constructor(efl_super(obj, MY_CLASS));
1180 efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY); 1180 efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
1181 evas_object_smart_callbacks_descriptions_set(obj, _smart_callbacks); 1181 evas_object_smart_callbacks_descriptions_set(obj, _smart_callbacks);
1182 elm_interface_atspi_accessible_role_set(obj, ELM_ATSPI_ROLE_POPUP_MENU); 1182 elm_interface_atspi_accessible_role_set(obj, ELM_ATSPI_ROLE_POPUP_MENU);
@@ -1204,7 +1204,7 @@ _elm_ctxpopup_hover_parent_set(Eo *obj, Elm_Ctxpopup_Data *sd, Evas_Object *pare
1204 1204
1205 //Update Background 1205 //Update Background
1206 evas_object_geometry_get(parent, &x, &y, &w, &h); 1206 evas_object_geometry_get(parent, &x, &y, &w, &h);
1207 if (parent && eo_isa(parent, EFL_UI_WIN_CLASS)) 1207 if (parent && efl_isa(parent, EFL_UI_WIN_CLASS))
1208 x = y = 0; 1208 x = y = 0;
1209 evas_object_move(sd->bg, x, y); 1209 evas_object_move(sd->bg, x, y);
1210 evas_object_resize(sd->bg, w, h); 1210 evas_object_resize(sd->bg, w, h);
@@ -1250,8 +1250,8 @@ _item_wrap_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UN
1250EOLIAN static Eo * 1250EOLIAN static Eo *
1251_elm_ctxpopup_item_efl_object_constructor(Eo *obj, Elm_Ctxpopup_Item_Data *it) 1251_elm_ctxpopup_item_efl_object_constructor(Eo *obj, Elm_Ctxpopup_Item_Data *it)
1252{ 1252{
1253 obj = efl_constructor(eo_super(obj, ELM_CTXPOPUP_ITEM_CLASS)); 1253 obj = efl_constructor(efl_super(obj, ELM_CTXPOPUP_ITEM_CLASS));
1254 it->base = eo_data_scope_get(obj, ELM_WIDGET_ITEM_CLASS); 1254 it->base = efl_data_scope_get(obj, ELM_WIDGET_ITEM_CLASS);
1255 1255
1256 return obj; 1256 return obj;
1257} 1257}
@@ -1261,14 +1261,14 @@ _elm_ctxpopup_item_append(Eo *obj, Elm_Ctxpopup_Data *sd, const char *label, Eva
1261{ 1261{
1262 Eo *eo_item; 1262 Eo *eo_item;
1263 1263
1264 eo_item = eo_add(ELM_CTXPOPUP_ITEM_CLASS, obj, elm_obj_ctxpopup_item_init(eo_self, func, data)); 1264 eo_item = efl_add(ELM_CTXPOPUP_ITEM_CLASS, obj, elm_obj_ctxpopup_item_init(efl_self, func, data));
1265 if (!eo_item) return NULL; 1265 if (!eo_item) return NULL;
1266 1266
1267 ELM_CTXPOPUP_ITEM_DATA_GET(eo_item, item); 1267 ELM_CTXPOPUP_ITEM_DATA_GET(eo_item, item);
1268 1268
1269 item->list_item = 1269 item->list_item =
1270 elm_list_item_append(sd->list, label, icon, NULL, _item_wrap_cb, item); 1270 elm_list_item_append(sd->list, label, icon, NULL, _item_wrap_cb, item);
1271 eo_ref(item->list_item); 1271 efl_ref(item->list_item);
1272 sd->items = eina_list_append(sd->items, eo_item); 1272 sd->items = eina_list_append(sd->items, eo_item);
1273 1273
1274 if (sd->visible) elm_layout_sizing_eval(obj); 1274 if (sd->visible) elm_layout_sizing_eval(obj);
@@ -1354,14 +1354,14 @@ _elm_ctxpopup_item_prepend(Eo *obj, Elm_Ctxpopup_Data *sd, const char *label, Ev
1354{ 1354{
1355 Eo *eo_item; 1355 Eo *eo_item;
1356 1356
1357 eo_item = eo_add(ELM_CTXPOPUP_ITEM_CLASS, obj, elm_obj_ctxpopup_item_init(eo_self, func, data)); 1357 eo_item = efl_add(ELM_CTXPOPUP_ITEM_CLASS, obj, elm_obj_ctxpopup_item_init(efl_self, func, data));
1358 if (!eo_item) return NULL; 1358 if (!eo_item) return NULL;
1359 1359
1360 ELM_CTXPOPUP_ITEM_DATA_GET(eo_item, item); 1360 ELM_CTXPOPUP_ITEM_DATA_GET(eo_item, item);
1361 1361
1362 item->list_item = 1362 item->list_item =
1363 elm_list_item_prepend(sd->list, label, icon, NULL, _item_wrap_cb, item); 1363 elm_list_item_prepend(sd->list, label, icon, NULL, _item_wrap_cb, item);
1364 eo_ref(item->list_item); 1364 efl_ref(item->list_item);
1365 sd->items = eina_list_prepend(sd->items, eo_item); 1365 sd->items = eina_list_prepend(sd->items, eo_item);
1366 1366
1367 if (sd->visible) elm_layout_sizing_eval(obj); 1367 if (sd->visible) elm_layout_sizing_eval(obj);
@@ -1407,7 +1407,7 @@ _elm_ctxpopup_item_init(Eo *eo_item,
1407{ 1407{
1408 Eo *obj; 1408 Eo *obj;
1409 obj = efl_parent_get(eo_item); 1409 obj = efl_parent_get(eo_item);
1410 Elm_Ctxpopup_Data *sd = eo_data_scope_get(obj, ELM_CTXPOPUP_CLASS); 1410 Elm_Ctxpopup_Data *sd = efl_data_scope_get(obj, ELM_CTXPOPUP_CLASS);
1411 if (!sd->list) 1411 if (!sd->list)
1412 { 1412 {
1413 sd->list = elm_list_add(obj); 1413 sd->list = elm_list_add(obj);
@@ -1468,7 +1468,7 @@ EOLIAN static Elm_Atspi_State_Set
1468_elm_ctxpopup_elm_interface_atspi_accessible_state_set_get(Eo *obj, Elm_Ctxpopup_Data *sd EINA_UNUSED) 1468_elm_ctxpopup_elm_interface_atspi_accessible_state_set_get(Eo *obj, Elm_Ctxpopup_Data *sd EINA_UNUSED)
1469{ 1469{
1470 Elm_Atspi_State_Set ret; 1470 Elm_Atspi_State_Set ret;
1471 ret = elm_interface_atspi_accessible_state_set_get(eo_super(obj, MY_CLASS)); 1471 ret = elm_interface_atspi_accessible_state_set_get(efl_super(obj, MY_CLASS));
1472 1472
1473 STATE_TYPE_SET(ret, ELM_ATSPI_STATE_MODAL); 1473 STATE_TYPE_SET(ret, ELM_ATSPI_STATE_MODAL);
1474 1474