forked from enlightenment/efl
elm_focus: implement missing functions
there is one function that needs to be implemented by the inheritor of Efl.Ui.Focus.Object and that is focus_parent, otherwise child_focus cannot be propagated correctly. This is now achived correctly for all widgets. This fixes from elm_object_focus_get results for toolbar and calendar. Segmentcontrol inherits from the class, however, the widget itself does not allow focus, so its never registered probebly. Differential Revision: https://phab.enlightenment.org/D7331
This commit is contained in:
parent
e661c4acc3
commit
fccc5fc438
|
@ -1301,4 +1301,10 @@ _efl_ui_calendar_item_efl_ui_focus_object_focus_geometry_get(const Eo *obj EINA_
|
|||
return efl_gfx_entity_geometry_get(pd->part);
|
||||
}
|
||||
|
||||
EOLIAN static Efl_Ui_Focus_Object*
|
||||
_efl_ui_calendar_item_efl_ui_focus_object_focus_parent_get(const Eo *obj, Efl_Ui_Calendar_Item_Data *pd EINA_UNUSED)
|
||||
{
|
||||
return efl_parent_get(obj);
|
||||
}
|
||||
|
||||
#include "efl_ui_calendar_item.eo.c"
|
||||
|
|
|
@ -11,6 +11,7 @@ class Efl.Ui.Calendar_Item (Efl.Object, Efl.Ui.Focus.Object)
|
|||
}
|
||||
implements {
|
||||
Efl.Ui.Focus.Object.focus {set;}
|
||||
Efl.Ui.Focus.Object.focus_parent {get;}
|
||||
Efl.Ui.Focus.Object.focus_geometry {get;}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1979,4 +1979,11 @@ _elm_calendar_item_efl_ui_focus_object_focus_geometry_get(const Eo *obj EINA_UNU
|
|||
return efl_gfx_entity_geometry_get(pd->part);
|
||||
}
|
||||
|
||||
EOLIAN static Efl_Ui_Focus_Object*
|
||||
_elm_calendar_item_efl_ui_focus_object_focus_parent_get(const Eo *obj, Elm_Calendar_Item_Data *pd EINA_UNUSED)
|
||||
{
|
||||
return efl_parent_get(obj);
|
||||
}
|
||||
|
||||
|
||||
#include "elm_calendar_item.eo.c"
|
||||
|
|
|
@ -11,6 +11,7 @@ class Elm.Calendar.Item (Efl.Object, Efl.Ui.Focus.Object)
|
|||
}
|
||||
implements {
|
||||
Efl.Ui.Focus.Object.focus {set;}
|
||||
Efl.Ui.Focus.Object.focus_parent {get;}
|
||||
Efl.Ui.Focus.Object.focus_geometry {get;}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -819,6 +819,12 @@ _elm_segment_control_item_efl_ui_focus_object_focus_geometry_get(const Eo *obj E
|
|||
return efl_gfx_entity_geometry_get(VIEW(pd));
|
||||
}
|
||||
|
||||
EOLIAN static Efl_Ui_Focus_Object*
|
||||
_elm_segment_control_item_efl_ui_focus_object_focus_parent_get(const Eo *obj EINA_UNUSED, Elm_Segment_Control_Item_Data *pd)
|
||||
{
|
||||
return WIDGET(pd);
|
||||
}
|
||||
|
||||
/* Internal EO APIs and hidden overrides */
|
||||
|
||||
#define ELM_SEGMENT_CONTROL_EXTRA_OPS \
|
||||
|
|
|
@ -42,5 +42,6 @@ class Elm.Segment_Control.Item(Elm.Widget.Item, Efl.Ui.Focus.Object, Efl.Ui.Lega
|
|||
Elm.Widget.Item.part_text { get; set; }
|
||||
Elm.Widget.Item.part_content { get; set; }
|
||||
Efl.Ui.Focus.Object.focus_geometry {get; }
|
||||
Efl.Ui.Focus.Object.focus_parent {get;}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -4070,6 +4070,12 @@ _elm_toolbar_efl_ui_focus_composition_prepare(Eo *obj, Elm_Toolbar_Data *pd)
|
|||
efl_ui_focus_composition_elements_set(obj, order);
|
||||
}
|
||||
|
||||
EOLIAN static Efl_Ui_Focus_Object*
|
||||
_elm_toolbar_item_efl_ui_focus_object_focus_parent_get(const Eo *obj, Elm_Toolbar_Item_Data *pd)
|
||||
{
|
||||
return WIDGET(pd);
|
||||
}
|
||||
|
||||
|
||||
/* Standard widget overrides */
|
||||
|
||||
|
|
|
@ -322,6 +322,7 @@ class Elm.Toolbar_Item(Elm.Widget.Item, Efl.Ui.Focus.Object, Efl.Ui.Legacy)
|
|||
Elm.Widget.Item.part_content_unset;
|
||||
Efl.Ui.Focus.Object.focus_geometry { get; }
|
||||
Efl.Ui.Focus.Object.focus { set; }
|
||||
Efl.Ui.Focus.Object.focus_parent { get; }
|
||||
Efl.Access.Object.i18n_name { get; }
|
||||
Efl.Access.Object.state_set { get; }
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue