Mercurial > pidgin
diff finch/gntconv.c @ 22213:16ff37f64e29
Update finch to not touch the internals of PurpleAccount. This also includes a change I made to reduce the Cyclomatic Complexity of one of the functions.
author | Sadrul Habib Chowdhury <imadil@gmail.com> |
---|---|
date | Sat, 26 Jan 2008 20:45:41 +0000 |
parents | 6bb29f94862c |
children | 2b426862ffbf |
line wrap: on
line diff
--- a/finch/gntconv.c Sat Jan 26 20:32:26 2008 +0000 +++ b/finch/gntconv.c Sat Jan 26 20:45:41 2008 +0000 @@ -531,7 +531,8 @@ if (purple_conversation_get_type(ggc->active_conv) == PURPLE_CONV_TYPE_IM) { PurpleAccount *account = purple_conversation_get_account(ggc->active_conv); - PurplePluginProtocolInfo *pinfo = account->gc ? PURPLE_PLUGIN_PROTOCOL_INFO(account->gc->prpl) : NULL; + PurpleConnection *gc = purple_account_get_connection(account); + PurplePluginProtocolInfo *pinfo = gc ? PURPLE_PLUGIN_PROTOCOL_INFO(gc->prpl) : NULL; if (pinfo && pinfo->get_info) { item = gnt_menuitem_new(_("Get Info")); @@ -545,7 +546,7 @@ if (pinfo && pinfo->send_file && (!pinfo->can_receive_file || - pinfo->can_receive_file(account->gc, purple_conversation_get_name(ggc->active_conv)))) { + pinfo->can_receive_file(gc, purple_conversation_get_name(ggc->active_conv)))) { item = gnt_menuitem_new(_("Send File")); gnt_menu_add_item(GNT_MENU(sub), item); gnt_menuitem_set_callback(item, send_file_cb, ggc);