changeset 4691:d78f7cb8ae4f

[gaim-migrate @ 5002] Open source at work. Thanks, Ha-King, Ethan. I also shrunk the group folder icon a bit. committer: Tailor Script <tailor@pidgin.im>
author Sean Egan <seanegan@gmail.com>
date Mon, 10 Mar 2003 06:35:40 +0000
parents e19f91053ad0
children a81443d3516b
files src/buddy.c
diffstat 1 files changed, 12 insertions(+), 9 deletions(-) [+]
line wrap: on
line diff
--- a/src/buddy.c	Mon Mar 10 06:22:44 2003 +0000
+++ b/src/buddy.c	Mon Mar 10 06:35:40 2003 +0000
@@ -170,14 +170,17 @@
 	GaimBlistNode *node;
 	GValue val;
 
-	gtk_tree_selection_get_selected(sel, NULL, &iter);
-	gtk_tree_model_get_value (GTK_TREE_MODEL(gtkblist->treemodel), &iter, NODE_COLUMN, &val);
-	node = g_value_get_pointer(&val);
+	if (gtk_tree_selection_get_selected(sel, NULL, &iter)) {
+		gtk_tree_model_get_value (GTK_TREE_MODEL(gtkblist->treemodel), &iter, NODE_COLUMN, &val);
+		node = g_value_get_pointer(&val);
 	
-	if (GAIM_BLIST_NODE_IS_BUDDY(node)) 
-		show_add_buddy(NULL, NULL, ((struct group*)node->parent)->name, NULL);
-	else if (GAIM_BLIST_NODE_IS_GROUP(node))
-		show_add_buddy(NULL, NULL, ((struct group*)node)->name, NULL);
+		if (GAIM_BLIST_NODE_IS_BUDDY(node)) 
+			show_add_buddy(NULL, NULL, ((struct group*)node->parent)->name, NULL);
+		else if (GAIM_BLIST_NODE_IS_GROUP(node))
+			show_add_buddy(NULL, NULL, ((struct group*)node)->name, NULL);
+	} else {
+		show_add_buddy(NULL,NULL,NULL,NULL);
+	}
 	
 }
 
@@ -239,7 +242,7 @@
 	gchar *filename = NULL;	
 	const char *protoname = NULL;
 
-	char *se,*sw,*nw,*ne;
+	char *se = NULL, *sw = NULL ,*nw = NULL ,*ne = NULL;
 	
 	int scalesize = 30;
 
@@ -574,7 +577,7 @@
 								    node->parent->parent ? node->parent->parent->ui_data : NULL, insertatiter);
 					gtk_tree_store_set(gtkblist->treemodel, iter2, 
 							   STATUS_ICON_COLUMN, gtk_widget_render_icon
-							   (gtkblist->treeview,GTK_STOCK_OPEN,GTK_ICON_SIZE_LARGE_TOOLBAR,NULL),
+							   (gtkblist->treeview,GTK_STOCK_OPEN,GTK_ICON_SIZE_SMALL_TOOLBAR,NULL),
 							   NAME_COLUMN, mark,
 							   NODE_COLUMN, node->parent,
 							   -1);