}
}
implements {
+ Efl.Gfx.visible.set;
Efl.Object.constructor;
Efl.Object.destructor;
Efl.Object.dbg_info_get;
Efl.Canvas.Object.no_render.set;
Efl.Canvas.Object.paragraph_direction.set;
- Efl.Canvas.Group.group_hide;
- Efl.Canvas.Group.group_show;
Efl.Canvas.Group.group_move;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
_edje_emit(ed, "resize", NULL);
}
-EOLIAN static void
-_edje_object_efl_canvas_group_group_show(Eo *obj, Edje *ed)
+static void
+_edje_object_show(Eo *obj, Edje *ed)
{
Eina_List *l;
Edje *edg;
- efl_canvas_group_show(efl_super(obj, MY_CLASS));
- if (evas_object_visible_get(obj)) return;
+ efl_gfx_visible_set(efl_super(obj, MY_CLASS), EINA_TRUE);
if (_edje_lua_script_only(ed))
{
_edje_lua_script_only_show(ed);
_edje_emit(ed, "show", NULL);
}
-EOLIAN static void
-_edje_object_efl_canvas_group_group_hide(Eo *obj, Edje *ed)
+static void
+_edje_object_hide(Eo *obj, Edje *ed)
{
Eina_List *l;
Edje *edg;
- efl_canvas_group_hide(efl_super(obj, MY_CLASS));
- if (!evas_object_visible_get(obj)) return;
+ efl_gfx_visible_set(efl_super(obj, MY_CLASS), EINA_FALSE);
if (_edje_lua_script_only(ed))
{
_edje_lua_script_only_hide(ed);
}
EOLIAN static void
+_edje_object_efl_gfx_visible_set(Eo *obj, Edje *ed, Eina_Bool vis)
+{
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_VISIBLE, 0, vis))
+ return;
+
+ if (vis) _edje_object_show(obj, ed);
+ else _edje_object_hide(obj, ed);
+}
+
+EOLIAN static void
_edje_object_efl_canvas_object_no_render_set(Eo *obj, Edje *ed, Eina_Bool enable)
{
Eina_List *l;
_efl_ui_image_internal_sizing_eval(obj, sd);
}
-EOLIAN static void
-_efl_ui_image_efl_canvas_group_group_show(Eo *obj, Efl_Ui_Image_Data *sd)
+static void
+_efl_ui_image_show(Eo *obj, Efl_Ui_Image_Data *sd)
{
sd->show = EINA_TRUE;
if (sd->preload_status == EFL_UI_IMAGE_PRELOADING) return;
- efl_canvas_group_show(efl_super(obj, MY_CLASS));
-
- evas_object_show(sd->img);
+ efl_gfx_visible_set(efl_super(obj, MY_CLASS), EINA_TRUE);
+ efl_gfx_visible_set(sd->img, EINA_TRUE);
+ ELM_SAFE_FREE(sd->prev_img, evas_object_del);
+}
+static void
+_efl_ui_image_hide(Eo *obj, Efl_Ui_Image_Data *sd)
+{
+ sd->show = EINA_FALSE;
+ efl_gfx_visible_set(efl_super(obj, MY_CLASS), EINA_FALSE);
+ efl_gfx_visible_set(sd->img, EINA_FALSE);
ELM_SAFE_FREE(sd->prev_img, evas_object_del);
}
EOLIAN static void
-_efl_ui_image_efl_canvas_group_group_hide(Eo *obj, Efl_Ui_Image_Data *sd)
+_efl_ui_image_efl_gfx_visible_set(Eo *obj, Efl_Ui_Image_Data *sd, Eina_Bool vis)
{
- efl_canvas_group_hide(efl_super(obj, MY_CLASS));
-
- sd->show = EINA_FALSE;
- evas_object_hide(sd->img);
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_VISIBLE, 0, vis))
+ return;
- ELM_SAFE_FREE(sd->prev_img, evas_object_del);
+ if (vis) _efl_ui_image_show(obj, sd);
+ else _efl_ui_image_hide(obj, sd);
}
EOLIAN static void
Efl.File.file.get;
Efl.File.mmap.set;
Efl.Gfx.color.set;
+ Efl.Gfx.visible.set;
Efl.Gfx.View.view_size.get;
Efl.Image.Load.load_size.set;
Efl.Image.Load.load_size.get;
Edje.Object.size_min_calc;
Edje.Object.calc_force;
Efl.Canvas.Object.clip.set;
- Efl.Canvas.Group.group_hide;
- Efl.Canvas.Group.group_show;
Efl.Canvas.Group.group_move;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
}
EOLIAN static void
-_efl_ui_text_efl_canvas_group_group_show(Eo *obj, Efl_Ui_Text_Data *sd EINA_UNUSED)
+_efl_ui_text_efl_gfx_visible_set(Eo *obj, Efl_Ui_Text_Data *sd EINA_UNUSED, Eina_Bool vis)
{
- efl_canvas_group_show(efl_super(obj, MY_CLASS));
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_VISIBLE, 0, vis))
+ return;
- _update_selection_handler(obj);
-}
-
-EOLIAN static void
-_efl_ui_text_efl_canvas_group_group_hide(Eo *obj, Efl_Ui_Text_Data *sd)
-{
- efl_canvas_group_hide(efl_super(obj, MY_CLASS));
-
- if (sd->have_selection)
+ efl_gfx_visible_set(efl_super(obj, MY_CLASS), vis);
+ if (vis)
+ _update_selection_handler(obj);
+ else if (sd->have_selection)
_hide_selection_handler(obj);
}
class.constructor;
Efl.Object.constructor;
Efl.Object.destructor;
+ Efl.Gfx.visible.set;
Efl.Canvas.Group.group_move;
Efl.Canvas.Group.group_member_add;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_resize;
Efl.Canvas.Group.group_del;
- Efl.Canvas.Group.group_show;
- Efl.Canvas.Group.group_hide;
Elm.Widget.activate;
Elm.Widget.focus_direction_manager_is;
Elm.Widget.theme_apply;
_elm_win_deferred_free--;
}
-EOLIAN static void
-_efl_ui_win_efl_canvas_group_group_show(Eo *obj, Efl_Ui_Win_Data *sd)
+static void
+_efl_ui_win_show(Eo *obj, Efl_Ui_Win_Data *sd)
{
- if (sd->modal_count) return;
- const Eina_List *l;
- Evas_Object *current;
Eina_Bool do_eval = EINA_FALSE;
+ if (sd->modal_count)
+ {
+ /* FIXME FIXME FIXME
+ * Ugly code flow: legacy code had an early return in smart_show, ie.
+ * evas object show would be processed but smart object show would be
+ * aborted. This super call tries to simulate that. */
+ efl_gfx_visible_set(efl_super(obj, EFL_CANVAS_GROUP_CLASS), EINA_TRUE);
+ return;
+ }
+
if (!evas_object_visible_get(obj)) do_eval = EINA_TRUE;
- efl_canvas_group_show(efl_super(obj, MY_CLASS));
+ efl_gfx_visible_set(efl_super(obj, MY_CLASS), EINA_TRUE);
if ((sd->modal) && (!evas_object_visible_get(obj)))
{
+ const Eina_List *l;
+ Evas_Object *current;
INCREMENT_MODALITY()
}
if (sd->shot.info) _shot_handle(sd);
}
-EOLIAN static void
-_efl_ui_win_efl_canvas_group_group_hide(Eo *obj, Efl_Ui_Win_Data *sd)
+static void
+_efl_ui_win_hide(Eo *obj, Efl_Ui_Win_Data *sd)
{
- if (sd->modal_count) return;
- const Eina_List *l;
- Evas_Object *current;
+ if (sd->modal_count)
+ {
+ /* FIXME FIXME FIXME
+ * Ugly code flow: legacy code had an early return in smart_show, ie.
+ * evas object show would be processed but smart object show would be
+ * aborted. This super call tries to simulate that. */
+ efl_gfx_visible_set(efl_super(obj, EFL_CANVAS_GROUP_CLASS), EINA_FALSE);
+ return;
+ }
- if (evas_object_visible_get(obj))
- _elm_win_state_eval_queue();
- efl_canvas_group_hide(efl_super(obj, MY_CLASS));
+ _elm_win_state_eval_queue();
+ efl_gfx_visible_set(efl_super(obj, MY_CLASS), EINA_FALSE);
if ((sd->modal) && (evas_object_visible_get(obj)))
{
+ const Eina_List *l;
+ Evas_Object *current;
DECREMENT_MODALITY()
}
}
EOLIAN static void
+_efl_ui_win_efl_gfx_visible_set(Eo *obj, Efl_Ui_Win_Data *sd, Eina_Bool vis)
+{
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_VISIBLE, 0, vis))
+ return;
+
+ if (vis) _efl_ui_win_show(obj, sd);
+ else _efl_ui_win_hide(obj, sd);
+}
+
+EOLIAN static void
_efl_ui_win_efl_input_interface_pointer_xy_get(Eo *obj EINA_UNUSED, Efl_Ui_Win_Data *sd, int *x, int *y)
{
evas_pointer_canvas_xy_get(sd->evas, x, y);
{
ELM_WIN_DATA_GET(data, sd);
+ /* FIXME: this intercept needs to be implemented in proper EO */
+
// this is called to make sure all smart containers have calculated their
// sizes BEFORE we show the window to make sure it initially appears at
// our desired size (ie min size is known first)
class.constructor;
Efl.Object.constructor;
Efl.Object.finalize;
- Efl.Canvas.Group.group_hide;
- Efl.Canvas.Group.group_show;
+ Efl.Gfx.visible.set;
Efl.Canvas.Group.group_move;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
}
EOLIAN static void
-_elm_combobox_efl_canvas_group_group_show(Eo *obj, Elm_Combobox_Data *sd)
+_elm_combobox_efl_gfx_visible_set(Eo *obj, Elm_Combobox_Data *sd, Eina_Bool vis)
{
- efl_canvas_group_show(efl_super(obj, MY_CLASS));
- if (sd->expanded) evas_object_show(sd->hover);
-}
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_VISIBLE, 0, vis))
+ return;
-EOLIAN static void
-_elm_combobox_efl_canvas_group_group_hide(Eo *obj, Elm_Combobox_Data *sd)
-{
- efl_canvas_group_hide(efl_super(obj, MY_CLASS));
- if (sd->hover) evas_object_hide(sd->hover);
+ efl_gfx_visible_set(efl_super(obj, MY_CLASS), vis);
+ if (vis)
+ {
+ if (sd->expanded) evas_object_show(sd->hover);
+ }
+ else
+ {
+ if (sd->hover) evas_object_hide(sd->hover);
+ }
}
EOLIAN static Eina_Bool
}
EOLIAN static void
-_elm_hoversel_efl_canvas_group_group_show(Eo *obj, Elm_Hoversel_Data *sd)
+_elm_hoversel_efl_gfx_visible_set(Eo *obj, Elm_Hoversel_Data *sd, Eina_Bool vis)
{
- efl_canvas_group_show(efl_super(obj, MY_CLASS));
- evas_object_show(sd->hover);
-}
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_VISIBLE, 0, vis))
+ return;
-EOLIAN static void
-_elm_hoversel_efl_canvas_group_group_hide(Eo *obj, Elm_Hoversel_Data *sd)
-{
- efl_canvas_group_hide(efl_super(obj, MY_CLASS));
- evas_object_hide(sd->hover);
+ efl_gfx_visible_set(efl_super(obj, MY_CLASS), vis);
+ efl_gfx_visible_set(sd->hover, vis);
}
EOLIAN static void
//Show only the top item view
EOLIAN static void
-_elm_naviframe_efl_canvas_group_group_show(Eo *obj, Elm_Naviframe_Data *sd EINA_UNUSED)
+_elm_naviframe_efl_gfx_visible_set(Eo *obj, Elm_Naviframe_Data *sd EINA_UNUSED, Eina_Bool vis)
{
Elm_Object_Item *eo_top;
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_VISIBLE, 0, vis))
+ return;
+
+ efl_gfx_visible_set(efl_super(obj, MY_CLASS), vis);
+ if (!vis) return;
+
eo_top = elm_naviframe_top_item_get(obj);
ELM_NAVIFRAME_ITEM_DATA_GET(eo_top, top);
implements {
class.constructor;
Efl.Object.constructor;
- Efl.Canvas.Group.group_hide;
- Efl.Canvas.Group.group_show;
+ Efl.Gfx.visible.set;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
Efl.Canvas.Group.group_resize;
}
EOLIAN static void
-_elm_entry_efl_canvas_group_group_show(Eo *obj, Elm_Entry_Data *sd)
+_elm_entry_efl_gfx_visible_set(Eo *obj, Elm_Entry_Data *sd, Eina_Bool vis)
{
- efl_canvas_group_show(efl_super(obj, MY_CLASS));
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_VISIBLE, 0, vis))
+ return;
- if (sd->have_selection)
- _update_selection_handler(obj);
-}
-
-EOLIAN static void
-_elm_entry_efl_canvas_group_group_hide(Eo *obj, Elm_Entry_Data *sd)
-{
- efl_canvas_group_hide(efl_super(obj, MY_CLASS));
+ efl_gfx_visible_set(efl_super(obj, MY_CLASS), vis);
if (sd->have_selection)
- _hide_selection_handler(obj);
+ {
+ if (vis) _update_selection_handler(obj);
+ else _hide_selection_handler(obj);
+ }
}
EOLIAN static void
implements {
class.constructor;
Efl.Object.constructor;
+ Efl.Gfx.visible.set;
Efl.Canvas.Group.group_move;
Efl.Canvas.Group.group_member_add;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_resize;
Efl.Canvas.Group.group_del;
- Efl.Canvas.Group.group_show;
- Efl.Canvas.Group.group_hide;
Elm.Widget.activate;
Elm.Widget.focus_direction_manager_is;
Elm.Widget.theme_apply;
}
EOLIAN static void
-_elm_hover_efl_canvas_group_group_show(Eo *obj, Elm_Hover_Data *_pd EINA_UNUSED)
+_elm_hover_efl_gfx_visible_set(Eo *obj, Elm_Hover_Data *_pd EINA_UNUSED, Eina_Bool vis)
{
- efl_canvas_group_show(efl_super(obj, MY_CLASS));
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_VISIBLE, 0, vis))
+ return;
- _hov_show_do(obj);
-}
-
-EOLIAN static void
-_elm_hover_efl_canvas_group_group_hide(Eo *obj, Elm_Hover_Data *_pd EINA_UNUSED)
-{
- const char *dismissstr;
-
- efl_canvas_group_hide(efl_super(obj, MY_CLASS));
+ efl_gfx_visible_set(efl_super(obj, MY_CLASS), vis);
- // for backward compatibility
- dismissstr = elm_layout_data_get(obj, "dismiss");
+ if (vis) _hov_show_do(obj);
+ else
+ {
+ // for backward compatibility
+ const char *dismissstr = elm_layout_data_get(obj, "dismiss");
- if (!dismissstr || strcmp(dismissstr, "on"))
- _hide_signals_emit(obj);
+ if (!eina_streq(dismissstr, "on"))
+ _hide_signals_emit(obj);
+ }
}
EOLIAN static const Elm_Layout_Part_Alias_Description*
implements {
class.constructor;
Efl.Object.constructor;
+ Efl.Gfx.visible.set;
Efl.Canvas.Group.group_del;
- Efl.Canvas.Group.group_hide;
- Efl.Canvas.Group.group_show;
Efl.Canvas.Group.group_move;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_resize;
class.constructor;
Efl.Object.constructor;
Efl.Object.destructor;
- Efl.Canvas.Group.group_hide;
- Efl.Canvas.Group.group_show;
+ Efl.Gfx.visible.set;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
Elm.Widget.widget_parent.set;
}
EOLIAN static void
-_elm_pan_efl_canvas_group_group_show(Eo *obj, Elm_Pan_Smart_Data *psd)
+_elm_pan_efl_gfx_visible_set(Eo *obj, Elm_Pan_Smart_Data *psd, Eina_Bool vis)
{
- efl_canvas_group_show(efl_super(obj, MY_PAN_CLASS));
-
- if (psd->content)
- evas_object_show(psd->content);
-}
-
-EOLIAN static void
-_elm_pan_efl_canvas_group_group_hide(Eo *obj, Elm_Pan_Smart_Data *psd)
-{
- efl_canvas_group_hide(efl_super(obj, MY_PAN_CLASS));
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_VISIBLE, 0, vis))
+ return;
- if (psd->content)
- evas_object_hide(psd->content);
+ efl_gfx_visible_set(efl_super(obj, MY_PAN_CLASS), vis);
+ if (psd->content) efl_gfx_visible_set(psd->content, vis);
}
EOLIAN static void
}
EOLIAN static void
-_elm_mapbuf_efl_canvas_group_group_show(Eo *obj, Elm_Mapbuf_Data *sd)
+_elm_mapbuf_efl_gfx_visible_set(Eo *obj, Elm_Mapbuf_Data *sd, Eina_Bool vis)
{
- efl_canvas_group_show(efl_super(obj, MY_CLASS));
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_VISIBLE, 0, vis))
+ return;
- _mapbuf_auto_eval(obj, sd);
- _configure(obj);
-}
-
-EOLIAN static void
-_elm_mapbuf_efl_canvas_group_group_hide(Eo *obj, Elm_Mapbuf_Data *sd)
-{
- efl_canvas_group_hide(efl_super(obj, MY_CLASS));
+ efl_gfx_visible_set(efl_super(obj, MY_CLASS), vis);
_mapbuf_auto_eval(obj, sd);
_configure(obj);
implements {
class.constructor;
Efl.Object.constructor;
- Efl.Canvas.Group.group_hide;
- Efl.Canvas.Group.group_show;
+ Efl.Gfx.visible.set;
Efl.Canvas.Group.group_move;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
}
EOLIAN static void
-_elm_menu_efl_canvas_group_group_show(Eo *obj EINA_UNUSED, Elm_Menu_Data *sd)
+_elm_menu_efl_gfx_visible_set(Eo *obj EINA_UNUSED, Elm_Menu_Data *sd, Eina_Bool vis)
{
- evas_object_show(sd->hv);
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_VISIBLE, 0, vis))
+ return;
+
+ if (vis) efl_gfx_visible_set(sd->hv, EINA_TRUE);
}
static void
class.constructor;
Efl.Object.constructor;
Efl.Object.destructor;
- Efl.Canvas.Group.group_show;
+ Efl.Gfx.visible.set;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
Elm.Widget.widget_parent;
implements {
class.constructor;
Efl.Object.constructor;
+ Efl.Gfx.visible.set;
Efl.Canvas.Group.group_del;
- Efl.Canvas.Group.group_show;
Efl.Canvas.Group.group_add;
Elm.Widget.focus_direction;
Elm.Widget.focus_next_manager_is;
sd->timer = NULL;
}
-EOLIAN static void
-_elm_notify_efl_canvas_group_group_show(Eo *obj, Elm_Notify_Data *sd)
+static void
+_elm_notify_show(Eo *obj, Elm_Notify_Data *sd)
{
sd->had_hidden = EINA_FALSE;
sd->in_timeout = EINA_FALSE;
- efl_canvas_group_show(efl_super(obj, MY_CLASS));
+ efl_gfx_visible_set(efl_super(obj, MY_CLASS), EINA_TRUE);
evas_object_show(sd->notify);
if (!sd->allow_events) evas_object_show(sd->block_events);
elm_object_focus_set(obj, EINA_TRUE);
}
-EOLIAN static void
-_elm_notify_efl_canvas_group_group_hide(Eo *obj, Elm_Notify_Data *sd)
+static void
+_elm_notify_hide(Eo *obj EINA_UNUSED, Elm_Notify_Data *sd)
{
const char *hide_signal;
return;
hide_signal = edje_object_data_get(sd->notify, "hide_finished_signal");
- if ((hide_signal) && (!strcmp(hide_signal, "on")))
+ if (eina_streq(hide_signal, "on"))
{
if (!sd->in_timeout)
edje_object_signal_emit(sd->notify, "elm,state,hide", "elm");
}
else //for backport supporting: edc without emitting hide finished signal
{
- efl_canvas_group_hide(efl_super(obj, MY_CLASS));
+ efl_gfx_visible_set(efl_super(obj, MY_CLASS), EINA_FALSE);
evas_object_hide(sd->notify);
if (sd->allow_events) evas_object_hide(sd->block_events);
}
ELM_SAFE_FREE(sd->timer, ecore_timer_del);
}
+EOLIAN static void
+_elm_notify_efl_gfx_visible_set(Eo *obj, Elm_Notify_Data *sd, Eina_Bool vis)
+{
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_VISIBLE, 0, vis))
+ return;
+
+ if (vis) _elm_notify_show(obj, sd);
+ else _elm_notify_hide(obj, sd);
+}
+
static void
_parent_del_cb(void *data,
Evas *e EINA_UNUSED,
sd->had_hidden = EINA_TRUE;
evas_object_hide(sd->notify);
if (!sd->allow_events) evas_object_hide(sd->block_events);
- efl_canvas_group_hide(efl_super(data, MY_CLASS));
+ efl_gfx_visible_set(efl_super(data, MY_CLASS), EINA_FALSE);
efl_event_callback_legacy_call(data, ELM_NOTIFY_EVENT_DISMISSED, NULL);
}
implements {
class.constructor;
Efl.Object.constructor;
- Efl.Canvas.Group.group_hide;
- Efl.Canvas.Group.group_show;
+ Efl.Gfx.visible.set;
Efl.Canvas.Group.group_move;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
implements {
Efl.Object.constructor;
class.constructor;
- Efl.Canvas.Group.group_hide;
- Efl.Canvas.Group.group_show;
+ Efl.Gfx.visible.set;
Efl.Canvas.Group.group_move;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
}
EOLIAN static void
-_elm_thumb_efl_canvas_group_group_show(Eo *obj, Elm_Thumb_Data *sd)
+_elm_thumb_efl_gfx_visible_set(Eo *obj, Elm_Thumb_Data *sd, Eina_Bool vis)
{
- efl_canvas_group_show(efl_super(obj, MY_CLASS));
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_VISIBLE, 0, vis))
+ return;
- _thumb_show(sd);
-}
+ efl_gfx_visible_set(efl_super(obj, MY_CLASS), vis);
-EOLIAN static void
-_elm_thumb_efl_canvas_group_group_hide(Eo *obj, Elm_Thumb_Data *sd)
-{
- ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd);
+ if (vis)
+ {
+ _thumb_show(sd);
+ return;
+ }
- efl_canvas_group_hide(efl_super(obj, MY_CLASS));
+ ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd);
if (sd->thumb.request)
{
Efl.Object.constructor;
Efl.File.file.set;
Efl.File.file.get;
- Efl.Canvas.Group.group_hide;
+ Efl.Gfx.visible.set;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
- Efl.Canvas.Group.group_show;
Efl.Ui.Draggable.drag_target.set;
Efl.Ui.Draggable.drag_target.get;
}
}
EOLIAN static void
-_elm_widget_efl_canvas_group_group_show(Eo *obj, Elm_Widget_Smart_Data *_pd)
+_elm_widget_efl_gfx_visible_set(Eo *obj, Elm_Widget_Smart_Data *pd, Eina_Bool vis)
{
Eina_Iterator *it;
Evas_Object *o;
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_VISIBLE, 0, vis))
+ return;
+
+ efl_gfx_visible_set(efl_super(obj, MY_CLASS), vis);
+
it = evas_object_smart_iterator_new(obj);
EINA_ITERATOR_FOREACH(it, o)
{
if (evas_object_data_get(o, "_elm_leaveme")) continue;
- evas_object_show(o);
+ efl_gfx_visible_set(o, vis);
}
eina_iterator_free(it);
- if (_elm_config->atspi_mode)
+ if (!_elm_config->atspi_mode || pd->on_destroy)
+ return;
+
+ if (vis)
{
elm_interface_atspi_accessible_added(obj);
- if (!_pd->on_destroy && _elm_widget_onscreen_is(obj))
- elm_interface_atspi_accessible_state_changed_signal_emit(obj, ELM_ATSPI_STATE_SHOWING, EINA_TRUE);
+ if (_elm_widget_onscreen_is(obj))
+ elm_interface_atspi_accessible_state_changed_signal_emit(obj, ELM_ATSPI_STATE_SHOWING, EINA_TRUE);
}
-}
-
-EOLIAN static void
-_elm_widget_efl_canvas_group_group_hide(Eo *obj, Elm_Widget_Smart_Data *_pd)
-{
- Eina_Iterator *it;
- Evas_Object *o;
-
- it = evas_object_smart_iterator_new(obj);
- EINA_ITERATOR_FOREACH(it, o)
+ else
{
- if (evas_object_data_get(o, "_elm_leaveme")) continue;
- evas_object_hide(o);
+ elm_interface_atspi_accessible_state_changed_signal_emit(obj, ELM_ATSPI_STATE_SHOWING, EINA_FALSE);
}
- eina_iterator_free(it);
-
- if (_elm_config->atspi_mode && !_pd->on_destroy)
- elm_interface_atspi_accessible_state_changed_signal_emit(obj, ELM_ATSPI_STATE_SHOWING, EINA_FALSE);
}
EOLIAN static void
Efl.Object.dbg_info_get;
Efl.Object.provider_find;
Efl.Gfx.color.set;
+ Efl.Gfx.visible.set;
Efl.Canvas.Object.clip.set;
Efl.Canvas.Object.no_render.set;
- Efl.Canvas.Group.group_hide;
Efl.Canvas.Group.group_calculate;
- Efl.Canvas.Group.group_show;
Efl.Canvas.Group.group_move;
Efl.Canvas.Group.group_member_del;
Efl.Canvas.Group.group_add;
implements {
Efl.Object.constructor;
Efl.Gfx.color.set;
+ Efl.Gfx.visible.set;
Efl.Canvas.Object.clip.set;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
Efl.Canvas.Group.group_move;
Efl.Canvas.Group.group_resize;
- Efl.Canvas.Group.group_show;
- Efl.Canvas.Group.group_hide;
Efl.File.file.set;
Efl.File.file.get;
Efl.Player.play.set;
}
EOLIAN static void
-_efl_canvas_video_efl_canvas_group_group_show(Evas_Object *obj EINA_UNUSED, Efl_Canvas_Video_Data *sd)
+_efl_canvas_video_efl_gfx_visible_set(Evas_Object *obj EINA_UNUSED, Efl_Canvas_Video_Data *sd, Eina_Bool vis)
{
- int a;
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_VISIBLE, 0, vis))
+ return;
- evas_object_show(sd->obj);
- if (sd->crop.clipper) evas_object_show(sd->crop.clipper);
+ efl_gfx_visible_set(efl_super(obj, MY_CLASS), vis);
+ efl_gfx_visible_set(sd->obj, vis);
+ efl_gfx_visible_set(sd->crop.clipper, vis);
- evas_object_color_get(sd->bg, NULL, NULL, NULL, &a);
- if (a > 0) evas_object_show(sd->bg);
-}
+ if (vis)
+ {
+ int a;
-EOLIAN static void
-_efl_canvas_video_efl_canvas_group_group_hide(Evas_Object *obj EINA_UNUSED, Efl_Canvas_Video_Data *sd)
-{
- evas_object_hide(sd->obj);
- if (sd->crop.clipper) evas_object_hide(sd->crop.clipper);
- evas_object_hide(sd->bg);
+ evas_object_color_get(sd->bg, NULL, NULL, NULL, &a);
+ if (a > 0) efl_gfx_visible_set(sd->bg, EINA_TRUE);
+ }
+ else
+ efl_gfx_visible_set(sd->bg, EINA_FALSE);
}
EOLIAN static void
enum _Evas_Object_Intercept_Cb_Type
{
- EVAS_OBJECT_INTERCEPT_CB_SHOW,
- EVAS_OBJECT_INTERCEPT_CB_HIDE,
+ EVAS_OBJECT_INTERCEPT_CB_VISIBLE,
EVAS_OBJECT_INTERCEPT_CB_MOVE,
EVAS_OBJECT_INTERCEPT_CB_RESIZE,
EVAS_OBJECT_INTERCEPT_CB_RAISE,
return: free(own(iterator<Efl.Gfx>), eina_iterator_free);
legacy: evas_object_smart_iterator_new;
}
- group_show {
- [[No description supplied by the EAPI.]]
- legacy: null;
- }
group_move {
[[No description supplied by the EAPI.]]
legacy: null;
@in y: Evas.Coord;
}
}
- group_hide {
- [[No description supplied by the EAPI.]]
- legacy: null;
- }
group_add {
[[Instantiates a new smart object described by $s.
data: Evas_Object_Smart_Clipped_Data;
implements {
Efl.Gfx.color.set;
+ Efl.Gfx.visible.set;
Efl.Canvas.Object.clip.set;
Efl.Canvas.Object.no_render.set;
- Efl.Canvas.Group.group_hide;
- Efl.Canvas.Group.group_show;
Efl.Canvas.Group.group_move;
Efl.Canvas.Group.group_member_del;
Efl.Canvas.Group.group_add;
switch (cb_type)
{
- case EVAS_OBJECT_INTERCEPT_CB_SHOW:
- if (obj->cur->visible) return 1;
- if (!obj->interceptors) return 0;
- return evas_object_intercept_call_show(eo_obj, obj);
-
- case EVAS_OBJECT_INTERCEPT_CB_HIDE:
- if (!obj->cur->visible) return 1;
+ case EVAS_OBJECT_INTERCEPT_CB_VISIBLE:
+ va_start(args, internal);
+ i = !!va_arg(args, int);
+ va_end(args);
+ if (i == obj->cur->visible) return 1;
if (!obj->interceptors) return 0;
- return evas_object_intercept_call_hide(eo_obj, obj);
+ if (i) return evas_object_intercept_call_show(eo_obj, obj);
+ else return evas_object_intercept_call_hide(eo_obj, obj);
case EVAS_OBJECT_INTERCEPT_CB_MOVE:
if (!obj->interceptors) return 0;
#define MY_CLASS_NAME "Evas_Object"
-static void
-_show(Evas_Object *eo_obj, Evas_Object_Protected_Data *obj);
-static void
-_hide(Evas_Object *eo_obj, Evas_Object_Protected_Data *obj);
-
static Eina_Inlist *
get_layer_objects(Evas_Layer *l)
{
}
static void
-_efl_canvas_object_efl_gfx_visible_set(Eo *eo_obj,
- Evas_Object_Protected_Data *obj,
- Eina_Bool visible)
-{
- evas_object_async_block(obj);
- if (visible) _show(eo_obj, obj);
- else _hide(eo_obj, obj);
-}
-
-static void
_show(Evas_Object *eo_obj, Evas_Object_Protected_Data *obj)
{
- if (_evas_object_intercept_call(eo_obj, EVAS_OBJECT_INTERCEPT_CB_SHOW, 1)) return;
- if (obj->is_smart)
+ if (obj->is_smart && obj->smart.smart && obj->smart.smart->smart_class->show)
{
- efl_canvas_group_show(eo_obj);
+ obj->smart.smart->smart_class->show(eo_obj);
}
EINA_COW_STATE_WRITE_BEGIN(obj, state_write, cur)
{
static void
_hide(Evas_Object *eo_obj, Evas_Object_Protected_Data *obj)
{
- if (_evas_object_intercept_call(eo_obj, EVAS_OBJECT_INTERCEPT_CB_HIDE, 1)) return;
- if (obj->is_smart)
+ if (obj->is_smart && obj->smart.smart && obj->smart.smart->smart_class->hide)
{
- efl_canvas_group_hide(eo_obj);
+ obj->smart.smart->smart_class->hide(eo_obj);
}
-
EINA_COW_STATE_WRITE_BEGIN(obj, state_write, cur)
{
state_write->visible = 0;
evas_object_inform_call_hide(eo_obj);
}
+EOLIAN static void
+_efl_canvas_object_efl_gfx_visible_set(Eo *eo_obj, Evas_Object_Protected_Data *obj,
+ Eina_Bool vis)
+{
+ if (_evas_object_intercept_call(eo_obj, EVAS_OBJECT_INTERCEPT_CB_VISIBLE, 1, vis))
+ return;
+
+ if (vis) _show(eo_obj, obj);
+ else _hide(eo_obj, obj);
+}
+
static Eina_Bool
_efl_canvas_object_efl_gfx_visible_get(Eo *eo_obj EINA_UNUSED,
Evas_Object_Protected_Data *obj)
}
EOLIAN static void
-_efl_canvas_group_group_show(Eo *eo_obj, Evas_Smart_Data *o EINA_UNUSED)
-{
- // If this function is reached, so we do nothing except trying to call
- // the function of the legacy smart class.
- Evas_Object_Protected_Data *obj = efl_data_scope_get(eo_obj, EFL_CANVAS_OBJECT_CLASS);
- Evas_Smart *s = obj->smart.smart;
- if (s && s->smart_class->show) s->smart_class->show(eo_obj);
-}
-
-EOLIAN static void
-_efl_canvas_group_group_hide(Eo *eo_obj, Evas_Smart_Data *o EINA_UNUSED)
-{
- // If this function is reached, so we do nothing except trying to call
- // the function of the legacy smart class.
- Evas_Object_Protected_Data *obj = efl_data_scope_get(eo_obj, EFL_CANVAS_OBJECT_CLASS);
- Evas_Smart *s = obj->smart.smart;
- if (s && s->smart_class->hide) s->smart_class->hide(eo_obj);
-}
-
-EOLIAN static void
_efl_canvas_group_efl_canvas_object_no_render_set(Eo *eo_obj, Evas_Smart_Data *o EINA_UNUSED, Eina_Bool enable)
{
Evas_Object_Protected_Data *obj2;
}
static void
-evas_object_smart_clipped_group_show(Evas_Object *eo_obj)
+evas_object_smart_clipped_smart_show(Evas_Object *eo_obj)
{
CSO_DATA_GET_OR_RETURN(eo_obj, cso);
if (evas_object_clipees_has(cso->clipper))
evas_object_show(cso->clipper); /* just show if clipper being used */
}
-EOLIAN static void
-_efl_canvas_group_clipped_efl_canvas_group_group_show(Eo *eo_obj, Evas_Object_Smart_Clipped_Data *obj EINA_UNUSED)
-{
- evas_object_smart_clipped_group_show(eo_obj);
-}
-
static void
-evas_object_smart_clipped_group_hide(Evas_Object *eo_obj)
+evas_object_smart_clipped_smart_hide(Evas_Object *eo_obj)
{
CSO_DATA_GET_OR_RETURN(eo_obj, cso);
evas_object_hide(cso->clipper);
}
EOLIAN static void
-_efl_canvas_group_clipped_efl_canvas_group_group_hide(Eo *eo_obj, Evas_Object_Smart_Clipped_Data *obj EINA_UNUSED)
+_efl_canvas_group_clipped_efl_gfx_visible_set(Eo *eo_obj, Evas_Object_Smart_Clipped_Data *obj EINA_UNUSED, Eina_Bool vis)
{
- evas_object_smart_clipped_group_hide(eo_obj);
+ if (_evas_object_intercept_call(eo_obj, EVAS_OBJECT_INTERCEPT_CB_VISIBLE, 0, vis))
+ return;
+
+ efl_gfx_visible_set(efl_super(eo_obj, MY_CLASS), vis);
+
+ if (vis) evas_object_smart_clipped_smart_show(eo_obj);
+ else evas_object_smart_clipped_smart_hide(eo_obj);
}
EOLIAN static void
sc->add = evas_object_smart_clipped_smart_add;
sc->del = evas_object_smart_clipped_smart_del;
sc->move = evas_object_smart_clipped_smart_move;
- sc->show = evas_object_smart_clipped_group_show;
- sc->hide = evas_object_smart_clipped_group_hide;
+ sc->show = evas_object_smart_clipped_smart_show;
+ sc->hide = evas_object_smart_clipped_smart_hide;
sc->color_set = evas_object_smart_clipped_smart_color_set;
sc->clip_set = evas_object_smart_clipped_smart_clip_set;
sc->clip_unset = evas_object_smart_clipped_smart_clip_unset;