summaryrefslogtreecommitdiff
path: root/src/lib/elementary/elc_naviframe.c
diff options
context:
space:
mode:
authorMarcel Hollerbach <marcel-hollerbach@t-online.de>2017-09-25 18:10:47 +0200
committerMarcel Hollerbach <marcel-hollerbach@t-online.de>2017-10-10 19:28:46 +0200
commit4884793cf0dec1ed94c6f50df10abacdd8ac60ce (patch)
treed0fb34b3801b718012061d6dc893d81c733d63df /src/lib/elementary/elc_naviframe.c
parent8019639b29a56750390f99a9132df84835b9596b (diff)
elm_naviframe: remove old api!
Diffstat (limited to 'src/lib/elementary/elc_naviframe.c')
-rw-r--r--src/lib/elementary/elc_naviframe.c92
1 files changed, 2 insertions, 90 deletions
diff --git a/src/lib/elementary/elc_naviframe.c b/src/lib/elementary/elc_naviframe.c
index c6a3e56..3688971 100644
--- a/src/lib/elementary/elc_naviframe.c
+++ b/src/lib/elementary/elc_naviframe.c
@@ -90,19 +90,9 @@ _resize_object_reset(Evas_Object *obj, Elm_Naviframe_Item_Data *it)
90static void 90static void
91_prev_page_focus_recover(Elm_Naviframe_Item_Data *it) 91_prev_page_focus_recover(Elm_Naviframe_Item_Data *it)
92{ 92{
93 Evas_Object *newest; 93 Elm_Naviframe *n = it->base->widget;
94 unsigned int order = 0;
95 94
96 newest = elm_widget_newest_focus_order_get(VIEW(it), &order, EINA_TRUE); 95 efl_ui_focus_manager_focus_set(efl_ui_focus_user_manager_get(n), n);
97 if (newest)
98 elm_object_focus_set(newest, EINA_TRUE);
99 else
100 {
101 if (elm_object_focus_allow_get(VIEW(it)))
102 elm_object_focus_set(VIEW(it), EINA_TRUE);
103 else
104 elm_object_focus_set(WIDGET(it), EINA_TRUE);
105 }
106} 96}
107 97
108EOLIAN static void 98EOLIAN static void
@@ -1378,76 +1368,6 @@ _on_obj_size_hints_changed(void *data EINA_UNUSED, Evas *e EINA_UNUSED,
1378 _item_dispmode_set(it, dispmode); 1368 _item_dispmode_set(it, dispmode);
1379} 1369}
1380 1370
1381EOLIAN static Eina_Bool
1382_elm_naviframe_elm_widget_focus_next(Eo *obj, Elm_Naviframe_Data *sd EINA_UNUSED, Elm_Focus_Direction dir, Evas_Object **next, Elm_Object_Item **next_item)
1383{
1384 Evas_Object *ao;
1385
1386 Eina_List *l = NULL;
1387 Elm_Object_Item *eo_top_it;
1388 void *(*list_data_get)(const Eina_List *list);
1389
1390 Eina_Bool int_ret = EINA_FALSE;
1391
1392 eo_top_it = elm_naviframe_top_item_get(obj);
1393 if (!eo_top_it) goto end;
1394
1395 list_data_get = eina_list_data_get;
1396
1397 ELM_NAVIFRAME_ITEM_DATA_GET(eo_top_it, top_it);
1398 l = eina_list_append(l, VIEW(top_it));
1399
1400 /* access */
1401 if (_elm_config->access_mode)
1402 {
1403 ao = _access_object_get(top_it, TITLE_ACCESS_PART);
1404 if (ao) l = eina_list_append(l, ao);
1405 }
1406
1407 int_ret = elm_widget_focus_list_next_get(obj, l, list_data_get, dir, next, next_item);
1408 eina_list_free(l);
1409
1410end:
1411 if (!int_ret)
1412 {
1413 *next = obj;
1414 int_ret = !elm_widget_focus_get(obj);
1415 }
1416
1417 return int_ret;
1418}
1419
1420EOLIAN static Eina_Bool
1421_elm_naviframe_elm_widget_focus_direction_manager_is(Eo *obj EINA_UNUSED, Elm_Naviframe_Data *sd EINA_UNUSED)
1422{
1423 return EINA_TRUE;
1424}
1425
1426EOLIAN static Eina_Bool
1427_elm_naviframe_elm_widget_focus_direction(Eo *obj EINA_UNUSED, Elm_Naviframe_Data *sd EINA_UNUSED, const Evas_Object *base, double degree, Evas_Object **direction, Elm_Object_Item **direction_item, double *weight)
1428{
1429 Eina_Bool int_ret;
1430
1431 Eina_List *l = NULL;
1432 Elm_Object_Item *eo_top_it;
1433 void *(*list_data_get)(const Eina_List *list);
1434
1435 eo_top_it = elm_naviframe_top_item_get(obj);
1436 if (!eo_top_it) return EINA_FALSE;
1437
1438 list_data_get = eina_list_data_get;
1439
1440 ELM_NAVIFRAME_ITEM_DATA_GET(eo_top_it, top_it);
1441 l = eina_list_append(l, VIEW(top_it));
1442
1443 int_ret = elm_widget_focus_list_direction_get
1444 (obj, base, l, list_data_get, degree, direction, direction_item, weight);
1445
1446 eina_list_free(l);
1447
1448 return int_ret;
1449}
1450
1451EOLIAN static void 1371EOLIAN static void
1452_elm_naviframe_efl_canvas_group_group_add(Eo *obj, Elm_Naviframe_Data *priv) 1372_elm_naviframe_efl_canvas_group_group_add(Eo *obj, Elm_Naviframe_Data *priv)
1453{ 1373{
@@ -1611,7 +1531,6 @@ _item_push_helper(Elm_Naviframe_Item_Data *item)
1611 evas_object_show(VIEW(item)); 1531 evas_object_show(VIEW(item));
1612 1532
1613 ELM_NAVIFRAME_ITEM_DATA_GET(eo_top_item, top_item); 1533 ELM_NAVIFRAME_ITEM_DATA_GET(eo_top_item, top_item);
1614 if (top_item) elm_obj_widget_focused_object_clear(VIEW(top_item));
1615 _resize_object_reset(obj, item); 1534 _resize_object_reset(obj, item);
1616 if (top_item) 1535 if (top_item)
1617 { 1536 {
@@ -1752,7 +1671,6 @@ _elm_naviframe_item_insert_after(Eo *obj, Elm_Naviframe_Data *sd, Elm_Object_Ite
1752 1671
1753 if (top_inserted) 1672 if (top_inserted)
1754 { 1673 {
1755 elm_obj_widget_focused_object_clear(VIEW(after));
1756 elm_widget_tree_unfocusable_set(VIEW(after), EINA_TRUE); 1674 elm_widget_tree_unfocusable_set(VIEW(after), EINA_TRUE);
1757 _resize_object_reset(obj, it); 1675 _resize_object_reset(obj, it);
1758 evas_object_show(VIEW(it)); 1676 evas_object_show(VIEW(it));
@@ -2071,12 +1989,6 @@ _elm_naviframe_event_enabled_get(Eo *obj EINA_UNUSED, Elm_Naviframe_Data *sd)
2071 return !sd->freeze_events; 1989 return !sd->freeze_events;
2072} 1990}
2073 1991
2074EOLIAN static Eina_Bool
2075_elm_naviframe_elm_widget_focus_next_manager_is(Eo *obj EINA_UNUSED, Elm_Naviframe_Data *sd EINA_UNUSED)
2076{
2077 return EINA_TRUE;
2078}
2079
2080static void 1992static void
2081_elm_naviframe_class_constructor(Efl_Class *klass) 1993_elm_naviframe_class_constructor(Efl_Class *klass)
2082{ 1994{