[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

gEDA-cvs: gaf.git: branch: master updated (1.6.1-20100214-190-g371bd61)



The branch, master has been updated
       via  371bd6130c77ae0d671ade3a82410f9a3a6105c3 (commit)
      from  1e93f7bea2cbe0fa8887337c261093b55c31dd6d (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


=========
 Summary
=========

 gschem/src/x_compselect.c |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)


=================
 Commit Messages
=================

commit 371bd6130c77ae0d671ade3a82410f9a3a6105c3
Author: Krzysztof Kosciuszkiewicz <k.kosciuszkiewicz@xxxxxxxxx>
Commit: Peter TB Brett <peter@xxxxxxxxxxxxx>

    gschem: expand component tree after filtering
    
    This patch changes the behavior of the component selection dialog.
    After filtering by name is applied the tree view of matching components
    is automatically expanded so that all leafs are immediately selectable.
    The tree view is collapsed when the filter is cleared.
    
    Reviewed-by: Peter TB Brett <peter@xxxxxxxxxxxxx>

:100644 100644 b1e0b4a... 2951149... M	gschem/src/x_compselect.c

=========
 Changes
=========

commit 371bd6130c77ae0d671ade3a82410f9a3a6105c3
Author: Krzysztof Kosciuszkiewicz <k.kosciuszkiewicz@xxxxxxxxx>
Commit: Peter TB Brett <peter@xxxxxxxxxxxxx>

    gschem: expand component tree after filtering
    
    This patch changes the behavior of the component selection dialog.
    After filtering by name is applied the tree view of matching components
    is automatically expanded so that all leafs are immediately selectable.
    The tree view is collapsed when the filter is cleared.
    
    Reviewed-by: Peter TB Brett <peter@xxxxxxxxxxxxx>

diff --git a/gschem/src/x_compselect.c b/gschem/src/x_compselect.c
index b1e0b4a..2951149 100644
--- a/gschem/src/x_compselect.c
+++ b/gschem/src/x_compselect.c
@@ -633,7 +633,15 @@ compselect_filter_timeout (gpointer data)
   model = gtk_tree_view_get_model (compselect->libtreeview);
 
   if (model != NULL) {
+    const gchar *text = gtk_entry_get_text (compselect->entry_filter);
     gtk_tree_model_filter_refilter ((GtkTreeModelFilter*)model);
+    if (strcmp (text, "") != 0) {
+      /* filter text not-empty */
+      gtk_tree_view_expand_all (compselect->libtreeview);
+    } else {
+      /* filter text is empty, collapse expanded tree */
+      gtk_tree_view_collapse_all (compselect->libtreeview);
+    }
   }
 
   /* return FALSE to remove the source */




_______________________________________________
geda-cvs mailing list
geda-cvs@xxxxxxxxxxxxxx
http://www.seul.org/cgi-bin/mailman/listinfo/geda-cvs