changeset 28844:96f0f6af5da2

merge of '2a337fc21125a25203efca7d15ea3002fa8e35fb' and '70c2ddd8cc314e53815d3772bf1364a66164319a'
author Elliott Sales de Andrade <qulogic@pidgin.im>
date Fri, 30 Oct 2009 06:52:29 +0000
parents 61fd49ad0def (diff) dd5026ca598a (current diff)
children 7e400b0c6397 e3206d6da6c7
files libpurple/protocols/msn/notification.c
diffstat 2 files changed, 14 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/libpurple/protocols/msn/notification.c	Fri Oct 30 06:46:11 2009 +0000
+++ b/libpurple/protocols/msn/notification.c	Fri Oct 30 06:52:29 2009 +0000
@@ -1098,7 +1098,17 @@
 		/* Where'd this come from? */
 		return;
 
-	if (cmd->param_count == 7) {
+	if (cmd->param_count == 8) {
+		/* Yahoo! Buddy, looks like */
+		networkid = atoi(cmd->params[3]);
+		friendly = g_strdup(purple_url_decode(cmd->params[4]));
+		clientid = strtoul(cmd->params[5], NULL, 10);
+
+		/* cmd->params[7] seems to be a URL to a Yahoo! icon:
+				https://sec.yimg.com/i/us/nt/b/purpley.1.0.png
+		   ... and it's purple, HAH!
+		*/
+	} else if (cmd->param_count == 7) {
 		/* MSNP14+ with Display Picture object */
 		networkid = atoi(cmd->params[3]);
 		friendly = g_strdup(purple_url_decode(cmd->params[4]));
--- a/pidgin/gtkstatusbox.c	Fri Oct 30 06:46:11 2009 +0000
+++ b/pidgin/gtkstatusbox.c	Fri Oct 30 06:52:29 2009 +0000
@@ -312,6 +312,7 @@
 {
 	if (event->button == 3) {
 		GtkWidget *menu_item;
+		const char *path;
 
 		if (box->icon_box_menu)
 			gtk_widget_destroy(box->icon_box_menu);
@@ -325,7 +326,8 @@
 		menu_item = pidgin_new_item_from_stock(box->icon_box_menu, _("Remove"), GTK_STOCK_REMOVE,
 						     G_CALLBACK(remove_buddy_icon_cb),
 						     box, 0, 0, NULL);
-		if (purple_prefs_get_path(PIDGIN_PREFS_ROOT "/accounts/buddyicon") == NULL)
+		if (!(path = purple_prefs_get_path(PIDGIN_PREFS_ROOT "/accounts/buddyicon"))
+				|| !*path)
 			gtk_widget_set_sensitive(menu_item, FALSE);
 
 		gtk_menu_popup(GTK_MENU(box->icon_box_menu), NULL, NULL, NULL, NULL,