Enlightenment CVS committal
Author : rbdpngn
Project : e17
Module : libs/ewl
Dir : e17/libs/ewl/src
Modified Files:
ewl_filedialog.c ewl_fileselector.c ewl_fileselector.h
Log Message:
Removed a couple unnecessary widgets used internally by the fileselector, and
fixed the sizing in the dialog test.
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/ewl_filedialog.c,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -3 -r1.16 -r1.17
--- ewl_filedialog.c 9 Dec 2003 17:56:27 -0000 1.16
+++ ewl_filedialog.c 9 Dec 2003 20:07:15 -0000 1.17
@@ -30,12 +30,10 @@
/**
- * ewl_filedialog_new - create a new filedialog
- * @follows: the widget this dialog follows
- * @cb: callback to be called when open/save button is pushed
- *
- * Returns a pointer to a newly allocated filedialog in success, NULL on
- * failure.
+ * @param follows: the widget this dialog follows
+ * @param cb: callback to be called when open/save button is pushed
+ * @return Returns a new filedialog in success, NULL on failure.
+ * @brief Create a new filedialog
*/
Ewl_Widget *ewl_filedialog_new(Ewl_Widget * follows,
Ewl_Filedialog_Type type,
@@ -135,6 +133,8 @@
return;
vbox = ewl_vbox_new ();
+ ewl_object_set_fill_policy(EWL_OBJECT(vbox), EWL_FLAG_FILL_SHRINK |
+ EWL_FLAG_FILL_FILL);
ewl_container_append_child(EWL_CONTAINER(fd), vbox);
ewl_widget_show (vbox);
@@ -143,8 +143,6 @@
ewl_widget_show (fd->path_label);
fd->selector = ewl_fileselector_new(cb);
- ewl_object_set_fill_policy(EWL_OBJECT(fd->selector),
- EWL_FLAG_FILL_SHRINK | EWL_FLAG_FILL_FILL);
ewl_container_append_child(EWL_CONTAINER(vbox), fd->selector);
ewl_callback_append (EWL_WIDGET (fd->selector),
EWL_CALLBACK_VALUE_CHANGED, ewl_filedialog_change_labels, fd);
@@ -155,22 +153,19 @@
od->box = ewl_box_new(EWL_ORIENTATION_HORIZONTAL);
ewl_box_set_spacing(EWL_BOX(od->box), 4);
ewl_object_set_padding(EWL_OBJECT(od->box), 10, 10, 10, 10);
- ewl_object_set_fill_policy(EWL_OBJECT(od->box),
- EWL_FLAG_FILL_VSHRINK);
+ ewl_object_set_fill_policy(EWL_OBJECT(od->box), EWL_FLAG_FILL_NONE);
ewl_object_set_alignment(EWL_OBJECT(od->box), EWL_FLAG_ALIGN_RIGHT);
ewl_container_append_child(EWL_CONTAINER(vbox), od->box);
ewl_widget_show(od->box);
od->open = ewl_button_new("Open");
- ewl_object_set_fill_policy(EWL_OBJECT(od->open),
- EWL_FLAG_FILL_SHRINK);
+ ewl_object_set_fill_policy(EWL_OBJECT(od->open), EWL_FLAG_FILL_NONE);
ewl_callback_append(od->open, EWL_CALLBACK_CLICKED, cb, fd->selector);
ewl_container_append_child(EWL_CONTAINER(od->box), od->open);
ewl_widget_show(od->open);
od->cancel = ewl_button_new("Cancel");
- ewl_object_set_fill_policy(EWL_OBJECT(od->cancel),
- EWL_FLAG_FILL_SHRINK);
+ ewl_object_set_fill_policy(EWL_OBJECT(od->cancel), EWL_FLAG_FILL_NONE);
ewl_callback_append(od->cancel, EWL_CALLBACK_CLICKED,
ewl_filedialog_destroy_cb, NULL);
ewl_container_append_child(EWL_CONTAINER(od->box), od->cancel);
@@ -213,8 +208,6 @@
return;
fd->selector = ewl_fileselector_new(cb);
- ewl_object_set_fill_policy(EWL_OBJECT(fd->selector),
- EWL_FLAG_FILL_SHRINK | EWL_FLAG_FILL_FILL);
ewl_container_append_child(EWL_CONTAINER(fd), fd->selector);
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/ewl_fileselector.c,v
retrieving revision 1.22
retrieving revision 1.23
diff -u -3 -r1.22 -r1.23
--- ewl_fileselector.c 9 Dec 2003 17:56:27 -0000 1.22
+++ ewl_fileselector.c 9 Dec 2003 20:07:15 -0000 1.23
@@ -100,35 +100,19 @@
w = EWL_WIDGET(fs);
ewl_box_init(EWL_BOX(w), EWL_ORIENTATION_HORIZONTAL);
+ ewl_box_set_homogeneous(EWL_BOX(w), TRUE);
ewl_object_set_fill_policy(EWL_OBJECT(w), EWL_FLAG_FILL_SHRINK |
EWL_FLAG_FILL_FILL);
- /*
- * Create the vbox that should contain the directories tree
- */
- fs->dbox = ewl_vbox_new();
- ewl_object_set_fill_policy(EWL_OBJECT(fs->dbox), EWL_FLAG_FILL_SHRINK |
- EWL_FLAG_FILL_FILL);
- ewl_container_append_child(EWL_CONTAINER(w), fs->dbox);
- ewl_widget_show(fs->dbox);
-
fs->dirs = ewl_tree_new (1);
ewl_tree_set_headers (EWL_TREE (fs->dirs), head_dirs);
- ewl_container_append_child(EWL_CONTAINER (fs->dbox), fs->dirs);
+ ewl_container_append_child(EWL_CONTAINER(w), fs->dirs);
ewl_object_set_minimum_size (EWL_OBJECT (fs->dirs), 100, 50);
ewl_widget_show (fs->dirs);
- /*
- * Create the vbox that should contain the files tree
- */
- fs->fbox = ewl_vbox_new();
- ewl_object_set_fill_policy(EWL_OBJECT(fs->fbox), EWL_FLAG_FILL_FILL);
- ewl_container_append_child(EWL_CONTAINER(w), fs->fbox);
- ewl_widget_show(fs->fbox);
-
fs->files = ewl_tree_new (1);
ewl_tree_set_headers (EWL_TREE (fs->files), head_files);
- ewl_container_append_child(EWL_CONTAINER (fs->fbox), fs->files);
+ ewl_container_append_child(EWL_CONTAINER(w), fs->files);
ewl_widget_show (fs->files);
/* Set what callback the user has defined */
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/ewl/src/ewl_fileselector.h,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -3 -r1.9 -r1.10
--- ewl_fileselector.h 9 Dec 2003 17:56:27 -0000 1.9
+++ ewl_fileselector.h 9 Dec 2003 20:07:15 -0000 1.10
@@ -18,9 +18,6 @@
struct _ewl_fileselector {
Ewl_Box box;
- Ewl_Widget *dbox; /* vbox to display directories */
- Ewl_Widget *fbox; /* vbox to display files */
-
Ewl_Widget *dirs; /* directory table */
Ewl_Widget *files; /* file table */
-------------------------------------------------------
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills. Sign up for IBM's
Free Linux Tutorials. Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
_______________________________________________
enlightenment-cvs mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs