diff console/libgnt/gnttree.c @ 14091:ae4cbed1b309

[gaim-migrate @ 16715] Add support for tab-completion and save-history in GntEntry. Also, the keyboard-commands should now work for Xterms. committer: Tailor Script <tailor@pidgin.im>
author Sadrul Habib Chowdhury <imadil@gmail.com>
date Sat, 12 Aug 2006 10:27:29 +0000
parents 7573bd40a190
children eaf7f35635bc
line wrap: on
line diff
--- a/console/libgnt/gnttree.c	Sat Aug 12 10:20:19 2006 +0000
+++ b/console/libgnt/gnttree.c	Sat Aug 12 10:27:29 2006 +0000
@@ -770,6 +770,15 @@
 	}
 }
 
+void gnt_tree_remove_all(GntTree *tree)
+{
+	tree->root = NULL;
+	g_hash_table_remove_all(tree->hash);
+	g_list_free(tree->list);
+	tree->list = NULL;
+	tree->current = tree->top = tree->bottom = NULL;
+}
+
 int gnt_tree_get_selection_visible_line(GntTree *tree)
 {
 	return get_distance(tree->top, tree->current) +