elm_toolbar: add toolbar item size calculation and setting min values for fixed items

Summary:
In case of the toolbar item size is fixed, the size of toolbar item became finger size.
so, after signal emission in _inform_item_number(),
edje_object_size_min_restricted_calc() and evas_object_size_hint_min_set() function are added.

Test Plan: change edc for supporting fixed toolbar item and run examples of toolbar in elementary_test

Reviewers: woohyun, seoz, Hermet, raster

Reviewed By: raster

Differential Revision: https://phab.enlightenment.org/D2184
This commit is contained in:
taehyub 2015-03-25 07:47:33 +09:00 committed by Carsten Haitzler (Rasterman)
parent 8e47bbb70a
commit c361c9e839
1 changed files with 11 additions and 1 deletions

View File

@ -1299,6 +1299,7 @@ _inform_item_number(Evas_Object *obj)
char buf[sizeof("elm,number,item,") + 4];
static int scount = 0;
int count = 0;
Evas_Coord mw, mh;
EINA_INLIST_FOREACH(sd->items, it)
{
@ -1313,7 +1314,16 @@ _inform_item_number(Evas_Object *obj)
EINA_INLIST_FOREACH(sd->items, it)
{
if (!it->separator && !it->object)
edje_object_signal_emit(VIEW(it), buf, "elm");
{
edje_object_signal_emit(VIEW(it), buf, "elm");
edje_object_message_signal_process(VIEW(it));
mw = mh = -1;
elm_coords_finger_size_adjust(1, &mw, 1, &mh);
edje_object_size_min_restricted_calc(VIEW(it), &mw, &mh, mw, mh);
evas_object_size_hint_min_set(VIEW(it), mw, mh);
}
}
}
}