/soc/2013/ankitkv/gobjectification: 18fc361b3704: Renamed purple...

Ankit Vani a at nevitus.org
Sat Aug 31 15:28:42 EDT 2013


Changeset: 18fc361b37047ae4fed029fe88cca63840ecdac9
Author:	 Ankit Vani <a at nevitus.org>
Date:	 2013-09-01 00:38 +0530
Branch:	 soc.2013.gobjectification.plugins
URL: https://hg.pidgin.im/soc/2013/ankitkv/gobjectification/rev/18fc361b3704

Description:

Renamed purple_find_protocol_info to purple_protocols_find

diffstat:

 finch/gntaccount.c                    |   2 +-
 finch/gntblist.c                      |   4 ++--
 finch/gntlog.c                        |   2 +-
 libpurple/account.c                   |   6 +++---
 libpurple/blistnodetypes.c            |   4 ++--
 libpurple/buddylist.c                 |   2 +-
 libpurple/connection.c                |   4 ++--
 libpurple/conversation.c              |   2 +-
 libpurple/log.c                       |   8 ++++----
 libpurple/plugins/idle.c              |   2 +-
 libpurple/plugins/log_reader.c        |   6 +++---
 libpurple/plugins/perl/common/Prpl.xs |   2 +-
 libpurple/server.c                    |   2 +-
 libpurple/util.c                      |   2 +-
 pidgin/gtkaccount.c                   |  10 +++++-----
 pidgin/gtkblist.c                     |  18 +++++++++---------
 pidgin/gtkconv.c                      |   6 +++---
 pidgin/gtkdialogs.c                   |   2 +-
 pidgin/gtklog.c                       |   2 +-
 pidgin/gtkstatusbox.c                 |   6 +++---
 pidgin/gtkthemes.c                    |   2 +-
 pidgin/gtkutils.c                     |   6 +++---
 pidgin/plugins/xmppconsole.c          |   2 +-
 pidgin/smileyparser.c                 |   2 +-
 24 files changed, 52 insertions(+), 52 deletions(-)

diffs (truncated from 540 to 300 lines):

diff --git a/finch/gntaccount.c b/finch/gntaccount.c
--- a/finch/gntaccount.c
+++ b/finch/gntaccount.c
@@ -575,7 +575,7 @@ edit_account_continue(PurpleAccount *acc
 				((PurpleProtocol*)iter->data)->name);
 	}
 
-	protocol = purple_find_protocol_info(purple_account_get_protocol_id(account));
+	protocol = purple_protocols_find(purple_account_get_protocol_id(account));
 
 	if (account && protocol)
 		gnt_combo_box_set_selected(GNT_COMBO_BOX(combo), protocol);
diff --git a/finch/gntblist.c b/finch/gntblist.c
--- a/finch/gntblist.c
+++ b/finch/gntblist.c
@@ -1415,7 +1415,7 @@ static void showlog_cb(PurpleBlistNode *
 		PurpleProtocol *protocol = NULL;
 		type = PURPLE_LOG_CHAT;
 		account = purple_chat_get_account(c);
-		protocol = purple_find_protocol_info(purple_account_get_protocol_id(account));
+		protocol = purple_protocols_find(purple_account_get_protocol_id(account));
 		if (protocol && protocol->get_chat_name) {
 			name = purple_protocol_iface_get_chat_name(protocol, purple_chat_get_components(c));
 		}
@@ -1737,7 +1737,7 @@ tooltip_for_buddy(PurpleBuddy *buddy, GS
 	purple_notify_user_info_add_pair_plaintext(user_info, _("Account"), tmp);
 	g_free(tmp);
 
-	protocol = purple_find_protocol_info(purple_account_get_protocol_id(account));
+	protocol = purple_protocols_find(purple_account_get_protocol_id(account));
 	if (protocol && protocol->tooltip_text) {
 		purple_protocol_iface_tooltip_text(protocol, buddy, user_info, full);
 	}
diff --git a/finch/gntlog.c b/finch/gntlog.c
--- a/finch/gntlog.c
+++ b/finch/gntlog.c
@@ -505,7 +505,7 @@ void finch_syslog_show()
 	for(accounts = purple_accounts_get_all(); accounts != NULL; accounts = accounts->next) {
 
 		PurpleAccount *account = (PurpleAccount *)accounts->data;
-		if(purple_find_protocol_info(purple_account_get_protocol_id(account)) == NULL)
+		if(purple_protocols_find(purple_account_get_protocol_id(account)) == NULL)
 			continue;
 
 		logs = g_list_concat(purple_log_get_system_logs(account), logs);
diff --git a/libpurple/account.c b/libpurple/account.c
--- a/libpurple/account.c
+++ b/libpurple/account.c
@@ -323,7 +323,7 @@ purple_account_connect(PurpleAccount *ac
 		return;
 	}
 
-	protocol = purple_find_protocol_info(purple_account_get_protocol_id(account));
+	protocol = purple_protocols_find(purple_account_get_protocol_id(account));
 	if (protocol == NULL) {
 		gchar *message;
 
@@ -1424,7 +1424,7 @@ purple_account_get_protocol_name(const P
 
 	g_return_val_if_fail(account != NULL, NULL);
 
-	p = purple_find_protocol_info(purple_account_get_protocol_id(account));
+	p = purple_protocols_find(purple_account_get_protocol_id(account));
 
 	return (p && purple_protocol_get_name(p) ?
 	        _(purple_protocol_get_name(p)) : _("Unknown"));
@@ -2882,7 +2882,7 @@ purple_account_constructed(GObject *obje
 	purple_signal_emit(purple_accounts_get_handle(), "account-created",
 			account);
 
-	protocol = purple_find_protocol_info(protocol_id);
+	protocol = purple_protocols_find(protocol_id);
 	if (protocol == NULL) {
 		g_free(username);
 		g_free(protocol_id);
diff --git a/libpurple/blistnodetypes.c b/libpurple/blistnodetypes.c
--- a/libpurple/blistnodetypes.c
+++ b/libpurple/blistnodetypes.c
@@ -634,7 +634,7 @@ purple_buddy_dispose(GObject *object)
 	 * Tell the owner PRPL that we're about to free the buddy so it
 	 * can free proto_data
 	 */
-	protocol = purple_find_protocol_info(purple_account_get_protocol_id(priv->account));
+	protocol = purple_protocols_find(purple_account_get_protocol_id(priv->account));
 	if (protocol)
 		purple_protocol_iface_buddy_free(protocol, buddy);
 
@@ -1120,7 +1120,7 @@ const char *purple_chat_get_name_only(Pu
 
 	g_return_val_if_fail(priv != NULL, NULL);
 
-	protocol = purple_find_protocol_info(purple_account_get_protocol_id(priv->account));
+	protocol = purple_protocols_find(purple_account_get_protocol_id(priv->account));
 
 	if (PURPLE_PROTOCOL_IMPLEMENTS(protocol, chat_info)) {
 		PurpleProtocolChatEntry *pce;
diff --git a/libpurple/buddylist.c b/libpurple/buddylist.c
--- a/libpurple/buddylist.c
+++ b/libpurple/buddylist.c
@@ -1634,7 +1634,7 @@ purple_blist_find_chat(PurpleAccount *ac
 	if (!purple_account_is_connected(account))
 		return NULL;
 
-	protocol = purple_find_protocol_info(purple_account_get_protocol_id(account));
+	protocol = purple_protocols_find(purple_account_get_protocol_id(account));
 
 	if (PURPLE_PROTOCOL_IMPLEMENTS(protocol, find_blist_chat))
 		return purple_protocol_iface_find_blist_chat(protocol, account, name);
diff --git a/libpurple/connection.c b/libpurple/connection.c
--- a/libpurple/connection.c
+++ b/libpurple/connection.c
@@ -872,7 +872,7 @@ void
 	if (!purple_account_is_disconnected(account))
 		return;
 
-	protocol = purple_find_protocol_info(purple_account_get_protocol_id(account));
+	protocol = purple_protocols_find(purple_account_get_protocol_id(account));
 
 	if (protocol == NULL) {
 		gchar *message;
@@ -936,7 +936,7 @@ void
 
 	g_return_if_fail(account != NULL);
 
-	protocol = purple_find_protocol_info(purple_account_get_protocol_id(account));
+	protocol = purple_protocols_find(purple_account_get_protocol_id(account));
 
 	if (protocol == NULL) {
 		gchar *message;
diff --git a/libpurple/conversation.c b/libpurple/conversation.c
--- a/libpurple/conversation.c
+++ b/libpurple/conversation.c
@@ -528,7 +528,7 @@ purple_conversation_write(PurpleConversa
 	}
 
 	if (account != NULL) {
-		protocol = purple_find_protocol_info(purple_account_get_protocol_id(account));
+		protocol = purple_protocols_find(purple_account_get_protocol_id(account));
 
 		if (PURPLE_IS_IM_CONVERSATION(conv) ||
 			!(purple_protocol_get_options(protocol) & OPT_PROTO_UNIQUE_CHATNAME)) {
diff --git a/libpurple/log.c b/libpurple/log.c
--- a/libpurple/log.c
+++ b/libpurple/log.c
@@ -342,7 +342,7 @@ purple_log_get_log_dir(PurpleLogType typ
 	const char *target;
 	char *dir;
 
-	protocol = purple_find_protocol_info(purple_account_get_protocol_id(account));
+	protocol = purple_protocols_find(purple_account_get_protocol_id(account));
 	if (!protocol)
 		return NULL;
 
@@ -1105,7 +1105,7 @@ static void log_get_log_sets_common(GHas
 		for (account_iter = purple_accounts_get_all() ; account_iter != NULL ; account_iter = account_iter->next) {
 			PurpleProtocol *protocol;
 
-			protocol = purple_find_protocol_info(purple_account_get_protocol_id((PurpleAccount *)account_iter->data));
+			protocol = purple_protocols_find(purple_account_get_protocol_id((PurpleAccount *)account_iter->data));
 			if (!protocol)
 				continue;
 
@@ -1404,7 +1404,7 @@ static gsize html_logger_write(PurpleLog
 	char *header;
 	char *escaped_from;
 	PurpleProtocol *protocol =
-			purple_find_protocol_info(purple_account_get_protocol_id(log->account));
+			purple_protocols_find(purple_account_get_protocol_id(log->account));
 	PurpleLogCommonLoggerData *data = log->logger_data;
 	gsize written = 0;
 
@@ -1559,7 +1559,7 @@ static gsize txt_logger_write(PurpleLog 
 {
 	char *date;
 	PurpleProtocol *protocol =
-			purple_find_protocol_info(purple_account_get_protocol_id(log->account));
+			purple_protocols_find(purple_account_get_protocol_id(log->account));
 	PurpleLogCommonLoggerData *data = log->logger_data;
 	char *stripped = NULL;
 
diff --git a/libpurple/plugins/idle.c b/libpurple/plugins/idle.c
--- a/libpurple/plugins/idle.c
+++ b/libpurple/plugins/idle.c
@@ -53,7 +53,7 @@ idleable_filter(PurpleAccount *account)
 {
 	PurplePlugin *prpl;
 
-	prpl = purple_find_protocol_info(purple_account_get_protocol_id(account));
+	prpl = purple_protocols_find(purple_account_get_protocol_id(account));
 	g_return_val_if_fail(prpl != NULL, FALSE);
 
 	return (PURPLE_PLUGIN_PROTOCOL_INFO(prpl)->set_idle != NULL);
diff --git a/libpurple/plugins/log_reader.c b/libpurple/plugins/log_reader.c
--- a/libpurple/plugins/log_reader.c
+++ b/libpurple/plugins/log_reader.c
@@ -82,7 +82,7 @@ static GList *adium_logger_list(PurpleLo
 	if (!logdir || !*logdir)
 		return NULL;
 
-	plugin = purple_find_protocol_info(purple_account_get_protocol_id(account));
+	plugin = purple_protocols_find(purple_account_get_protocol_id(account));
 	if (!plugin)
 		return NULL;
 
@@ -1226,7 +1226,7 @@ static GList *trillian_logger_list(Purpl
 	if (!logdir || !*logdir)
 		return NULL;
 
-	plugin = purple_find_protocol_info(purple_account_get_protocol_id(account));
+	plugin = purple_protocols_find(purple_account_get_protocol_id(account));
 	if (!plugin)
 		return NULL;
 
@@ -1786,7 +1786,7 @@ static GList *qip_logger_list(PurpleLogT
 	if (!logdir || !*logdir)
 		return NULL;
 
-	plugin = purple_find_protocol_info(purple_account_get_protocol_id(account));
+	plugin = purple_protocols_find(purple_account_get_protocol_id(account));
 	if (!plugin)
 		return NULL;
 
diff --git a/libpurple/plugins/perl/common/Prpl.xs b/libpurple/plugins/perl/common/Prpl.xs
--- a/libpurple/plugins/perl/common/Prpl.xs
+++ b/libpurple/plugins/perl/common/Prpl.xs
@@ -4,7 +4,7 @@ MODULE = Purple::Prpl  PACKAGE = Purple:
 PROTOTYPES: ENABLE
 
 Purple::Plugin
-purple_find_protocol_info(id)
+purple_protocols_find(id)
 	const char *id
 
 MODULE = Purple::Prpl  PACKAGE = Purple::Prpl  PREFIX = purple_protocol_
diff --git a/libpurple/server.c b/libpurple/server.c
--- a/libpurple/server.c
+++ b/libpurple/server.c
@@ -297,7 +297,7 @@ PurpleAttentionType *purple_get_attentio
 
 	g_return_val_if_fail(account != NULL, NULL);
 
-	protocol = purple_find_protocol_info(purple_account_get_protocol_id(account));
+	protocol = purple_protocols_find(purple_account_get_protocol_id(account));
 
 	/* Lookup the attention type in the protocol's attention_types list, if any. */
 	get_attention_types = protocol->get_attention_types;
diff --git a/libpurple/util.c b/libpurple/util.c
--- a/libpurple/util.c
+++ b/libpurple/util.c
@@ -3390,7 +3390,7 @@ purple_normalize(const PurpleAccount *ac
 	if (account != NULL)
 	{
 		PurpleProtocol *protocol =
-				purple_find_protocol_info(purple_account_get_protocol_id(account));
+				purple_protocols_find(purple_account_get_protocol_id(account));
 
 		if (protocol != NULL && protocol->normalize)
 			ret = purple_protocol_iface_normalize(protocol, account, str);
diff --git a/pidgin/gtkaccount.c b/pidgin/gtkaccount.c
--- a/pidgin/gtkaccount.c
+++ b/pidgin/gtkaccount.c
@@ -236,7 +236,7 @@ set_account_protocol_cb(GtkWidget *widge
 {
 	PurpleProtocol *new_protocol;
 
-	new_protocol = purple_find_protocol_info(id);
+	new_protocol = purple_protocols_find(id);
 
 	dialog->protocol = new_protocol;
 	g_free(dialog->protocol_id);
@@ -1741,7 +1741,7 @@ pidgin_account_dialog_show_continue(Purp
 	if (!dialog->protocol_id)
 		return;
 
-	dialog->protocol = purple_find_protocol_info(dialog->protocol_id);
+	dialog->protocol = purple_protocols_find(dialog->protocol_id);
 
 	dialog->window = win = pidgin_create_dialog((type == PIDGIN_ADD_ACCOUNT_DIALOG) ? _("Add Account") : _("Modify Account"),
 		PIDGIN_HIG_BOX_SPACE, "account", FALSE);
@@ -2247,7 +2247,7 @@ set_account(GtkListStore *store, GtkTree
 	if ((pixbuf != NULL) && purple_account_is_disconnected(account))
 		gdk_pixbuf_saturate_and_pixelate(pixbuf, pixbuf, 0.0, FALSE);
 
-	protocol = purple_find_protocol_info(purple_account_get_protocol_id(account));
+	protocol = purple_protocols_find(purple_account_get_protocol_id(account));
 	if (protocol != NULL && purple_protocol_get_icon_spec(protocol).format != NULL) {
 		if (purple_account_get_bool(account, "use-global-buddyicon", TRUE)) {
 			if (global_buddyicon != NULL)
@@ -2710,7 +2710,7 @@ authorize_reason_cb(struct auth_request 
 	PurpleProtocol *protocol = NULL;
 
 	protocol_id = purple_account_get_protocol_id(ar->account);
-	protocol = purple_find_protocol_info(protocol_id);
+	protocol = purple_protocols_find(protocol_id);
 
 	if (protocol && (purple_protocol_get_options(protocol) & OPT_PROTO_AUTHORIZATION_GRANTED_MESSAGE)) {
 		/* Duplicate information because ar is freed by closing minidialog */
@@ -2753,7 +2753,7 @@ deny_reason_cb(struct auth_request *ar)
 	PurpleProtocol *protocol = NULL;
 



More information about the Commits mailing list