From: <enl...@li...> - 2005-09-20 09:45:18
|
Enlightenment CVS committal Author : codewarrior Project : e17 Module : apps/e Dir : e17/apps/e/src/bin Modified Files: e_configure.c Log Message: * data/themes/default_configure.edc: - add min: 1 1; to text parts so they can control the edje's size. * src/bin/e_configure.c: - better calculation of the min sizes for icons / window. =================================================================== RCS file: /cvsroot/enlightenment/e17/apps/e/src/bin/e_configure.c,v retrieving revision 1.3 retrieving revision 1.4 diff -u -3 -r1.3 -r1.4 --- e_configure.c 20 Sep 2005 08:34:23 -0000 1.3 +++ e_configure.c 20 Sep 2005 09:45:08 -0000 1.4 @@ -36,7 +36,7 @@ static void _e_configure_gui_show(E_Configure *app) { - Evas_Coord w, h; + Evas_Coord w, h, ew, eh; app->win = e_win_new(app->con); e_win_delete_callback_set(app->win, _e_configure_gui_hide); @@ -45,12 +45,9 @@ e_win_name_class_set(app->win, "EConfigure", "EConfigure"); app->evas = e_win_evas_get(app->win); ecore_evas_data_set(app->win->ecore_evas, "App", app); - - e_win_resize(app->win, 370, 200); - + e_win_resize_callback_set(app->win, _e_configure_cb_resize); - app->edje = edje_object_add(app->evas); e_theme_edje_object_set(app->edje, "base/theme/configure", "configure/main"); @@ -66,11 +63,19 @@ e_box_orientation_set(app->box, 1); e_box_align_set(app->box, 0.0, 0.0); - + + edje_object_size_min_calc (app->edje, &ew, &eh); e_box_min_size_get(app->box, &w, &h); + + if (ew > w ) + w = ew; + if (eh > h) + h = eh; + edje_extern_object_min_size_set(app->box, w, h); - e_win_size_base_set (app->win, w, h); - e_win_size_min_set (app->win, w, h); + e_win_size_base_set (app->win, w , h + eh); + e_win_size_min_set (app->win, w, h + eh); + e_win_resize(app->win, w, h + eh); edje_object_part_swallow(app->edje, "icon_swallow", app->box); evas_object_show(app->box); @@ -122,14 +127,20 @@ edje_object_part_swallow(o, "icon_swallow", icon); edje_object_part_text_set(o, "title", a->name); - evas_object_show(icon); + evas_object_show(icon); + + + + edje_object_size_min_calc (o, &w, &h); + edje_extern_object_min_size_set (o, w, h); + e_box_pack_end(app->box, o); e_box_pack_options_set(o, 1, 0, /* fill */ 1, 0, /* expand */ 0.0, 0.0, /* align */ - 64, 64, /* min */ + w, h, /* min */ 999, 999 //172, 72 /* max */ ); |