adium.1-3: ccdb44b0: Overplucked a little too much on this Ya...

zacw at adiumx.com zacw at adiumx.com
Sun Jul 5 15:50:21 EDT 2009


-----------------------------------------------------------------
Revision: ccdb44b03ebf0792b3b57531c03ae4e66086d8e2
Ancestor: a139b8af0bc2e07bf3fc4a65620d2cfbbf14b047
Author: zacw at adiumx.com
Date: 2009-07-05T19:48:12
Branch: im.pidgin.adium.1-3
URL: http://d.pidgin.im/viewmtn/revision/info/ccdb44b03ebf0792b3b57531c03ae4e66086d8e2

Modified files:
        libpurple/protocols/yahoo/yahoo.c
        libpurple/protocols/yahoo/yahoo.h

ChangeLog: 

Overplucked a little too much on this Yahoo change.


-------------- next part --------------
============================================================
--- libpurple/protocols/yahoo/yahoo.c	4cec01c07623081386bbc21a64d8cce83f6bc3b0
+++ libpurple/protocols/yahoo/yahoo.c	8f0cd6d43a16075b2b0a1c41e9bc982c8ba95848
@@ -580,9 +580,6 @@ static void yahoo_process_list(PurpleCon
 			else
 				g_string_append(yd->tmp_serv_ilist, pair->value);
 			break;
-		case 89:
-			yd->profiles = g_strsplit(pair->value, ",", -1);
-			break;
 		case 59: /* cookies, yum */
 			yahoo_process_cookie(yd, pair->value);
 			break;
@@ -2824,7 +2821,6 @@ static void yahoo_close(PurpleConnection
 	g_free(yd->pending_chat_id);
 	g_free(yd->pending_chat_topic);
 	g_free(yd->pending_chat_goto);
-	g_strfreev(yd->profiles);
 
 	g_free(yd->current_list15_grp);
 
@@ -3204,16 +3200,15 @@ static GList *yahoo_blist_node_menu(Purp
 	}
 }
 
-static void yahoo_act_id(PurpleConnection *gc, PurpleRequestFields *fields)
+static void yahoo_act_id(PurpleConnection *gc, const char *entry)
 {
 	struct yahoo_data *yd = gc->proto_data;
-	const char *name = yd->profiles[purple_request_fields_get_choice(fields, "id")];
 
 	struct yahoo_packet *pkt = yahoo_packet_new(YAHOO_SERVICE_IDACT, YAHOO_STATUS_AVAILABLE, 0);
-	yahoo_packet_hash_str(pkt, 3, name);
+	yahoo_packet_hash_str(pkt, 3, entry);
 	yahoo_packet_send_and_free(pkt, yd);
 
-	purple_connection_set_display_name(gc, name);
+	purple_connection_set_display_name(gc, entry);
 }
 
 static void
@@ -3295,28 +3290,9 @@ static void yahoo_show_act_id(PurplePlug
 
 static void yahoo_show_act_id(PurplePluginAction *action)
 {
-	PurpleRequestFields *fields;
-	PurpleRequestFieldGroup *group;
-	PurpleRequestField *field;
 	PurpleConnection *gc = (PurpleConnection *) action->context;
-	struct yahoo_data *yd = purple_connection_get_protocol_data(gc);
-	const char *name = purple_connection_get_display_name(gc);
-	int iter;
-
-	fields = purple_request_fields_new();
-	group = purple_request_field_group_new(NULL);
-	purple_request_fields_add_group(fields, group);
-	field = purple_request_field_choice_new("id", "Activate which ID?", 0);
-	purple_request_field_group_add_field(group, field);
-
-	for (iter = 0; yd->profiles[iter]; iter++) {
-		purple_request_field_choice_add(field, yd->profiles[iter]);
-		if (purple_strequal(yd->profiles[iter], name))
-			purple_request_field_choice_set_default_value(field, iter);
-	}
-
-	purple_request_fields(gc, NULL, _("Select the ID you want to activate"), NULL,
-					   fields,
+	purple_request_input(gc, NULL, _("Activate which ID?"), NULL,
+					   purple_connection_get_display_name(gc), FALSE, FALSE, NULL,
 					   _("OK"), G_CALLBACK(yahoo_act_id),
 					   _("Cancel"), NULL,
 					   purple_connection_get_account(gc), NULL, NULL,
============================================================
--- libpurple/protocols/yahoo/yahoo.h	230197886b9532b82a55d86eb5e873963a518f81
+++ libpurple/protocols/yahoo/yahoo.h	38a6ac8aaada556549e629e5821c3ad850d98bd5
@@ -130,8 +130,6 @@ struct yahoo_data {
 	guint txhandler;
 	GHashTable *friends;
 
-	char **profiles;  /* Multiple profiles can be associated with an account */
-
 	/**
 	 * This is used to keep track of the IMVironment chosen
 	 * by people you talk to.  We don't do very much with


More information about the Commits mailing list