X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~mdw/git/disorder/blobdiff_plain/39fe10140c119ea11d2834416d59ff0995675adc..e1d4a32b103161e3b3ec51c0895f2ca88413078f:/disobedience/choose.c diff --git a/disobedience/choose.c b/disobedience/choose.c index 842a200..1cd4500 100644 --- a/disobedience/choose.c +++ b/disobedience/choose.c @@ -433,7 +433,7 @@ static void fill_search_node(struct choosenode *cn) { D(("fill_search_node %s", cn->path)); /* We depend on the search results being sorted as by compare_path(). */ - cn->children.nvec = 0; + clear_children(cn); for(n = 0; n < nsearchresults; ++n) { /* We only care about descendants of CN */ if(!is_descendant(cn->path, searchresults[n])) @@ -596,7 +596,9 @@ static void redisplay_tree(void) { files_selected = 0; files_visible = 0; /* Correct the layout and find out how much space it uses */ + MTAG_PUSH("display_tree"); d = display_tree(root, 0, 0); + MTAG_POP(); /* We must set the total size or scrolling will not work (it wouldn't be hard * for GtkLayout to figure it out for itself but presumably you're supposed * to be able to have widgets off the edge of the layuot.) @@ -630,6 +632,7 @@ static struct displaydata display_tree(struct choosenode *cn, int x, int y) { * A non-expandable item has just a text label and no arrow. */ if(!cn->container) { + MTAG_PUSH("make_widgets"); /* Widgets need to be created */ NW(hbox); cn->hbox = gtk_hbox_new(FALSE, 1); @@ -665,6 +668,7 @@ static struct displaydata display_tree(struct choosenode *cn, int x, int y) { gtk_widget_set_name(cn->container, "choose"); /* Show everything by default */ gtk_widget_show_all(cn->container); + MTAG_POP(); } assert(cn->container); /* Make sure the icon is right */