changeset 8960:7c008d98ef33

[gaim-migrate @ 9734] this was decidedly easy to do committer: Tailor Script <tailor@pidgin.im>
author Nathan Walp <nwalp@pidgin.im>
date Mon, 17 May 2004 02:40:04 +0000
parents bfc8dea58386
children 92e061a1db10
files src/blist.c src/gtkblist.c
diffstat 2 files changed, 13 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/src/blist.c	Mon May 17 02:02:24 2004 +0000
+++ b/src/blist.c	Mon May 17 02:40:04 2004 +0000
@@ -1484,7 +1484,8 @@
 							ops->update(gaimbuddylist, bnode);
 						}
 					}
-					if(recompute) {
+					if(recompute ||
+							gaim_blist_node_get_bool(cnode, "show_offline")) {
 						gaim_contact_compute_priority_buddy((GaimContact*)cnode);
 						ops->update(gaimbuddylist, cnode);
 					}
@@ -2422,6 +2423,9 @@
 						}
 					}
 
+					g_hash_table_foreach(cnode->settings,
+							blist_print_cnode_settings, file);
+
 					fprintf(file, "\t\t\t</contact>\n");
 				} else if(GAIM_BLIST_NODE_IS_CHAT(cnode)) {
 					GaimChat *chat = (GaimChat *)cnode;
--- a/src/gtkblist.c	Mon May 17 02:02:24 2004 +0000
+++ b/src/gtkblist.c	Mon May 17 02:40:04 2004 +0000
@@ -2133,7 +2133,10 @@
 	gtknode = node->ui_data;
 
 	if (node->child && GAIM_BLIST_NODE_IS_CONTACT(node) &&
-			((GaimContact*)node)->online > 1 && !gtknode->contact_expanded &&
+			(((GaimContact*)node)->online > 1 ||
+			 (gaim_blist_node_get_bool(node, "show_offline") &&
+			  ((GaimContact*)node)->currentsize > 1)) &&
+			!gtknode->contact_expanded &&
 			gaim_prefs_get_bool("/gaim/gtk/blist/auto_expand_contacts")) {
 		GtkTreeIter i;
 		gaim_gtk_blist_expand_contact_cb(NULL, node);
@@ -3627,7 +3630,8 @@
 
 	if(buddy && (buddy->present != GAIM_BUDDY_OFFLINE ||
 			(gaim_account_is_connected(buddy->account) &&
-			 gaim_prefs_get_bool("/gaim/gtk/blist/show_offline_buddies")))) {
+			 gaim_prefs_get_bool("/gaim/gtk/blist/show_offline_buddies")) ||
+			gaim_blist_node_get_bool(node, "show_offline"))) {
 		GtkTreeIter iter;
 
 		if(!insert_node(list, node, &iter))
@@ -3680,7 +3684,8 @@
 	if(gtkparentnode->contact_expanded &&
 			(buddy->present != GAIM_BUDDY_OFFLINE ||
 			(gaim_account_is_connected(buddy->account) &&
-			 gaim_prefs_get_bool("/gaim/gtk/blist/show_offline_buddies")))) {
+			 gaim_prefs_get_bool("/gaim/gtk/blist/show_offline_buddies")) ||
+			gaim_blist_node_get_bool(node->parent, "show_offline"))) {
 		GtkTreeIter iter;
 
 		if(!insert_node(list, node, &iter))