Enlightenment CVS committal Author : titan Project : e17 Module : proto
Dir : e17/proto/ephoto/src Modified Files: ephoto.h ephoto_browsing.c ephoto_misc.c Log Message: Center the text in the tree rows. =================================================================== RCS file: /cvs/e/e17/proto/ephoto/src/ephoto.h,v retrieving revision 1.16 retrieving revision 1.17 diff -u -3 -r1.16 -r1.17 --- ephoto.h 6 Apr 2006 23:28:38 -0000 1.16 +++ ephoto.h 7 Apr 2006 13:18:21 -0000 1.17 @@ -42,6 +42,8 @@ void slideshow_load_cb(Ewl_Widget *w, void *event, void *data); void loadclicked_cb(Ewl_Widget *w, void *event, void *data); void load_cb(Ewl_Widget *w, void *event, void *data); +void reseti_cb(Ewl_Widget *w, void *event, void *data); +void reseta_cb(Ewl_Widget *w, void *event, void *data); typedef struct _Main Main; typedef struct _Slide Slide; =================================================================== RCS file: /cvs/e/e17/proto/ephoto/src/ephoto_browsing.c,v retrieving revision 1.25 retrieving revision 1.26 diff -u -3 -r1.25 -r1.26 --- ephoto_browsing.c 7 Apr 2006 01:47:39 -0000 1.25 +++ ephoto_browsing.c 7 Apr 2006 13:18:21 -0000 1.26 @@ -170,6 +170,9 @@ m->hbox = ewl_hbox_new(); ewl_box_spacing_set(EWL_BOX(m->hbox), 5); + ewl_object_alignment_set(EWL_OBJECT(m->hbox), EWL_FLAG_ALIGN_CENTER); + ewl_object_fill_policy_set(EWL_OBJECT(m->hbox), EWL_FLAG_FILL_ALL); + ewl_widget_name_set(m->hbox, pathw); ewl_widget_show(m->hbox); m->image = ewl_image_new(); @@ -181,14 +184,15 @@ ewl_widget_name_set(m->text, pathw); ewl_text_text_set(EWL_TEXT(m->text), bname); ewl_object_minimum_size_set(EWL_OBJECT(m->text), 10, 16); - ewl_object_fill_policy_set(EWL_OBJECT(m->text), EWL_FLAG_FILL_ALL); + ewl_object_fill_policy_set(EWL_OBJECT(m->text), EWL_FLAG_FILL_SHRINK); + ewl_object_alignment_set(EWL_OBJECT(m->text), EWL_FLAG_ALIGN_CENTER); ewl_container_child_append(EWL_CONTAINER(m->hbox), m->text); ewl_widget_show(m->text); m->children[0] = m->hbox; m->children[1] = NULL; m->row = ewl_tree_row_add(EWL_TREE(m->dirtree), NULL, m->children); - ewl_callback_append(m->text, EWL_CALLBACK_CLICKED, populatei_cb, NULL); + ewl_callback_append(m->hbox, EWL_CALLBACK_CLICKED, populatei_cb, NULL); } } /****************************************************************************/ @@ -242,7 +246,7 @@ ewl_widget_show(m->hbox); m->image = ewl_image_new(); - ewl_image_file_set(EWL_IMAGE(m->image), PACKAGE_DATA_DIR "images/audio.png", NULL); + ewl_image_file_set(EWL_IMAGE(m->image), PACKAGE_DATA_DIR "/images/audio.png", NULL); ewl_container_child_append(EWL_CONTAINER(m->hbox), m->image); ewl_widget_show(m->image); @@ -255,9 +259,6 @@ ewl_container_child_append(EWL_CONTAINER(m->hbox), m->text); ewl_widget_show(m->text); - m->children[0] = m->hbox; - m->children[1] = NULL; - m->children[0] = m->hbox; m->children[1] = NULL; m->row = ewl_tree_row_add(EWL_TREE(m->dirtree), NULL, m->children); =================================================================== RCS file: /cvs/e/e17/proto/ephoto/src/ephoto_misc.c,v retrieving revision 1.12 retrieving revision 1.13 diff -u -3 -r1.12 -r1.13 --- ephoto_misc.c 7 Apr 2006 03:12:34 -0000 1.12 +++ ephoto_misc.c 7 Apr 2006 13:18:21 -0000 1.13 @@ -225,6 +225,7 @@ { Ewl_Widget *vbox; Ewl_Widget *hbox; + Ewl_Widget *image; Ewl_Widget *rtext; Ewl_Widget *tree; Ewl_Widget *ok; @@ -266,14 +267,24 @@ char *tempo; tempo = ecore_list_remove_first(slideshows); - rtext = ewl_text_new(); + hbox = ewl_hbox_new(); + ewl_box_spacing_set(EWL_BOX(hbox), 5); + ewl_widget_show(hbox); + + image = ewl_image_new(); + ewl_image_file_set(EWL_IMAGE(image), PACKAGE_DATA_DIR "/images/slide.png", NULL); + ewl_container_child_append(EWL_CONTAINER(hbox), image); + ewl_widget_show(image); + + rtext = ewl_text_new(); ewl_widget_name_set(rtext, tempo); ewl_text_text_set(EWL_TEXT(rtext), tempo); ewl_object_minimum_size_set(EWL_OBJECT(rtext), 10, 16); ewl_object_fill_policy_set(EWL_OBJECT(rtext), EWL_FLAG_FILL_ALL); - ewl_widget_show(rtext); + ewl_container_child_append(EWL_CONTAINER(hbox), rtext); + ewl_widget_show(rtext); - children[0] = rtext; + children[0] = hbox; children[1] = NULL; row = ewl_tree_row_add(EWL_TREE(tree), NULL, children); ewl_callback_append(rtext, EWL_CALLBACK_CLICKED, loadclicked_cb, NULL); ------------------------------------------------------- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642 _______________________________________________ enlightenment-cvs mailing list enlightenment-cvs@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs