diff console/libgnt/gnttree.c @ 14336:f3ef96e8428f

[gaim-migrate @ 17032] The entries in the accounts-window, the status-window etc. now should have the same order as in the xml-file. committer: Tailor Script <tailor@pidgin.im>
author Sadrul Habib Chowdhury <imadil@gmail.com>
date Fri, 25 Aug 2006 19:04:29 +0000
parents e9dd2f76e61b
children 0387a167f342
line wrap: on
line diff
--- a/console/libgnt/gnttree.c	Fri Aug 25 18:21:22 2006 +0000
+++ b/console/libgnt/gnttree.c	Fri Aug 25 19:04:29 2006 +0000
@@ -990,7 +990,19 @@
 	GntTreeRow *r;
 	r = g_hash_table_lookup(tree->hash, key);
 	g_return_val_if_fail(!r || !r->choice, NULL);
-		
+
+	if (bigbro == NULL) {
+		r = g_hash_table_lookup(tree->hash, parent);
+		if (!r)
+			r = tree->root;
+		else
+			r = r->child;
+		if (r) {
+			while (r->next)
+				r = r->next;
+			bigbro = r->key;
+		} 
+	}
 	row = gnt_tree_add_row_after(tree, key, row, parent, bigbro);
 	row->choice = TRUE;