elm_win_focus_highlight_animate_set(win, enable);
}
+EOLIAN static Eina_Bool
+_elm_widget_focus_highlight_style_set(Eo *obj, Elm_Widget_Smart_Data *sd EINA_UNUSED, const char *style)
+{
+ // Forward to closest parent Window
+ Evas_Object *win = elm_widget_top_get(obj);
+
+ if (win && efl_isa(win, EFL_UI_WIN_CLASS))
+ return elm_obj_widget_focus_highlight_style_set(win, style);
+
+ return EINA_FALSE;
+}
+
+EOLIAN static const char *
+_elm_widget_focus_highlight_style_get(Eo *obj, Elm_Widget_Smart_Data *sd EINA_UNUSED)
+{
+ // Forward to closest parent Window
+ Evas_Object *win = elm_widget_top_get(obj);
+
+ if (win && efl_isa(win, EFL_UI_WIN_CLASS))
+ return elm_win_focus_highlight_style_get(win);
+
+ return NULL;
+}
+
static Eina_Bool
_tree_unfocusable(Eo *obj)
{
}
}
-EOLIAN static Eina_Bool
-_elm_widget_focus_highlight_style_set(Eo *obj EINA_UNUSED, Elm_Widget_Smart_Data *sd, const char *style)
-{
- // FIXME: This does not return the proper error code! Who cares if the
- // string was changed?? This should return false if the desired style does
- // not exist...
- if (eina_stringshare_replace(&sd->focus_highlight_style, style)) return EINA_TRUE;
- return EINA_FALSE;
-}
-
-EOLIAN static const char*
-_elm_widget_focus_highlight_style_get(Eo *obj EINA_UNUSED, Elm_Widget_Smart_Data *sd)
-{
- return sd->focus_highlight_style;
-}
-
static void
_parent_focus(Evas_Object *obj, Elm_Object_Item *item)
{
region: Eina.Rectangle; [[The rectangle area.]]
}
}
- @property focus_highlight_style {
- [[Control the widget focus highlight style.
+ @property focus_highlight_enabled {
+ [[Whether focus highlight is enabled or not.
- If $style is $null, the default will be used.
+ As of EFL 1.21 focus highlight properties apply to a single window,
+ not a single widget. As a consequence, calls to this function may
+ be forwarded to the parent window. Future versions of EFL may
+ implement widget-specific focus highlight properties.
+
+ See also @.widget_top.
+ See also @.focus_highlight_style.
+ See also @.focus_highlight_animate.
]]
set {
- return: bool; [[$true on success, $false otherwise.]]
+ [[Set the enabled status for the focus highlight in a window.
+
+ This function will enable or disable the focus highlight,
+ regardless of the global setting for it.
+ ]]
}
get {
+ [[Get the enabled value of the focus highlight for this window.]]
}
values {
- style: string @nullable; [[The name of the focus highlight style.]]
+ enabled: bool; [[The enabled value for the highlight.]]
}
}
- @property focus_highlight_enabled {
- [[Whether focus highlight is enabled or not.]]
- set {
- [[Set the enabled status for the focus highlight in a window.
+ @property focus_highlight_style {
+ [[Control the widget focus highlight style.
- This function will enable or disable the focus highlight only
- for the given window, regardless of the global setting for it.
- ]]
+ If $style is $null, the default will be used.
+
+ As of EFL 1.21 focus highlight properties apply to a single window,
+ not a single widget. As a consequence, calls to this function may
+ be forwarded to the parent window. Future versions of EFL may
+ implement widget-specific focus highlight properties.
+
+ See also @.widget_top.
+ See also @.focus_highlight_enabled.
+ See also @.focus_highlight_animate.
+ ]]
+ set {
+ /* FIXME: This is async... success here means nothing. */
+ return: bool; [[$true on success, $false otherwise.]]
}
get {
- [[Get the enabled value of the focus highlight for this window.]]
}
values {
- enabled: bool; [[The enabled value for the highlight.]]
+ style: string @nullable; [[The name of the focus highlight style.]]
}
}
@property focus_highlight_animate {
- [[Whether focus highlight should animate or not.]]
+ [[Whether focus highlight should animate or not.
+
+ As of EFL 1.21 focus highlight properties apply to a single window,
+ not a single widget. As a consequence, calls to this function may
+ be forwarded to the parent window. Future versions of EFL may
+ implement widget-specific focus highlight properties.
+
+ See also @.widget_top.
+ See also @.focus_highlight_style.
+ See also @.focus_highlight_enabled.
+ ]]
set {
[[Set the animate status for the focus highlight for this window.
This function will enable or disable the animation of focus
- highlight only for the given window. If the widget is not a
- window, then this call is forwarded to the window (using
- @.widget_top).
+ highlight.
]]
}
get {