changeset 4837:3411fdaa54fa

[gaim-migrate @ 5162] Let's try not having expander arrows for a little bit. I'll get better "expand/collapse" icons soon. committer: Tailor Script <tailor@pidgin.im>
author Rob Flynn <gaim@robflynn.com>
date Thu, 20 Mar 2003 05:24:41 +0000
parents d2b4e0ed7985
children 60d8c5ad77f9
files src/buddy.c src/gtklist.h
diffstat 2 files changed, 10 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/buddy.c	Thu Mar 20 01:36:55 2003 +0000
+++ b/src/buddy.c	Thu Mar 20 05:24:41 2003 +0000
@@ -924,6 +924,7 @@
 	GtkItemFactory *ift;
 	GtkCellRenderer *rend;
 	GtkTreeViewColumn *column;
+	GtkTreeViewColumn *expcol;
 	GtkWidget *sw;
 	GtkWidget *button;
 	GtkSizeGroup *sg;
@@ -969,7 +970,7 @@
 	gtk_scrolled_window_set_shadow_type (GTK_SCROLLED_WINDOW(sw), GTK_SHADOW_IN);
 	gtk_scrolled_window_set_policy(GTK_SCROLLED_WINDOW(sw), GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC);
 
-	gtkblist->treemodel = gtk_tree_store_new(BLIST_COLUMNS, GDK_TYPE_PIXBUF, G_TYPE_STRING,
+	gtkblist->treemodel = gtk_tree_store_new(BLIST_COLUMNS, G_TYPE_STRING, GDK_TYPE_PIXBUF, G_TYPE_STRING,
 						 G_TYPE_STRING, G_TYPE_STRING, GDK_TYPE_PIXBUF, G_TYPE_POINTER);
 
 	gtkblist->treeview = gtk_tree_view_new_with_model(GTK_TREE_MODEL(gtkblist->treemodel));
@@ -994,6 +995,10 @@
 
 	gtk_tree_view_set_headers_visible(GTK_TREE_VIEW(gtkblist->treeview), FALSE);
 
+	rend = gtk_cell_renderer_text_new();
+	expcol = gtk_tree_view_column_new_with_attributes("Empty", rend, "pixbuf", EXPANDER_COLUMN, NULL);
+	gtk_tree_view_append_column(GTK_TREE_VIEW(gtkblist->treeview), expcol);
+
 	rend = gtk_cell_renderer_pixbuf_new();
 	column = gtk_tree_view_column_new_with_attributes("Status", rend, "pixbuf", STATUS_ICON_COLUMN, NULL);
 	gtk_tree_view_append_column(GTK_TREE_VIEW(gtkblist->treeview), column);
@@ -1060,6 +1065,9 @@
 	gaim_gtk_blist_refresh(list);
 	gtk_widget_show_all(gtkblist->window);
 
+	gtk_tree_view_set_expander_column(GTK_TREE_VIEW(gtkblist->treeview), GTK_TREE_VIEW_COLUMN(expcol));
+	gtk_tree_view_column_set_visible(GTK_TREE_VIEW_COLUMN(expcol), FALSE);
+
 	gaim_gtk_blist_update_toolbar();
 
 }
--- a/src/gtklist.h	Thu Mar 20 01:36:55 2003 +0000
+++ b/src/gtklist.h	Thu Mar 20 05:24:41 2003 +0000
@@ -25,6 +25,7 @@
 #define _GAIM_GTK_LIST_H_
 
 enum {
+	EXPANDER_COLUMN,
 	STATUS_ICON_COLUMN,
 	NAME_COLUMN,
 	WARNING_COLUMN,