summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJean-Philippe Andre <jp.andre@samsung.com>2016-10-11 16:54:31 +0900
committerJean-Philippe Andre <jp.andre@samsung.com>2016-10-12 11:25:56 +0900
commit8a9f0bd603aaaf3abd3ca9aa87675c9199fe9d09 (patch)
tree0a6e61d5e156ea8b025912c937abe7bcc5cd9c5b
parent11b7cf6b728001dbcd42ce41d5ac2e129a835fd8 (diff)
downloadefl-8a9f0bd603aaaf3abd3ca9aa87675c9199fe9d09.tar.gz
evas/elm: Remove function group_resize
This is an override of efl_gfx_size_set. Same as before, the order of operations matter so it is possible that a corner case will break. In particular, legacy code was: - intercept - smart resize (do stuff), super, super, super - evas object resize The new code is more like: - intercept - super, super, super, evas object resize - do stuff But unfortunately this broke elm_widget (read: all widgets) as the internal resize was done before the object resize. So, inside the resize event cb, the resize_obj size would not match the smart object size. >_<
-rw-r--r--src/lib/edje/edje_object.eo2
-rw-r--r--src/lib/edje/edje_smart.c12
-rw-r--r--src/lib/elementary/efl_ui_image.c10
-rw-r--r--src/lib/elementary/efl_ui_image.eo2
-rw-r--r--src/lib/elementary/efl_ui_text.c7
-rw-r--r--src/lib/elementary/efl_ui_text.eo2
-rw-r--r--src/lib/elementary/efl_ui_win.c8
-rw-r--r--src/lib/elementary/efl_ui_win.eo2
-rw-r--r--src/lib/elementary/elc_combobox.c8
-rw-r--r--src/lib/elementary/elm_combobox.eo2
-rw-r--r--src/lib/elementary/elm_diskselector.c7
-rw-r--r--src/lib/elementary/elm_diskselector.eo2
-rw-r--r--src/lib/elementary/elm_entry.c7
-rw-r--r--src/lib/elementary/elm_entry.eo2
-rw-r--r--src/lib/elementary/elm_gengrid.c15
-rw-r--r--src/lib/elementary/elm_gengrid.eo2
-rw-r--r--src/lib/elementary/elm_gengrid_pan.eo2
-rw-r--r--src/lib/elementary/elm_genlist.c20
-rw-r--r--src/lib/elementary/elm_genlist.eo2
-rw-r--r--src/lib/elementary/elm_genlist_pan.eo2
-rw-r--r--src/lib/elementary/elm_glview.c9
-rw-r--r--src/lib/elementary/elm_glview.eo2
-rw-r--r--src/lib/elementary/elm_hover.c7
-rw-r--r--src/lib/elementary/elm_hover.eo2
-rw-r--r--src/lib/elementary/elm_interface_scrollable.c7
-rw-r--r--src/lib/elementary/elm_list.c7
-rw-r--r--src/lib/elementary/elm_list.eo2
-rw-r--r--src/lib/elementary/elm_map.c14
-rw-r--r--src/lib/elementary/elm_map.eo2
-rw-r--r--src/lib/elementary/elm_map_pan.eo2
-rw-r--r--src/lib/elementary/elm_mapbuf.c7
-rw-r--r--src/lib/elementary/elm_mapbuf.eo2
-rw-r--r--src/lib/elementary/elm_notify.c11
-rw-r--r--src/lib/elementary/elm_notify.eo2
-rw-r--r--src/lib/elementary/elm_pan.eo2
-rw-r--r--src/lib/elementary/elm_panel.c7
-rw-r--r--src/lib/elementary/elm_panel.eo2
-rw-r--r--src/lib/elementary/elm_photocam.c15
-rw-r--r--src/lib/elementary/elm_photocam.eo2
-rw-r--r--src/lib/elementary/elm_photocam_pan.eo2
-rw-r--r--src/lib/elementary/elm_scroller.c7
-rw-r--r--src/lib/elementary/elm_scroller.eo2
-rw-r--r--src/lib/elementary/elm_toolbar.c7
-rw-r--r--src/lib/elementary/elm_toolbar.eo2
-rw-r--r--src/lib/elementary/elm_widget.c13
-rw-r--r--src/lib/elementary/elm_widget.eo2
-rw-r--r--src/lib/emotion/efl_canvas_video.eo2
-rw-r--r--src/lib/emotion/emotion_smart.c7
-rw-r--r--src/lib/evas/canvas/efl_canvas_group.eo8
-rw-r--r--src/lib/evas/canvas/evas_box.eo2
-rw-r--r--src/lib/evas/canvas/evas_object_box.c9
-rw-r--r--src/lib/evas/canvas/evas_object_intercept.c7
-rw-r--r--src/lib/evas/canvas/evas_object_main.c40
-rw-r--r--src/lib/evas/canvas/evas_object_smart.c10
-rw-r--r--src/lib/evas/canvas/evas_object_table.c9
-rw-r--r--src/lib/evas/canvas/evas_table.eo2
-rw-r--r--src/lib/evas/include/evas_private.h1
57 files changed, 216 insertions, 136 deletions
diff --git a/src/lib/edje/edje_object.eo b/src/lib/edje/edje_object.eo
index b6ec2c6fe9..0ad4b2d215 100644
--- a/src/lib/edje/edje_object.eo
+++ b/src/lib/edje/edje_object.eo
@@ -2068,6 +2068,7 @@ class Edje.Object (Efl.Canvas.Group.Clipped, Efl.File, Efl.Container, Efl.Part)
implements {
Efl.Gfx.visible.set;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Object.constructor;
Efl.Object.destructor;
Efl.Object.dbg_info_get;
@@ -2075,7 +2076,6 @@ class Edje.Object (Efl.Canvas.Group.Clipped, Efl.File, Efl.Container, Efl.Part)
Efl.Canvas.Object.paragraph_direction.set;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
- Efl.Canvas.Group.group_resize;
Efl.Canvas.Group.group_calculate;
Efl.File.file.set;
Efl.File.file.get;
diff --git a/src/lib/edje/edje_smart.c b/src/lib/edje/edje_smart.c
index d0800a2109..0a69d5e0b1 100644
--- a/src/lib/edje/edje_smart.c
+++ b/src/lib/edje/edje_smart.c
@@ -254,9 +254,12 @@ _edje_limit_get(Edje *ed, Edje_Limit **limits, unsigned int length, Evas_Coord s
}
EOLIAN static void
-_edje_object_efl_canvas_group_group_resize(Eo *obj EINA_UNUSED, Edje *ed, Evas_Coord w, Evas_Coord h)
+_edje_object_efl_gfx_size_set(Eo *obj, Edje *ed, Evas_Coord w, Evas_Coord h)
{
- if ((w == ed->w) && (h == ed->h)) return;
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
+
+ if ((w == ed->w) && (h == ed->h)) goto super;
if (ed->collection)
{
_edje_limit_get(ed, ed->collection->limits.horizontal, ed->collection->limits.horizontal_count, ed->w, w);
@@ -279,12 +282,15 @@ _edje_object_efl_canvas_group_group_resize(Eo *obj EINA_UNUSED, Edje *ed, Evas_C
if (_edje_lua_script_only(ed))
{
_edje_lua_script_only_resize(ed);
- return;
+ goto super;
}
// evas_object_resize(ed->clipper, ed->w, ed->h);
ed->dirty = EINA_TRUE;
_edje_recalc_do(ed);
_edje_emit(ed, "resize", NULL);
+
+super:
+ efl_gfx_size_set(efl_super(obj, MY_CLASS), w, h);
}
static void
diff --git a/src/lib/elementary/efl_ui_image.c b/src/lib/elementary/efl_ui_image.c
index 80b2b33345..2e75cbe6a0 100644
--- a/src/lib/elementary/efl_ui_image.c
+++ b/src/lib/elementary/efl_ui_image.c
@@ -577,17 +577,21 @@ _efl_ui_image_efl_gfx_position_set(Eo *obj, Efl_Ui_Image_Data *sd, Evas_Coord x,
}
EOLIAN static void
-_efl_ui_image_efl_canvas_group_group_resize(Eo *obj, Efl_Ui_Image_Data *sd, Evas_Coord w, Evas_Coord h)
+_efl_ui_image_efl_gfx_size_set(Eo *obj, Efl_Ui_Image_Data *sd, Evas_Coord w, Evas_Coord h)
{
- efl_canvas_group_resize(efl_super(obj, MY_CLASS), w, h);
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
- if ((sd->img_w == w) && (sd->img_h == h)) return;
+ if ((sd->img_w == w) && (sd->img_h == h)) goto super;
sd->img_w = w;
sd->img_h = h;
/* takes care of resizing */
_efl_ui_image_internal_sizing_eval(obj, sd);
+
+super:
+ efl_gfx_size_set(efl_super(obj, MY_CLASS), w, h);
}
static void
diff --git a/src/lib/elementary/efl_ui_image.eo b/src/lib/elementary/efl_ui_image.eo
index c69cb3f50c..8bdf134ced 100644
--- a/src/lib/elementary/efl_ui_image.eo
+++ b/src/lib/elementary/efl_ui_image.eo
@@ -125,6 +125,7 @@ class Efl.Ui.Image (Elm.Widget, Efl.Ui.Clickable, Efl.Ui.Draggable,
Efl.Gfx.color.set;
Efl.Gfx.visible.set;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Gfx.View.view_size.get;
Efl.Image.Load.load_size.set;
Efl.Image.Load.load_size.get;
@@ -146,7 +147,6 @@ class Efl.Ui.Image (Elm.Widget, Efl.Ui.Clickable, Efl.Ui.Draggable,
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
Efl.Canvas.Group.group_member_add;
- Efl.Canvas.Group.group_resize;
Efl.Ui.Draggable.drag_target.set;
Efl.Ui.Draggable.drag_target.get;
Elm.Widget.theme_apply;
diff --git a/src/lib/elementary/efl_ui_text.c b/src/lib/elementary/efl_ui_text.c
index 5d6ecb3429..52ebe1134d 100644
--- a/src/lib/elementary/efl_ui_text.c
+++ b/src/lib/elementary/efl_ui_text.c
@@ -3483,12 +3483,15 @@ _efl_ui_text_efl_gfx_position_set(Eo *obj, Efl_Ui_Text_Data *sd, Evas_Coord x, E
}
EOLIAN static void
-_efl_ui_text_efl_canvas_group_group_resize(Eo *obj, Efl_Ui_Text_Data *sd, Evas_Coord w, Evas_Coord h)
+_efl_ui_text_efl_gfx_size_set(Eo *obj, Efl_Ui_Text_Data *sd, Evas_Coord w, Evas_Coord h)
{
- efl_canvas_group_resize(efl_super(obj, MY_CLASS), w, h);
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
evas_object_resize(sd->hit_rect, w, h);
_update_selection_handler(obj);
+
+ efl_gfx_size_set(efl_super(obj, MY_CLASS), w, h);
}
EOLIAN static void
diff --git a/src/lib/elementary/efl_ui_text.eo b/src/lib/elementary/efl_ui_text.eo
index d506a45332..8fe58331b8 100644
--- a/src/lib/elementary/efl_ui_text.eo
+++ b/src/lib/elementary/efl_ui_text.eo
@@ -418,9 +418,9 @@ class Efl.Ui.Text (Elm.Layout, Elm.Interface_Scrollable, Efl.Ui.Clickable,
Efl.Object.destructor;
Efl.Gfx.visible.set;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_member_add;
Efl.Canvas.Group.group_add;
- Efl.Canvas.Group.group_resize;
Efl.Canvas.Group.group_del;
Elm.Widget.activate;
Elm.Widget.focus_direction_manager_is;
diff --git a/src/lib/elementary/efl_ui_win.c b/src/lib/elementary/efl_ui_win.c
index 5dca56fbdf..56782307f7 100644
--- a/src/lib/elementary/efl_ui_win.c
+++ b/src/lib/elementary/efl_ui_win.c
@@ -2821,11 +2821,13 @@ super_skip:
}
EOLIAN static void
-_efl_ui_win_efl_canvas_group_group_resize(Eo *obj, Efl_Ui_Win_Data *sd, Evas_Coord w, Evas_Coord h)
+_efl_ui_win_efl_gfx_size_set(Eo *obj, Efl_Ui_Win_Data *sd, Evas_Coord w, Evas_Coord h)
{
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
+
if (sd->img_obj)
{
- efl_canvas_group_resize(efl_super(obj, MY_CLASS), w, h);
if (sd->constrain)
{
int sw, sh;
@@ -2841,6 +2843,8 @@ _efl_ui_win_efl_canvas_group_group_resize(Eo *obj, Efl_Ui_Win_Data *sd, Evas_Coo
}
if (!sd->response) TRAP(sd, resize, w, h);
+
+ efl_gfx_size_set(efl_super(obj, MY_CLASS), w, h);
}
static void
diff --git a/src/lib/elementary/efl_ui_win.eo b/src/lib/elementary/efl_ui_win.eo
index b8c9ab47bc..0b5255030f 100644
--- a/src/lib/elementary/efl_ui_win.eo
+++ b/src/lib/elementary/efl_ui_win.eo
@@ -811,9 +811,9 @@ class Efl.Ui.Win (Elm.Widget, Efl.Canvas, Elm.Interface.Atspi.Window,
Efl.Object.finalize;
Efl.Gfx.visible.set;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
- Efl.Canvas.Group.group_resize;
Elm.Widget.focus_direction;
Elm.Widget.focus_next_manager_is;
Elm.Widget.focus_direction_manager_is;
diff --git a/src/lib/elementary/elc_combobox.c b/src/lib/elementary/elc_combobox.c
index 2af16e2ba6..6026ce9e35 100644
--- a/src/lib/elementary/elc_combobox.c
+++ b/src/lib/elementary/elc_combobox.c
@@ -529,10 +529,12 @@ _elm_combobox_elm_widget_part_text_get(Eo *obj EINA_UNUSED, Elm_Combobox_Data *p
}
EOLIAN static void
-_elm_combobox_efl_canvas_group_group_resize(Eo *obj, Elm_Combobox_Data *pd,
- Evas_Coord w, Evas_Coord h)
+_elm_combobox_efl_gfx_size_set(Eo *obj, Elm_Combobox_Data *pd, Evas_Coord w, Evas_Coord h)
{
- efl_canvas_group_resize(efl_super(obj, MY_CLASS), w, h);
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
+
if (pd->count > 0) _table_resize(obj);
+ efl_gfx_size_set(efl_super(obj, MY_CLASS), w, h);
}
#include "elm_combobox.eo.c"
diff --git a/src/lib/elementary/elm_combobox.eo b/src/lib/elementary/elm_combobox.eo
index 66f60a6f47..9302421fd5 100644
--- a/src/lib/elementary/elm_combobox.eo
+++ b/src/lib/elementary/elm_combobox.eo
@@ -37,9 +37,9 @@ class Elm.Combobox (Elm.Button, Efl.Ui.Selectable,
class.constructor;
Efl.Object.constructor;
Efl.Gfx.visible.set;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
- Efl.Canvas.Group.group_resize;
Elm.Widget.part_text.set;
Elm.Widget.part_text.get;
Elm.Widget.theme_apply;
diff --git a/src/lib/elementary/elm_diskselector.c b/src/lib/elementary/elm_diskselector.c
index 8d4da071b8..8d8f29cf51 100644
--- a/src/lib/elementary/elm_diskselector.c
+++ b/src/lib/elementary/elm_diskselector.c
@@ -1432,11 +1432,14 @@ _elm_diskselector_efl_gfx_position_set(Eo *obj, Elm_Diskselector_Data *sd, Evas_
}
EOLIAN static void
-_elm_diskselector_efl_canvas_group_group_resize(Eo *obj, Elm_Diskselector_Data *sd, Evas_Coord w, Evas_Coord h)
+_elm_diskselector_efl_gfx_size_set(Eo *obj, Elm_Diskselector_Data *sd, Evas_Coord w, Evas_Coord h)
{
- efl_canvas_group_resize(efl_super(obj, MY_CLASS), w, h);
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
evas_object_resize(sd->hit_rect, w, h);
+
+ efl_gfx_size_set(efl_super(obj, MY_CLASS), w, h);
}
EOLIAN static void
diff --git a/src/lib/elementary/elm_diskselector.eo b/src/lib/elementary/elm_diskselector.eo
index 0b20ec6cea..54cf42281d 100644
--- a/src/lib/elementary/elm_diskselector.eo
+++ b/src/lib/elementary/elm_diskselector.eo
@@ -198,10 +198,10 @@ class Elm.Diskselector (Elm.Widget, Elm.Interface_Scrollable,
class.constructor;
Efl.Object.constructor;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_member_add;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
- Efl.Canvas.Group.group_resize;
Elm.Widget.focus_next_manager_is;
Elm.Widget.access;
Elm.Widget.focus_next;
diff --git a/src/lib/elementary/elm_entry.c b/src/lib/elementary/elm_entry.c
index 85c039db35..2f5e353ae1 100644
--- a/src/lib/elementary/elm_entry.c
+++ b/src/lib/elementary/elm_entry.c
@@ -3929,13 +3929,16 @@ _elm_entry_efl_gfx_position_set(Eo *obj, Elm_Entry_Data *sd, Evas_Coord x, Evas_
}
EOLIAN static void
-_elm_entry_efl_canvas_group_group_resize(Eo *obj, Elm_Entry_Data *sd, Evas_Coord w, Evas_Coord h)
+_elm_entry_efl_gfx_size_set(Eo *obj, Elm_Entry_Data *sd, Evas_Coord w, Evas_Coord h)
{
- efl_canvas_group_resize(efl_super(obj, MY_CLASS), w, h);
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
evas_object_resize(sd->hit_rect, w, h);
if (sd->have_selection)
_update_selection_handler(obj);
+
+ efl_gfx_size_set(efl_super(obj, MY_CLASS), w, h);
}
EOLIAN static void
diff --git a/src/lib/elementary/elm_entry.eo b/src/lib/elementary/elm_entry.eo
index 2bd3b1f1b7..3a0aaa28f4 100644
--- a/src/lib/elementary/elm_entry.eo
+++ b/src/lib/elementary/elm_entry.eo
@@ -941,9 +941,9 @@ class Elm.Entry (Elm.Layout, Elm.Interface_Scrollable, Efl.Ui.Clickable,
Efl.Object.constructor;
Efl.Gfx.visible.set;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_member_add;
Efl.Canvas.Group.group_add;
- Efl.Canvas.Group.group_resize;
Efl.Canvas.Group.group_del;
Elm.Widget.activate;
Elm.Widget.focus_direction_manager_is;
diff --git a/src/lib/elementary/elm_gengrid.c b/src/lib/elementary/elm_gengrid.c
index 27e06ceb02..90fc7fab8a 100644
--- a/src/lib/elementary/elm_gengrid.c
+++ b/src/lib/elementary/elm_gengrid.c
@@ -490,12 +490,13 @@ _elm_gengrid_pan_efl_gfx_position_set(Eo *obj, Elm_Gengrid_Pan_Data *psd, Evas_C
}
EOLIAN static void
-_elm_gengrid_pan_efl_canvas_group_group_resize(Eo *obj, Elm_Gengrid_Pan_Data *psd, Evas_Coord w, Evas_Coord h)
+_elm_gengrid_pan_efl_gfx_size_set(Eo *obj, Elm_Gengrid_Pan_Data *psd, Evas_Coord w, Evas_Coord h)
{
- Evas_Coord ow, oh;
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
+
+ efl_gfx_size_set(efl_super(obj, MY_CLASS), w, h);
- evas_object_geometry_get(obj, NULL, NULL, &ow, &oh);
- if ((ow == w) && (oh == h)) return;
ecore_job_del(psd->wsd->calc_job);
psd->wsd->calc_job = ecore_job_add(_calc_job, psd->wobj);
}
@@ -4347,11 +4348,13 @@ _elm_gengrid_efl_gfx_position_set(Eo *obj, Elm_Gengrid_Data *sd, Evas_Coord x, E
}
EOLIAN static void
-_elm_gengrid_efl_canvas_group_group_resize(Eo *obj, Elm_Gengrid_Data *sd, Evas_Coord w, Evas_Coord h)
+_elm_gengrid_efl_gfx_size_set(Eo *obj, Elm_Gengrid_Data *sd, Evas_Coord w, Evas_Coord h)
{
- efl_canvas_group_resize(efl_super(obj, MY_CLASS), w, h);
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
evas_object_resize(sd->hit_rect, w, h);
+ efl_gfx_size_set(efl_super(obj, MY_CLASS), w, h);
}
EOLIAN static void
diff --git a/src/lib/elementary/elm_gengrid.eo b/src/lib/elementary/elm_gengrid.eo
index 63baf6ff32..fc7231e286 100644
--- a/src/lib/elementary/elm_gengrid.eo
+++ b/src/lib/elementary/elm_gengrid.eo
@@ -541,10 +541,10 @@ class Elm.Gengrid (Elm.Layout, Elm.Interface_Scrollable,
class.constructor;
Efl.Object.constructor;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
Efl.Canvas.Group.group_member_add;
- Efl.Canvas.Group.group_resize;
Elm.Widget.theme_apply;
Elm.Widget.focus_next_manager_is;
Elm.Widget.focus_direction_manager_is;
diff --git a/src/lib/elementary/elm_gengrid_pan.eo b/src/lib/elementary/elm_gengrid_pan.eo
index 94ca804f2f..72a5ade975 100644
--- a/src/lib/elementary/elm_gengrid_pan.eo
+++ b/src/lib/elementary/elm_gengrid_pan.eo
@@ -7,8 +7,8 @@ class Elm.Gengrid.Pan (Elm.Pan)
class.constructor;
Efl.Object.destructor;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_calculate;
- Efl.Canvas.Group.group_resize;
Elm.Pan.content_size.get;
Elm.Pan.pos;
Elm.Pan.pos_min.get;
diff --git a/src/lib/elementary/elm_genlist.c b/src/lib/elementary/elm_genlist.c
index f75b263601..b0e8da810f 100644
--- a/src/lib/elementary/elm_genlist.c
+++ b/src/lib/elementary/elm_genlist.c
@@ -290,14 +290,16 @@ _elm_genlist_pan_smart_resize_job(void *data)
}
EOLIAN static void
-_elm_genlist_pan_efl_canvas_group_group_resize(Eo *obj, Elm_Genlist_Pan_Data *psd, Evas_Coord w, Evas_Coord h)
+_elm_genlist_pan_efl_gfx_size_set(Eo *obj, Elm_Genlist_Pan_Data *psd, Evas_Coord w, Evas_Coord h)
{
+ Elm_Genlist_Data *sd = psd->wsd;
Evas_Coord ow, oh;
- Elm_Genlist_Data *sd = psd->wsd;
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
- evas_object_geometry_get(obj, NULL, NULL, &ow, &oh);
- if ((ow == w) && (oh == h)) return;
+ efl_gfx_size_get(obj, &ow, &oh);
+ if ((ow == w) && (oh == h)) goto super; // should already be intercepted above
if ((sd->mode == ELM_LIST_COMPRESS) && (ow != w))
{
/* fix me later */
@@ -315,6 +317,9 @@ _elm_genlist_pan_efl_canvas_group_group_resize(Eo *obj, Elm_Genlist_Pan_Data *ps
sd->calc_job = ecore_job_add(_calc_job, psd->wobj);
else
sd->calc_job = NULL;
+
+super:
+ efl_gfx_size_set(efl_super(obj, MY_PAN_CLASS), w, h);
}
static void
@@ -5674,13 +5679,16 @@ _elm_genlist_efl_gfx_position_set(Eo *obj, Elm_Genlist_Data *sd, Evas_Coord x, E
}
EOLIAN static void
-_elm_genlist_efl_canvas_group_group_resize(Eo *obj, Elm_Genlist_Data *sd, Evas_Coord w, Evas_Coord h)
+_elm_genlist_efl_gfx_size_set(Eo *obj, Elm_Genlist_Data *sd, Evas_Coord w, Evas_Coord h)
{
- efl_canvas_group_resize(efl_super(obj, MY_CLASS), w, h);
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
evas_object_resize(sd->hit_rect, w, h);
if ((sd->queue) && (!sd->queue_idle_enterer) && (w > 0))
_requeue_idle_enterer(sd);
+
+ efl_gfx_size_set(efl_super(obj, MY_CLASS), w, h);
}
EOLIAN static void
diff --git a/src/lib/elementary/elm_genlist.eo b/src/lib/elementary/elm_genlist.eo
index cbdb18021f..97c7dd9960 100644
--- a/src/lib/elementary/elm_genlist.eo
+++ b/src/lib/elementary/elm_genlist.eo
@@ -529,10 +529,10 @@ class Elm.Genlist (Elm.Layout, Elm.Interface_Scrollable, Efl.Ui.Clickable,
class.constructor;
Efl.Object.constructor;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_member_add;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
- Efl.Canvas.Group.group_resize;
Elm.Widget.theme_apply;
Elm.Widget.focus_next_manager_is;
Elm.Widget.sub_object_add;
diff --git a/src/lib/elementary/elm_genlist_pan.eo b/src/lib/elementary/elm_genlist_pan.eo
index f773328014..bc9a9b4eec 100644
--- a/src/lib/elementary/elm_genlist_pan.eo
+++ b/src/lib/elementary/elm_genlist_pan.eo
@@ -7,9 +7,9 @@ class Elm.Genlist.Pan (Elm.Pan)
class.constructor;
Efl.Object.destructor;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_calculate;
Efl.Canvas.Group.group_del;
- Efl.Canvas.Group.group_resize;
Elm.Pan.content_size.get;
Elm.Pan.pos;
Elm.Pan.pos_min.get;
diff --git a/src/lib/elementary/elm_glview.c b/src/lib/elementary/elm_glview.c
index ff98a271e1..966295ebdb 100644
--- a/src/lib/elementary/elm_glview.c
+++ b/src/lib/elementary/elm_glview.c
@@ -86,9 +86,12 @@ _glview_update_surface(Evas_Object *obj)
}
EOLIAN static void
-_elm_glview_efl_canvas_group_group_resize(Eo *obj, Elm_Glview_Data *sd, Evas_Coord w, Evas_Coord h)
+_elm_glview_efl_gfx_size_set(Eo *obj, Elm_Glview_Data *sd, Evas_Coord w, Evas_Coord h)
{
- efl_canvas_group_resize(efl_super(obj, MY_CLASS), w, h);
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
+
+ efl_gfx_size_set(efl_super(obj, MY_CLASS), w, h);
sd->resized = EINA_TRUE;
@@ -100,8 +103,6 @@ _elm_glview_efl_canvas_group_group_resize(Eo *obj, Elm_Glview_Data *sd, Evas_Coo
h = 64;
}
- if ((sd->w == w) && (sd->h == h)) return;
-
sd->w = w;
sd->h = h;
diff --git a/src/lib/elementary/elm_glview.eo b/src/lib/elementary/elm_glview.eo
index 54d8143a51..d50a8ae89a 100644
--- a/src/lib/elementary/elm_glview.eo
+++ b/src/lib/elementary/elm_glview.eo
@@ -188,9 +188,9 @@ class Elm.Glview (Elm.Widget, Efl.Gfx.View)
implements {
class.constructor;
Efl.Object.finalize;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
- Efl.Canvas.Group.group_resize;
Elm.Widget.on_focus;
Efl.Gfx.View.view_size.get;
Efl.Gfx.View.view_size.set;
diff --git a/src/lib/elementary/elm_hover.c b/src/lib/elementary/elm_hover.c
index 0c8fa72682..eacfb1472c 100644
--- a/src/lib/elementary/elm_hover.c
+++ b/src/lib/elementary/elm_hover.c
@@ -627,9 +627,12 @@ _elm_hover_efl_gfx_position_set(Eo *obj, Elm_Hover_Data *_pd EINA_UNUSED, Evas_C
}
EOLIAN static void
-_elm_hover_efl_canvas_group_group_resize(Eo *obj, Elm_Hover_Data *_pd EINA_UNUSED, Evas_Coord w, Evas_Coord h)
+_elm_hover_efl_gfx_size_set(Eo *obj, Elm_Hover_Data *_pd EINA_UNUSED, Evas_Coord w, Evas_Coord h)
{
- efl_canvas_group_resize(efl_super(obj, MY_CLASS), w, h);
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
+
+ efl_gfx_size_set(efl_super(obj, MY_CLASS), w, h);
elm_layout_sizing_eval(obj);
}
diff --git a/src/lib/elementary/elm_hover.eo b/src/lib/elementary/elm_hover.eo
index 47caaabc63..a01ea229d7 100644
--- a/src/lib/elementary/elm_hover.eo
+++ b/src/lib/elementary/elm_hover.eo
@@ -62,9 +62,9 @@ class Elm.Hover (Elm.Layout, Efl.Ui.Clickable, Elm.Interface.Atspi_Widget_Action
Efl.Object.constructor;
Efl.Gfx.visible.set;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_del;
Efl.Canvas.Group.group_add;
- Efl.Canvas.Group.group_resize;
Elm.Widget.theme_apply;
Elm.Widget.sub_object_add;
Elm.Widget.widget_parent;
diff --git a/src/lib/elementary/elm_interface_scrollable.c b/src/lib/elementary/elm_interface_scrollable.c
index f6b1623077..8d22b544c6 100644
--- a/src/lib/elementary/elm_interface_scrollable.c
+++ b/src/lib/elementary/elm_interface_scrollable.c
@@ -116,8 +116,13 @@ _elm_pan_efl_gfx_position_set(Eo *obj, Elm_Pan_Smart_Data *psd, Evas_Coord x, Ev
}
EOLIAN static void
-_elm_pan_efl_canvas_group_group_resize(Eo *obj EINA_UNUSED, Elm_Pan_Smart_Data *psd, Evas_Coord w, Evas_Coord h)
+_elm_pan_efl_gfx_size_set(Eo *obj EINA_UNUSED, Elm_Pan_Smart_Data *psd, Evas_Coord w, Evas_Coord h)
{
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
+
+ efl_gfx_size_set(efl_super(obj, MY_PAN_CLASS), w, h);
+
psd->w = w;
psd->h = h;
diff --git a/src/lib/elementary/elm_list.c b/src/lib/elementary/elm_list.c
index dc8e9b7ba9..8f2ca840f8 100644
--- a/src/lib/elementary/elm_list.c
+++ b/src/lib/elementary/elm_list.c
@@ -2520,9 +2520,12 @@ _elm_list_efl_gfx_position_set(Eo *obj, Elm_List_Data *sd, Evas_Coord x, Evas_Co
}
EOLIAN static void
-_elm_list_efl_canvas_group_group_resize(Eo *obj, Elm_List_Data *sd, Evas_Coord w, Evas_Coord h)
+_elm_list_efl_gfx_size_set(Eo *obj, Elm_List_Data *sd, Evas_Coord w, Evas_Coord h)
{
- efl_canvas_group_resize(efl_super(obj, MY_CLASS), w, h);
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
+
+ efl_gfx_size_set(efl_super(obj, MY_CLASS), w, h);
evas_object_resize(sd->hit_rect, w, h);
}
diff --git a/src/lib/elementary/elm_list.eo b/src/lib/elementary/elm_list.eo
index 273ca41270..3c55a83f52 100644
--- a/src/lib/elementary/elm_list.eo
+++ b/src/lib/elementary/elm_list.eo
@@ -430,10 +430,10 @@ class Elm.List (Elm.Layout, Elm.Interface_Scrollable,
class.constructor;
Efl.Object.constructor;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_member_add;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
- Efl.Canvas.Group.group_resize;
Elm.Widget.theme_apply;
Elm.Widget.focus_next_manager_is;
Elm.Widget.focus_direction_manager_is;
diff --git a/src/lib/elementary/elm_map.c b/src/lib/elementary/elm_map.c
index e600a21d32..1d57f5f070 100644
--- a/src/lib/elementary/elm_map.c
+++ b/src/lib/elementary/elm_map.c
@@ -3864,8 +3864,13 @@ _elm_map_pan_elm_pan_content_size_get(Eo *obj EINA_UNUSED, Elm_Map_Pan_Data *psd
}
EOLIAN static void
-_elm_map_pan_efl_canvas_group_group_resize(Eo *obj, Elm_Map_Pan_Data *psd, Evas_Coord w EINA_UNUSED, Evas_Coord h EINA_UNUSED)
+_elm_map_pan_efl_gfx_size_set(Eo *obj, Elm_Map_Pan_Data *psd, Evas_Coord w, Evas_Coord h)
{
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
+
+ efl_gfx_size_set(efl_super(obj, MY_PAN_CLASS), w, h);
+
_sizing_eval(psd->wsd->obj);
elm_map_zoom_mode_set(psd->wobj, psd->wsd->mode);
evas_object_smart_changed(obj);
@@ -4219,9 +4224,12 @@ _elm_map_efl_gfx_position_set(Eo *obj, Elm_Map_Data *sd, Evas_Coord x, Evas_Coor
}
EOLIAN static void
-_elm_map_efl_canvas_group_group_resize(Eo *obj, Elm_Map_Data *sd, Evas_Coord w, Evas_Coord h)
+_elm_map_efl_gfx_size_set(Eo *obj, Elm_Map_Data *sd, Evas_Coord w, Evas_Coord h)
{
- efl_canvas_group_resize(efl_super(obj, MY_CLASS), w, h);
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
+
+ efl_gfx_size_set(efl_super(obj, MY_CLASS), w, h);
evas_object_resize(sd->hit_rect, w, h);
}
diff --git a/src/lib/elementary/elm_map.eo b/src/lib/elementary/elm_map.eo
index 9267b35f9e..d47e046159 100644
--- a/src/lib/elementary/elm_map.eo
+++ b/src/lib/elementary/elm_map.eo
@@ -627,10 +627,10 @@ class Elm.Map (Elm.Widget, Elm.Interface_Scrollable,
class.constructor;
Efl.Object.constructor;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
Efl.Canvas.Group.group_member_add;
- Efl.Canvas.Group.group_resize;
Elm.Widget.theme_apply;
Elm.Widget.on_focus;
Elm.Widget.event;
diff --git a/src/lib/elementary/elm_map_pan.eo b/src/lib/elementary/elm_map_pan.eo
index a073aafcf2..cbae0a077f 100644
--- a/src/lib/elementary/elm_map_pan.eo
+++ b/src/lib/elementary/elm_map_pan.eo
@@ -7,8 +7,8 @@ class Elm.Map.Pan (Elm.Pan)
class.constructor;
Efl.Object.destructor;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_calculate;
- Efl.Canvas.Group.group_resize;
Elm.Pan.content_size.get;
Elm.Pan.pos;
Elm.Pan.pos_min.get;
diff --git a/src/lib/elementary/elm_mapbuf.c b/src/lib/elementary/elm_mapbuf.c
index 2034e209c8..371c634088 100644
--- a/src/lib/elementary/elm_mapbuf.c
+++ b/src/lib/elementary/elm_mapbuf.c
@@ -169,9 +169,12 @@ _elm_mapbuf_efl_gfx_position_set(Eo *obj, Elm_Mapbuf_Data *sd, Evas_Coord x, Eva
}
EOLIAN static void
-_elm_mapbuf_efl_canvas_group_group_resize(Eo *obj, Elm_Mapbuf_Data *sd, Evas_Coord w, Evas_Coord h)
+_elm_mapbuf_efl_gfx_size_set(Eo *obj, Elm_Mapbuf_Data *sd, Evas_Coord w, Evas_Coord h)
{
- efl_canvas_group_resize(efl_super(obj, MY_CLASS), w, h);
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
+
+ efl_gfx_size_set(efl_super(obj, MY_CLASS), w, h);
if (sd->content) evas_object_resize(sd->content, w, h);
_mapbuf_auto_eval(obj, sd);
diff --git a/src/lib/elementary/elm_mapbuf.eo b/src/lib/elementary/elm_mapbuf.eo
index 24445109a7..62a47404d9 100644
--- a/src/lib/elementary/elm_mapbuf.eo
+++ b/src/lib/elementary/elm_mapbuf.eo
@@ -131,9 +131,9 @@ class Elm.Mapbuf (Elm.Widget, Efl.Container, Efl.Part)
Efl.Object.constructor;
Efl.Gfx.visible.set;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
- Efl.Canvas.Group.group_resize;
Elm.Widget.theme_apply;
Elm.Widget.sub_object_del;
Efl.Container.content.get;
diff --git a/src/lib/elementary/elm_notify.c b/src/lib/elementary/elm_notify.c
index 80ad35ef05..26aec380fb 100644
--- a/src/lib/elementary/elm_notify.c
+++ b/src/lib/elementary/elm_notify.c
@@ -226,15 +226,18 @@ _block_area_clicked_cb(void *data,
}
EOLIAN static void
-_elm_notify_efl_canvas_group_group_resize(Eo *obj, Elm_Notify_Data *sd, Evas_Coord w, Evas_Coord h)
+_elm_notify_efl_gfx_size_set(Eo *obj, Elm_Notify_Data *sd, Evas_Coord w, Evas_Coord h)
{
- Evas_Coord x, y;
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
- efl_canvas_group_resize(efl_super(obj, MY_CLASS), w, h);
+ efl_gfx_size_set(efl_super(obj, MY_CLASS), w, h);
if (!sd->parent && sd->content)
{
- evas_object_geometry_get(obj, &x, &y, NULL, NULL);
+ Evas_Coord x, y;
+
+ efl_gfx_position_get(obj, &x, &y);
_notify_move_to_orientation(obj, x, y, w, h);
}
}
diff --git a/src/lib/elementary/elm_notify.eo b/src/lib/elementary/elm_notify.eo
index 93148843d7..2deaa59484 100644
--- a/src/lib/elementary/elm_notify.eo
+++ b/src/lib/elementary/elm_notify.eo
@@ -81,9 +81,9 @@ class Elm.Notify (Elm.Widget, Efl.Container, Efl.Part)
Efl.Object.constructor;
Efl.Gfx.visible.set;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
- Efl.Canvas.Group.group_resize;
Elm.Widget.focus_direction;
Elm.Widget.widget_parent;
Elm.Widget.theme_apply;
diff --git a/src/lib/elementary/elm_pan.eo b/src/lib/elementary/elm_pan.eo
index d89fedf2f6..8628914718 100644
--- a/src/lib/elementary/elm_pan.eo
+++ b/src/lib/elementary/elm_pan.eo
@@ -45,9 +45,9 @@ class Elm.Pan (Efl.Canvas.Group.Clipped)
class.constructor;
Efl.Gfx.visible.set;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
- Efl.Canvas.Group.group_resize;
}
events {
changed;
diff --git a/src/lib/elementary/elm_panel.c b/src/lib/elementary/elm_panel.c
index 8eb079ceea..a8979aecaf 100644
--- a/src/lib/elementary/elm_panel.c
+++ b/src/lib/elementary/elm_panel.c
@@ -1108,9 +1108,12 @@ _elm_panel_efl_gfx_position_set(Eo *obj, Elm_Panel_Data *sd, Evas_Coord x, Evas_
}
EOLIAN static void
-_elm_panel_efl_canvas_group_group_resize(Eo *obj, Elm_Panel_Data *sd, Evas_Coord w, Evas_Coord h)
+_elm_panel_efl_gfx_size_set(Eo *obj, Elm_Panel_Data *sd, Evas_Coord w, Evas_Coord h)
{
- efl_canvas_group_resize(efl_super(obj, MY_CLASS), w, h);
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
+
+ efl_gfx_size_set(efl_super(obj, MY_CLASS), w, h);
if (!sd->scrollable) return;
diff --git a/src/lib/elementary/elm_panel.eo b/src/lib/elementary/elm_panel.eo
index 41fab5d43a..3ec22852b7 100644
--- a/src/lib/elementary/elm_panel.eo
+++ b/src/lib/elementary/elm_panel.eo
@@ -70,10 +70,10 @@ class Elm.Panel (Elm.Layout, Elm.Interface_Scrollable,
class.constructor;
Efl.Object.constructor;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_member_add;
Efl.Canvas.Group.group_del;
- Efl.Canvas.Group.group_resize;
Elm.Widget.theme_apply;
Elm.Widget.focus_next_manager_is;
Elm.Widget.focus_next;
diff --git a/src/lib/elementary/elm_photocam.c b/src/lib/elementary/elm_photocam.c
index e5e987150d..840f0833b0 100644
--- a/src/lib/elementary/elm_photocam.c
+++ b/src/lib/elementary/elm_photocam.c
@@ -157,12 +157,12 @@ _elm_photocam_pan_efl_gfx_position_set(Eo *obj, Elm_Photocam_Pan_Data *psd, Evas
}
EOLIAN static void
-_elm_photocam_pan_efl_canvas_group_group_resize(Eo *obj, Elm_Photocam_Pan_Data *psd, Evas_Coord w, Evas_Coord h)
+_elm_photocam_pan_efl_gfx_size_set(Eo *obj, Elm_Photocam_Pan_Data *psd, Evas_Coord w, Evas_Coord h)
{
- Evas_Coord ow, oh;
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
- evas_object_geometry_get(obj, NULL, NULL, &ow, &oh);
- if ((ow == w) && (oh == h)) return;
+ efl_gfx_size_set(efl_super(obj, MY_PAN_CLASS), w, h);
psd->wsd->resized = EINA_TRUE;
ecore_job_del(psd->wsd->calc_job);
@@ -1491,9 +1491,12 @@ _elm_photocam_efl_gfx_position_set(Eo *obj, Elm_Photocam_Data *sd, Evas_Coord x,
}
EOLIAN static void
-_elm_photocam_efl_canvas_group_group_resize(Eo *obj, Elm_Photocam_Data *sd, Evas_Coord w, Evas_Coord h)
+_elm_photocam_efl_gfx_size_set(Eo *obj, Elm_Photocam_Data *sd, Evas_Coord w, Evas_Coord h)
{
- efl_canvas_group_resize(efl_super(obj, MY_CLASS), w, h);
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
+
+ efl_gfx_size_set(efl_super(obj, MY_CLASS), w, h);
evas_object_resize(sd->hit_rect, w, h);
}
diff --git a/src/lib/elementary/elm_photocam.eo b/src/lib/elementary/elm_photocam.eo
index c04bc2ab58..ebf0e13e56 100644
--- a/src/lib/elementary/elm_photocam.eo
+++ b/src/lib/elementary/elm_photocam.eo
@@ -190,10 +190,10 @@ class Elm.Photocam (Elm.Widget, Elm.Interface_Scrollable,
class.constructor;
Efl.Object.constructor;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
Efl.Canvas.Group.group_member_add;
- Efl.Canvas.Group.group_resize;
Elm.Widget.theme_apply;
Elm.Widget.on_focus;
Elm.Widget.event;
diff --git a/src/lib/elementary/elm_photocam_pan.eo b/src/lib/elementary/elm_photocam_pan.eo
index c3fcda1de7..57d1d455f3 100644
--- a/src/lib/elementary/elm_photocam_pan.eo
+++ b/src/lib/elementary/elm_photocam_pan.eo
@@ -7,8 +7,8 @@ class Elm.Photocam.Pan (Elm.Pan)
class.constructor;
Efl.Object.destructor;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_calculate;
- Efl.Canvas.Group.group_resize;
Elm.Pan.content_size.get;
Elm.Pan.pos;
Elm.Pan.pos_min.get;
diff --git a/src/lib/elementary/elm_scroller.c b/src/lib/elementary/elm_scroller.c
index 371d893c6a..6e64b28262 100644
--- a/src/lib/elementary/elm_scroller.c
+++ b/src/lib/elementary/elm_scroller.c
@@ -930,9 +930,12 @@ _elm_scroller_efl_gfx_position_set(Eo *obj, Elm_Scroller_Data *sd, Evas_Coord x,
}
EOLIAN static void
-_elm_scroller_efl_canvas_group_group_resize(Eo *obj, Elm_Scroller_Data *sd, Evas_Coord w, Evas_Coord h)
+_elm_scroller_efl_gfx_size_set(Eo *obj, Elm_Scroller_Data *sd, Evas_Coord w, Evas_Coord h)
{
- efl_canvas_group_resize(efl_super(obj, MY_CLASS), w, h);
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
+
+ efl_gfx_size_set(efl_super(obj, MY_CLASS), w, h);
evas_object_resize(sd->hit_rect, w, h);
}
diff --git a/src/lib/elementary/elm_scroller.eo b/src/lib/elementary/elm_scroller.eo
index b8d2ee776c..8b9fe469f2 100644
--- a/src/lib/elementary/elm_scroller.eo
+++ b/src/lib/elementary/elm_scroller.eo
@@ -61,9 +61,9 @@ class Elm.Scroller (Elm.Layout, Elm.Interface_Scrollable,
class.constructor;
Efl.Object.constructor;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_member_add;
- Efl.Canvas.Group.group_resize;
Elm.Widget.theme_apply;
Elm.Widget.activate;
Elm.Widget.focus_next_manager_is;
diff --git a/src/lib/elementary/elm_toolbar.c b/src/lib/elementary/elm_toolbar.c
index 0b96c5c207..cbeaddc602 100644
--- a/src/lib/elementary/elm_toolbar.c
+++ b/src/lib/elementary/elm_toolbar.c
@@ -2946,9 +2946,12 @@ _elm_toolbar_efl_gfx_position_set(Eo *obj, Elm_Toolbar_Data *sd, Evas_Coord x, E
}
EOLIAN static void
-_elm_toolbar_efl_canvas_group_group_resize(Eo *obj, Elm_Toolbar_Data *sd, Evas_Coord w, Evas_Coord h)
+_elm_toolbar_efl_gfx_size_set(Eo *obj, Elm_Toolbar_Data *sd, Evas_Coord w, Evas_Coord h)
{
- efl_canvas_group_resize(efl_super(obj, MY_CLASS), w, h);
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
+
+ efl_gfx_size_set(efl_super(obj, MY_CLASS), w, h);
evas_object_resize(sd->hit_rect, w, h);
}
diff --git a/src/lib/elementary/elm_toolbar.eo b/src/lib/elementary/elm_toolbar.eo
index 1c961fcc44..783899bd77 100644
--- a/src/lib/elementary/elm_toolbar.eo
+++ b/src/lib/elementary/elm_toolbar.eo
@@ -346,11 +346,11 @@ class Elm.Toolbar (Elm.Widget, Elm.Interface_Scrollable, Efl.Orientation,
class.constructor;
Efl.Object.constructor;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_calculate;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
Efl.Canvas.Group.group_member_add;
- Efl.Canvas.Group.group_resize;
Elm.Widget.focus_next_manager_is;
Elm.Widget.access;
Elm.Widget.focus_next;
diff --git a/src/lib/elementary/elm_widget.c b/src/lib/elementary/elm_widget.c
index 292fc3e933..172d014540 100644
--- a/src/lib/elementary/elm_widget.c
+++ b/src/lib/elementary/elm_widget.c
@@ -506,21 +506,24 @@ _elm_widget_efl_gfx_position_set(Eo *obj EINA_UNUSED, Elm_Widget_Smart_Data *sd,
if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_MOVE, 0, x, y))
return;
- efl_gfx_position_set(efl_super(obj, MY_CLASS), x, y);
-
sd->x = x;
sd->y = y;
-
_smart_reconfigure(sd);
+
+ efl_gfx_position_set(efl_super(obj, MY_CLASS), x, y);
}
EOLIAN static void
-_elm_widget_efl_canvas_group_group_resize(Eo *obj EINA_UNUSED, Elm_Widget_Smart_Data *sd, Evas_Coord w, Evas_Coord h)
+_elm_widget_efl_gfx_size_set(Eo *obj EINA_UNUSED, Elm_Widget_Smart_Data *sd, Evas_Coord w, Evas_Coord h)
{
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
+
sd->w = w;
sd->h = h;
-
_smart_reconfigure(sd);
+
+ efl_gfx_size_set(efl_super(obj, MY_CLASS), w, h);
}
EOLIAN static void
diff --git a/src/lib/elementary/elm_widget.eo b/src/lib/elementary/elm_widget.eo
index bab0e4fafe..fc296d44f2 100644
--- a/src/lib/elementary/elm_widget.eo
+++ b/src/lib/elementary/elm_widget.eo
@@ -850,6 +850,7 @@ abstract Elm.Widget (Efl.Canvas.Group, Elm.Interface.Atspi_Accessible, Elm.Inter
Efl.Gfx.color.set;
Efl.Gfx.visible.set;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Canvas.Object.clip.set;
Efl.Canvas.Object.no_render.set;
Efl.Canvas.Group.group_calculate;
@@ -857,7 +858,6 @@ abstract Elm.Widget (Efl.Canvas.Group, Elm.Interface.Atspi_Accessible, Elm.Inter
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
Efl.Canvas.Group.group_member_add;
- Efl.Canvas.Group.group_resize;
Elm.Interface.Atspi_Accessible.name.get;
Elm.Interface.Atspi_Accessible.state_set.get;
Elm.Interface.Atspi_Accessible.children.get;
diff --git a/src/lib/emotion/efl_canvas_video.eo b/src/lib/emotion/efl_canvas_video.eo
index fb9b96d4ae..9715347def 100644
--- a/src/lib/emotion/efl_canvas_video.eo
+++ b/src/lib/emotion/efl_canvas_video.eo
@@ -54,10 +54,10 @@ class Efl.Canvas.Video (Efl.Canvas.Group, Efl.File, Efl.Player, Efl.Image, Efl.I
Efl.Gfx.color.set;
Efl.Gfx.visible.set;
Efl.Gfx.position.set;
+ Efl.Gfx.size.set;
Efl.Canvas.Object.clip.set;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
- Efl.Canvas.Group.group_resize;
Efl.File.file.set;
Efl.File.file.get;
Efl.Player.play.set;
diff --git a/src/lib/emotion/emotion_smart.c b/src/lib/emotion/emotion_smart.c
index 266473905c..9b0338d1d3 100644
--- a/src/lib/emotion/emotion_smart.c
+++ b/src/lib/emotion/emotion_smart.c
@@ -1944,8 +1944,13 @@ _efl_canvas_video_efl_gfx_position_set(Evas_Object *obj, Efl_Canvas_Video_Data *
}
EOLIAN static void
-_efl_canvas_video_efl_canvas_group_group_resize(Evas_Object *obj, Efl_Canvas_Video_Data *sd, Evas_Coord w, Evas_Coord h)
+_efl_canvas_video_efl_gfx_size_set(Evas_Object *obj, Efl_Canvas_Video_Data *sd, Evas_Coord w, Evas_Coord h)
{
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
+
+ efl_gfx_size_set(efl_super(obj, MY_CLASS), w, h);
+
_efl_canvas_video_aspect_border_apply(obj, sd, w, h);
evas_object_resize(sd->bg, w, h);
}
diff --git a/src/lib/evas/canvas/efl_canvas_group.eo b/src/lib/evas/canvas/efl_canvas_group.eo
index 1649fa145d..a55d83fd74 100644
--- a/src/lib/evas/canvas/efl_canvas_group.eo
+++ b/src/lib/evas/canvas/efl_canvas_group.eo
@@ -92,14 +92,6 @@ class Efl.Canvas.Group (Efl.Canvas.Object)
}
legacy: null;
}
- group_resize {
- [[No description supplied by the EAPI.]]
- legacy: null;
- params {
- @in w: Evas.Coord;
- @in h: Evas.Coord;
- }
- }
group_member_del {
[[Removes a member object from a given smart object.
diff --git a/src/lib/evas/canvas/evas_box.eo b/src/lib/evas/canvas/evas_box.eo
index 26b04c39d7..66fdb40cc8 100644
--- a/src/lib/evas/canvas/evas_box.eo
+++ b/src/lib/evas/canvas/evas_box.eo
@@ -657,10 +657,10 @@ class Evas.Box (Efl.Canvas.Group.Clipped)
implements {
class.constructor;
Efl.Object.constructor;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_calculate;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
- Efl.Canvas.Group.group_resize;
}
events {
child,added;
diff --git a/src/lib/evas/canvas/evas_object_box.c b/src/lib/evas/canvas/evas_object_box.c
index 051c5e5cb1..f2b2f9b4e9 100644
--- a/src/lib/evas/canvas/evas_object_box.c
+++ b/src/lib/evas/canvas/evas_object_box.c
@@ -424,11 +424,12 @@ _evas_box_efl_canvas_group_group_del(Eo *o, Evas_Object_Box_Data *priv)
}
EOLIAN static void
-_evas_box_efl_canvas_group_group_resize(Eo *o, Evas_Object_Box_Data *_pd EINA_UNUSED, Evas_Coord w, Evas_Coord h)
+_evas_box_efl_gfx_size_set(Eo *o, Evas_Object_Box_Data *_pd EINA_UNUSED, Evas_Coord w, Evas_Coord h)
{
- Evas_Coord ow, oh;
- evas_object_geometry_get(o, NULL, NULL, &ow, &oh);
- if ((ow == w) && (oh == h)) return;
+ if (_evas_object_intercept_call(o, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
+
+ efl_gfx_size_set(efl_super(o, MY_CLASS), w, h);
evas_object_smart_changed(o);
}
diff --git a/src/lib/evas/canvas/evas_object_intercept.c b/src/lib/evas/canvas/evas_object_intercept.c
index f653f02d9a..13b9a9697e 100644
--- a/src/lib/evas/canvas/evas_object_intercept.c
+++ b/src/lib/evas/canvas/evas_object_intercept.c
@@ -126,10 +126,15 @@ _evas_object_intercept_call(Evas_Object *eo_obj, Evas_Object_Intercept_Cb_Type c
break;
case EVAS_OBJECT_INTERCEPT_CB_RESIZE:
- if (!obj->interceptors) return 0;
va_start(args, internal);
i = va_arg(args, int);
j = va_arg(args, int);
+ if (!internal)
+ {
+ if (_efl_canvas_object_efl_gfx_size_set_block(eo_obj, obj, i, j))
+ goto end_block;
+ }
+ if (!obj->interceptors) goto end_noblock;
blocked = evas_object_intercept_call_resize(eo_obj, obj, i, j);
break;
diff --git a/src/lib/evas/canvas/evas_object_main.c b/src/lib/evas/canvas/evas_object_main.c
index 4a3c2d233c..20b7798339 100644
--- a/src/lib/evas/canvas/evas_object_main.c
+++ b/src/lib/evas/canvas/evas_object_main.c
@@ -865,6 +865,26 @@ evas_object_resize(Evas_Object *obj, Evas_Coord w, Evas_Coord h)
efl_gfx_size_set((Evas_Object *)obj, w, h);
}
+Eina_Bool
+_efl_canvas_object_efl_gfx_size_set_block(Eo *eo_obj, Evas_Object_Protected_Data *obj,
+ Evas_Coord w, Evas_Coord h)
+{
+ if (obj->doing.in_resize > 0)
+ {
+ WRN("evas_object_resize() called on object %p (%s) when in the middle "
+ "of resizing the same object", eo_obj, efl_class_name_get(eo_obj));
+ return EINA_TRUE;
+ }
+
+ if (w < 0) w = 0;
+ if (h < 0) h = 0;
+
+ if ((obj->cur->geometry.w == w) && (obj->cur->geometry.h == h))
+ return EINA_TRUE;
+
+ return EINA_FALSE;
+}
+
EOLIAN static void
_efl_canvas_object_efl_gfx_size_set(Eo *eo_obj, Evas_Object_Protected_Data *obj,
Evas_Coord w, Evas_Coord h)
@@ -873,21 +893,11 @@ _efl_canvas_object_efl_gfx_size_set(Eo *eo_obj, Evas_Object_Protected_Data *obj,
Eina_Bool pass = EINA_FALSE, freeze = EINA_FALSE;
Eina_Bool source_invisible = EINA_FALSE;
- if (obj->delete_me) return;
- if (!obj->layer) return;
if (w < 0) w = 0;
if (h < 0) h = 0;
- evas_object_async_block(obj);
- if (_evas_object_intercept_call(eo_obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 1, w, h)) return;
-
- if (obj->doing.in_resize > 0)
- {
- WRN("evas_object_resize() called on object %p when in the middle of resizing the same object", obj);
- return;
- }
-
- if ((obj->cur->geometry.w == w) && (obj->cur->geometry.h == h)) return;
+ if (_evas_object_intercept_call(eo_obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 1, w, h))
+ return;
if (!(obj->layer->evas->is_frozen))
{
@@ -901,10 +911,8 @@ _efl_canvas_object_efl_gfx_size_set(Eo *eo_obj, Evas_Object_Protected_Data *obj,
}
obj->doing.in_resize++;
- if (obj->is_smart)
- {
- efl_canvas_group_resize(eo_obj, w, h);
- }
+ if (obj->is_smart && obj->smart.smart && obj->smart.smart->smart_class->resize)
+ obj->smart.smart->smart_class->resize(eo_obj, w, h);
EINA_COW_STATE_WRITE_BEGIN(obj, state_write, cur)
{
diff --git a/src/lib/evas/canvas/evas_object_smart.c b/src/lib/evas/canvas/evas_object_smart.c
index 359de50e7f..af9472d274 100644
--- a/src/lib/evas/canvas/evas_object_smart.c
+++ b/src/lib/evas/canvas/evas_object_smart.c
@@ -632,16 +632,6 @@ _efl_canvas_group_group_del(Eo *eo_obj EINA_UNUSED, Evas_Smart_Data *o EINA_UNUS
}
EOLIAN static void
-_efl_canvas_group_group_resize(Eo *eo_obj, Evas_Smart_Data *o EINA_UNUSED, Evas_Coord w, Evas_Coord h)
-{
- // 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->resize) s->smart_class->resize(eo_obj, w, h);
-}
-
-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;
diff --git a/src/lib/evas/canvas/evas_object_table.c b/src/lib/evas/canvas/evas_object_table.c
index d294ba5644..e8b1351dde 100644
--- a/src/lib/evas/canvas/evas_object_table.c
+++ b/src/lib/evas/canvas/evas_object_table.c
@@ -930,11 +930,12 @@ _evas_table_efl_canvas_group_group_del(Eo *obj, Evas_Table_Data *priv)
}
EOLIAN static void
-_evas_table_efl_canvas_group_group_resize(Eo *obj, Evas_Table_Data *_pd EINA_UNUSED, Evas_Coord w, Evas_Coord h)
+_evas_table_efl_gfx_size_set(Eo *obj, Evas_Table_Data *_pd EINA_UNUSED, Evas_Coord w, Evas_Coord h)
{
- Evas_Coord ow, oh;
- evas_object_geometry_get(obj, NULL, NULL, &ow, &oh);
- if ((ow == w) && (oh == h)) return;
+ if (_evas_object_intercept_call(obj, EVAS_OBJECT_INTERCEPT_CB_RESIZE, 0, w, h))
+ return;
+
+ efl_gfx_size_set(efl_super(obj, MY_CLASS), w, h);
evas_object_smart_changed(obj);
}
diff --git a/src/lib/evas/canvas/evas_table.eo b/src/lib/evas/canvas/evas_table.eo
index 6fd473f7a1..7932ec7cb9 100644
--- a/src/lib/evas/canvas/evas_table.eo
+++ b/src/lib/evas/canvas/evas_table.eo
@@ -216,9 +216,9 @@ class Evas.Table (Efl.Canvas.Group.Clipped)
implements {
class.constructor;
Efl.Object.constructor;
+ Efl.Gfx.size.set;
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
Efl.Canvas.Group.group_calculate;
- Efl.Canvas.Group.group_resize;
}
}
diff --git a/src/lib/evas/include/evas_private.h b/src/lib/evas/include/evas_private.h
index 91602d96c8..775b05a7f1 100644
--- a/src/lib/evas/include/evas_private.h
+++ b/src/lib/evas/include/evas_private.h
@@ -1654,6 +1654,7 @@ void _efl_canvas_object_clip_prev_reset(Evas_Object_Protected_Data *obj, Eina_Bo
Eina_Bool _efl_canvas_object_clip_set_block(Eo *eo_obj, Evas_Object_Protected_Data *obj, Evas_Object *eo_clip, Evas_Object_Protected_Data *clip);
Eina_Bool _efl_canvas_object_clip_unset_block(Eo *eo_obj, Evas_Object_Protected_Data *obj);
+Eina_Bool _efl_canvas_object_efl_gfx_size_set_block(Eo *eo_obj, Evas_Object_Protected_Data *obj, Evas_Coord w, Evas_Coord h);
void _canvas_event_default_flags_set(Eo *e, void *_pd, va_list *list);
void _canvas_event_default_flags_get(Eo *e, void *_pd, va_list *list);