| 703 |
703 |
| 704 name = purple_chat_get_name_only(chat); |
704 name = purple_chat_get_name_only(chat); |
| 705 conv = purple_conversations_find_chat_with_account(name, account); |
705 conv = purple_conversations_find_chat_with_account(name, account); |
| 706 |
706 |
| 707 if (!conv || purple_chat_conversation_has_left(conv)) { |
707 if (!conv || purple_chat_conversation_has_left(conv)) { |
| 708 serv_join_chat(purple_account_get_connection(account), |
708 purple_serv_join_chat(purple_account_get_connection(account), |
| 709 purple_chat_get_components(chat)); |
709 purple_chat_get_components(chat)); |
| 710 } else if (conv) { |
710 } else if (conv) { |
| 711 purple_conversation_present(PURPLE_CONVERSATION(conv)); |
711 purple_conversation_present(PURPLE_CONVERSATION(conv)); |
| 712 } |
712 } |
| 713 } |
713 } |
| 1209 gpointer uihandle; |
1209 gpointer uihandle; |
| 1210 purple_notify_user_info_add_pair_plaintext(info, _("Information"), _("Retrieving...")); |
1210 purple_notify_user_info_add_pair_plaintext(info, _("Information"), _("Retrieving...")); |
| 1211 uihandle = purple_notify_userinfo(conn, name, info, NULL, NULL); |
1211 uihandle = purple_notify_userinfo(conn, name, info, NULL, NULL); |
| 1212 purple_notify_user_info_destroy(info); |
1212 purple_notify_user_info_destroy(info); |
| 1213 |
1213 |
| 1214 serv_get_info(conn, name); |
1214 purple_serv_get_info(conn, name); |
| 1215 return uihandle; |
1215 return uihandle; |
| 1216 } |
1216 } |
| 1217 |
1217 |
| 1218 static void |
1218 static void |
| 1219 finch_blist_get_buddy_info_cb(PurpleBlistNode *selected, PurpleBuddy *buddy) |
1219 finch_blist_get_buddy_info_cb(PurpleBlistNode *selected, PurpleBuddy *buddy) |
| 1222 } |
1222 } |
| 1223 |
1223 |
| 1224 static void |
1224 static void |
| 1225 finch_blist_menu_send_file_cb(PurpleBlistNode *selected, PurpleBuddy *buddy) |
1225 finch_blist_menu_send_file_cb(PurpleBlistNode *selected, PurpleBuddy *buddy) |
| 1226 { |
1226 { |
| 1227 serv_send_file(purple_account_get_connection(purple_buddy_get_account(buddy)), purple_buddy_get_name(buddy), NULL); |
1227 purple_serv_send_file(purple_account_get_connection(purple_buddy_get_account(buddy)), purple_buddy_get_name(buddy), NULL); |
| 1228 } |
1228 } |
| 1229 |
1229 |
| 1230 static void |
1230 static void |
| 1231 finch_blist_pounce_node_cb(PurpleBlistNode *selected, PurpleBlistNode *node) |
1231 finch_blist_pounce_node_cb(PurpleBlistNode *selected, PurpleBlistNode *node) |
| 1232 { |
1232 { |
| 1346 if (PURPLE_IS_CONTACT(node)) { |
1346 if (PURPLE_IS_CONTACT(node)) { |
| 1347 PurpleContact *contact = (PurpleContact*)node; |
1347 PurpleContact *contact = (PurpleContact*)node; |
| 1348 PurpleBuddy *buddy = purple_contact_get_priority_buddy(contact); |
1348 PurpleBuddy *buddy = purple_contact_get_priority_buddy(contact); |
| 1349 purple_contact_set_alias(contact, name); |
1349 purple_contact_set_alias(contact, name); |
| 1350 purple_buddy_set_local_alias(buddy, name); |
1350 purple_buddy_set_local_alias(buddy, name); |
| 1351 serv_alias_buddy(buddy); |
1351 purple_serv_alias_buddy(buddy); |
| 1352 } else if (PURPLE_IS_BUDDY(node)) { |
1352 } else if (PURPLE_IS_BUDDY(node)) { |
| 1353 purple_buddy_set_local_alias((PurpleBuddy*)node, name); |
1353 purple_buddy_set_local_alias((PurpleBuddy*)node, name); |
| 1354 serv_alias_buddy((PurpleBuddy*)node); |
1354 purple_serv_alias_buddy((PurpleBuddy*)node); |
| 1355 } else if (PURPLE_IS_CHAT(node)) |
1355 } else if (PURPLE_IS_CHAT(node)) |
| 1356 purple_chat_set_alias((PurpleChat*)node, name); |
1356 purple_chat_set_alias((PurpleChat*)node, name); |
| 1357 else if (PURPLE_IS_GROUP(node) && (name != NULL)) |
1357 else if (PURPLE_IS_GROUP(node) && (name != NULL)) |
| 1358 purple_group_set_name((PurpleGroup*)node, name); |
1358 purple_group_set_name((PurpleGroup*)node, name); |
| 1359 else |
1359 else |
| 2615 node = purple_blist_node_next(node, FALSE)) { |
2615 node = purple_blist_node_next(node, FALSE)) { |
| 2616 if (PURPLE_IS_CHAT(node)) { |
2616 if (PURPLE_IS_CHAT(node)) { |
| 2617 PurpleChat *chat = (PurpleChat*)node; |
2617 PurpleChat *chat = (PurpleChat*)node; |
| 2618 if (purple_chat_get_account(chat) == account && |
2618 if (purple_chat_get_account(chat) == account && |
| 2619 purple_blist_node_get_bool(node, "gnt-autojoin")) |
2619 purple_blist_node_get_bool(node, "gnt-autojoin")) |
| 2620 serv_join_chat(purple_account_get_connection(account), purple_chat_get_components(chat)); |
2620 purple_serv_join_chat(purple_account_get_connection(account), purple_chat_get_components(chat)); |
| 2621 } |
2621 } |
| 2622 } |
2622 } |
| 2623 return FALSE; |
2623 return FALSE; |
| 2624 } |
2624 } |
| 2625 |
2625 |
| 2777 if (info->chat_info_defaults != NULL) |
2777 if (info->chat_info_defaults != NULL) |
| 2778 hash = info->chat_info_defaults(gc, name); |
2778 hash = info->chat_info_defaults(gc, name); |
| 2779 } else { |
2779 } else { |
| 2780 hash = purple_chat_get_components(chat); |
2780 hash = purple_chat_get_components(chat); |
| 2781 } |
2781 } |
| 2782 serv_join_chat(gc, hash); |
2782 purple_serv_join_chat(gc, hash); |
| 2783 if (chat == NULL && hash != NULL) |
2783 if (chat == NULL && hash != NULL) |
| 2784 g_hash_table_destroy(hash); |
2784 g_hash_table_destroy(hash); |
| 2785 } |
2785 } |
| 2786 |
2786 |
| 2787 static void |
2787 static void |