changeset 15507:94031a2b0aaa

gtkblist changes to pidgin
author Sean Egan <seanegan@gmail.com>
date Sat, 03 Feb 2007 08:52:00 +0000
parents 311315e979f7
children 23ca11f8a8c4
files pidgin/gtkblist.c pidgin/gtkblist.h pidgin/gtkconv.c pidgin/plugins/ticker/ticker.c
diffstat 4 files changed, 18 insertions(+), 18 deletions(-) [+]
line wrap: on
line diff
--- a/pidgin/gtkblist.c	Sat Feb 03 08:45:32 2007 +0000
+++ b/pidgin/gtkblist.c	Sat Feb 03 08:52:00 2007 +0000
@@ -2267,7 +2267,7 @@
 		account = ((GaimChat*)(node))->account;
 	}
 
-	td->status_icon = pidgin_blist_get_status_icon(node, GAIM_STATUS_ICON_LARGE);
+	td->status_icon = pidgin_blist_get_status_icon(node, PIDGIN_STATUS_ICON_LARGE);
 	td->avatar = pidgin_blist_get_buddy_icon(node, !full, FALSE, TRUE);
 	td->prpl_icon = pidgin_create_prpl_icon(account, PIDGIN_PRPL_ICON_SMALL);
 	tooltip_text = gaim_get_tooltip_text(node, full);
@@ -3022,7 +3022,7 @@
 
 
 GdkPixbuf *
-pidgin_blist_get_status_icon(GaimBlistNode *node, GaimStatusIconSize size)
+pidgin_blist_get_status_icon(GaimBlistNode *node, PidginStatusIconSize size)
 {
 	GdkPixbuf *ret;
 	const char *protoname = NULL;
@@ -3030,7 +3030,7 @@
 	struct _pidgin_blist_node *gtkbuddynode = NULL;
 	GaimBuddy *buddy = NULL;
 	GaimChat *chat = NULL;
-	GtkIconSize icon_size = gtk_icon_size_from_name((size == GAIM_STATUS_ICON_LARGE) ? PIDGIN_ICON_SIZE_TANGO_MEDIUM :
+	GtkIconSize icon_size = gtk_icon_size_from_name((size == PIDGIN_STATUS_ICON_LARGE) ? PIDGIN_ICON_SIZE_TANGO_MEDIUM :
 											 PIDGIN_ICON_SIZE_TANGO_EXTRA_SMALL);
 
 	if(GAIM_BLIST_NODE_IS_CONTACT(node)) {
@@ -3075,7 +3075,7 @@
 		GaimPresence *p;
 		if(conv != NULL) {
 			PidginConversation *gtkconv = PIDGIN_CONVERSATION(conv);
-			if(gtkconv != NULL && pidgin_conv_is_hidden(gtkconv) && size == GAIM_STATUS_ICON_SMALL) {
+			if(gtkconv != NULL && pidgin_conv_is_hidden(gtkconv) && size == PIDGIN_STATUS_ICON_SMALL) {
 				return gtk_widget_render_icon (GTK_WIDGET(gtkblist->treeview), PIDGIN_STOCK_STATUS_MESSAGE,
 							       icon_size, "GtkTreeView");
 			}
@@ -3089,21 +3089,21 @@
 			ret = gtk_widget_render_icon (GTK_WIDGET(gtkblist->treeview), PIDGIN_STOCK_STATUS_LOGOUT,
 					icon_size, "GtkTreeView");
 		else if (gaim_presence_is_status_primitive_active(p, GAIM_STATUS_UNAVAILABLE))
-			if (gaim_presence_is_idle(p) && size == GAIM_STATUS_ICON_SMALL)
+			if (gaim_presence_is_idle(p) && size == PIDGIN_STATUS_ICON_SMALL)
 				ret = gtk_widget_render_icon (GTK_WIDGET(gtkblist->treeview), PIDGIN_STOCK_STATUS_BUSY_I,
 						icon_size, "GtkTreeView");
 			else
 				ret = gtk_widget_render_icon (GTK_WIDGET(gtkblist->treeview), PIDGIN_STOCK_STATUS_BUSY,
 						icon_size, "GtkTreeView");
 		else if (gaim_presence_is_status_primitive_active(p, GAIM_STATUS_AWAY))
-		        if (gaim_presence_is_idle(p) && size == GAIM_STATUS_ICON_SMALL)
+		        if (gaim_presence_is_idle(p) && size == PIDGIN_STATUS_ICON_SMALL)
 		                ret = gtk_widget_render_icon (GTK_WIDGET(gtkblist->treeview), PIDGIN_STOCK_STATUS_AWAY_I,
 		                                icon_size, "GtkTreeView");
 		 	else
 				ret = gtk_widget_render_icon (GTK_WIDGET(gtkblist->treeview), PIDGIN_STOCK_STATUS_AWAY,
 						icon_size, "GtkTreeView");
 		else if (gaim_presence_is_status_primitive_active(p, GAIM_STATUS_EXTENDED_AWAY))
-			if (gaim_presence_is_idle(p) && size == GAIM_STATUS_ICON_SMALL)
+			if (gaim_presence_is_idle(p) && size == PIDGIN_STATUS_ICON_SMALL)
 		        	ret = gtk_widget_render_icon (GTK_WIDGET(gtkblist->treeview), PIDGIN_STOCK_STATUS_XA_I,
 						icon_size, "GtkTreeView");
 			else
@@ -3112,7 +3112,7 @@
 		else if (gaim_presence_is_status_primitive_active(p, GAIM_STATUS_OFFLINE))
 			ret = gtk_widget_render_icon (GTK_WIDGET(gtkblist->treeview), PIDGIN_STOCK_STATUS_OFFLINE,
 					icon_size, "GtkTreeView");
-		else if (gaim_presence_is_idle(p) && size == GAIM_STATUS_ICON_SMALL)
+		else if (gaim_presence_is_idle(p) && size == PIDGIN_STATUS_ICON_SMALL)
 			ret = gtk_widget_render_icon (GTK_WIDGET(gtkblist->treeview), PIDGIN_STOCK_STATUS_AVAILABLE_I,
 					icon_size, "GtkTreeView");
 		else
@@ -4745,7 +4745,7 @@
 	presence = gaim_buddy_get_presence(buddy);
 
 	status = pidgin_blist_get_status_icon((GaimBlistNode*)buddy,
-						GAIM_STATUS_ICON_SMALL);
+						PIDGIN_STATUS_ICON_SMALL);
 
 	avatar = pidgin_blist_get_buddy_icon((GaimBlistNode *)buddy, TRUE, TRUE, TRUE);
 	if (!avatar) {
@@ -4847,7 +4847,7 @@
 			char *mark;
 
 			status = pidgin_blist_get_status_icon(cnode,
-					 GAIM_STATUS_ICON_SMALL);
+					 PIDGIN_STATUS_ICON_SMALL);
 
 			mark = g_markup_escape_text(gaim_contact_get_alias(contact), -1);
 			gtk_tree_store_set(gtkblist->treemodel, &iter,
@@ -4928,7 +4928,7 @@
 			return;
 
 		status = pidgin_blist_get_status_icon(node,
-				 GAIM_STATUS_ICON_SMALL);
+				 PIDGIN_STATUS_ICON_SMALL);
 		emblem = pidgin_blist_get_emblem(node);
 		avatar = pidgin_blist_get_buddy_icon(node, TRUE, FALSE, TRUE);
 
--- a/pidgin/gtkblist.h	Sat Feb 03 08:45:32 2007 +0000
+++ b/pidgin/gtkblist.h	Sat Feb 03 08:52:00 2007 +0000
@@ -47,10 +47,10 @@
 };
 
 typedef enum {
-	GAIM_STATUS_ICON_LARGE,
-	GAIM_STATUS_ICON_SMALL
+	PIDGIN_STATUS_ICON_LARGE,
+	PIDGIN_STATUS_ICON_SMALL
 
-} GaimStatusIconSize;
+} PidginStatusIconSize;
 
 #include "gtkgaim.h"
 #include "blist.h"
@@ -193,7 +193,7 @@
  * Useful for the buddy ticker
  */
 GdkPixbuf *pidgin_blist_get_status_icon(GaimBlistNode *node,
-		GaimStatusIconSize size);
+		PidginStatusIconSize size);
 
 /**
  * Returns a boolean indicating if @a node is part of an expanded contact.
--- a/pidgin/gtkconv.c	Sat Feb 03 08:45:32 2007 +0000
+++ b/pidgin/gtkconv.c	Sat Feb 03 08:52:00 2007 +0000
@@ -2261,7 +2261,7 @@
 				ops->update(NULL, (GaimBlistNode*)b);
 
 			status = pidgin_blist_get_status_icon((GaimBlistNode*)b,
-				(small_icon ? GAIM_STATUS_ICON_SMALL : GAIM_STATUS_ICON_LARGE));
+				(small_icon ? PIDGIN_STATUS_ICON_SMALL : PIDGIN_STATUS_ICON_LARGE));
 		}
 	}
 
@@ -3196,7 +3196,7 @@
 
 	/* Create a pixmap for the protocol icon. */
 	if (buddy != NULL)
-		pixbuf = pidgin_blist_get_status_icon((GaimBlistNode*)buddy, GAIM_STATUS_ICON_SMALL);
+		pixbuf = pidgin_blist_get_status_icon((GaimBlistNode*)buddy, PIDGIN_STATUS_ICON_SMALL);
 	else
 		pixbuf = pidgin_create_prpl_icon(account, 0.5);
 
--- a/pidgin/plugins/ticker/ticker.c	Sat Feb 03 08:45:32 2007 +0000
+++ b/pidgin/plugins/ticker/ticker.c	Sat Feb 03 08:52:00 2007 +0000
@@ -117,7 +117,7 @@
 		td->icon = gtk_image_new();
 
 	pixbuf = pidgin_blist_get_status_icon((GaimBlistNode*)c,
-			GAIM_STATUS_ICON_SMALL);
+			PIDGIN_STATUS_ICON_SMALL);
 	gtk_image_set_from_pixbuf(GTK_IMAGE(td->icon), pixbuf);
 	g_object_unref(G_OBJECT(pixbuf));
 }