forked from enlightenment/efl
the min size of the box is the sum of the items min size
SVN revision: 50156
This commit is contained in:
parent
6d4c38f97b
commit
d97c0b0a9a
|
@ -26,6 +26,9 @@ struct _Evas_Object_Box_Accessor
|
||||||
|
|
||||||
static const char _evas_object_box_type[] = "Evas_Object_Box";
|
static const char _evas_object_box_type[] = "Evas_Object_Box";
|
||||||
|
|
||||||
|
|
||||||
|
static void _sizing_eval(Evas_Object *obj);
|
||||||
|
|
||||||
#define EVAS_OBJECT_BOX_DATA_GET(o, ptr) \
|
#define EVAS_OBJECT_BOX_DATA_GET(o, ptr) \
|
||||||
Evas_Object_Box_Data *ptr = evas_object_smart_data_get(o)
|
Evas_Object_Box_Data *ptr = evas_object_smart_data_get(o)
|
||||||
|
|
||||||
|
@ -139,6 +142,12 @@ _on_child_hints_changed(void *data, Evas *evas __UNUSED__, Evas_Object *o __UNUS
|
||||||
if (!priv->layouting) evas_object_smart_changed(box);
|
if (!priv->layouting) evas_object_smart_changed(box);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void
|
||||||
|
_on_hints_changed(void *data __UNUSED__, Evas *evas __UNUSED__, Evas_Object *o , void *einfo __UNUSED__)
|
||||||
|
{
|
||||||
|
_sizing_eval(o);
|
||||||
|
}
|
||||||
|
|
||||||
static Evas_Object_Box_Option *
|
static Evas_Object_Box_Option *
|
||||||
_evas_object_box_option_new(Evas_Object *o, Evas_Object_Box_Data *priv, Evas_Object *child)
|
_evas_object_box_option_new(Evas_Object *o, Evas_Object_Box_Data *priv, Evas_Object *child)
|
||||||
{
|
{
|
||||||
|
@ -425,6 +434,9 @@ _evas_object_box_smart_add(Evas_Object *o)
|
||||||
}
|
}
|
||||||
_evas_object_box_parent_sc->add(o);
|
_evas_object_box_parent_sc->add(o);
|
||||||
|
|
||||||
|
|
||||||
|
evas_object_event_callback_add
|
||||||
|
(o, EVAS_CALLBACK_CHANGED_SIZE_HINTS, _on_hints_changed, o);
|
||||||
priv->children = NULL;
|
priv->children = NULL;
|
||||||
priv->align.h = 0.5;
|
priv->align.h = 0.5;
|
||||||
priv->align.v = 0.5;
|
priv->align.v = 0.5;
|
||||||
|
|
Loading…
Reference in New Issue