Mercurial > pidgin
comparison src/conversation.c @ 6695:0c5637b5462e
[gaim-migrate @ 7221]
This is contact support. Really.
It has a few bugs left in it, like sorting not working, and stuff like that,
but it's pretty solid for the most part.
I'm not in the mood to do a whole lot of typing, so just use and enjoy.
committer: Tailor Script <tailor@pidgin.im>
author | Nathan Walp <nwalp@pidgin.im> |
---|---|
date | Tue, 02 Sep 2003 03:41:10 +0000 |
parents | 314111e7b601 |
children | e9a730ad5a3c |
comparison
equal
deleted
inserted
replaced
6694:2d2f04c5c7d2 | 6695:0c5637b5462e |
---|---|
1193 | 1193 |
1194 void | 1194 void |
1195 gaim_conversation_autoset_title(GaimConversation *conv) | 1195 gaim_conversation_autoset_title(GaimConversation *conv) |
1196 { | 1196 { |
1197 GaimAccount *account; | 1197 GaimAccount *account; |
1198 struct buddy *b; | 1198 GaimBuddy *b; |
1199 const char *text, *name; | 1199 const char *text, *name; |
1200 | 1200 |
1201 g_return_if_fail(conv != NULL); | 1201 g_return_if_fail(conv != NULL); |
1202 | 1202 |
1203 account = gaim_conversation_get_account(conv); | 1203 account = gaim_conversation_get_account(conv); |
1435 GaimPluginProtocolInfo *prpl_info = NULL; | 1435 GaimPluginProtocolInfo *prpl_info = NULL; |
1436 GaimConnection *gc = NULL; | 1436 GaimConnection *gc = NULL; |
1437 GaimAccount *account; | 1437 GaimAccount *account; |
1438 GaimConversationUiOps *ops; | 1438 GaimConversationUiOps *ops; |
1439 GaimWindow *win; | 1439 GaimWindow *win; |
1440 struct buddy *b; | 1440 GaimBuddy *b; |
1441 GaimUnseenState unseen; | 1441 GaimUnseenState unseen; |
1442 /* int logging_font_options = 0; */ | 1442 /* int logging_font_options = 0; */ |
1443 | 1443 |
1444 g_return_if_fail(conv != NULL); | 1444 g_return_if_fail(conv != NULL); |
1445 g_return_if_fail(message != NULL); | 1445 g_return_if_fail(message != NULL); |
1469 !(prpl_info->options & OPT_PROTO_UNIQUE_CHATNAME)) { | 1469 !(prpl_info->options & OPT_PROTO_UNIQUE_CHATNAME)) { |
1470 | 1470 |
1471 if (who == NULL) { | 1471 if (who == NULL) { |
1472 if (flags & GAIM_MESSAGE_SEND) { | 1472 if (flags & GAIM_MESSAGE_SEND) { |
1473 b = gaim_find_buddy(account, | 1473 b = gaim_find_buddy(account, |
1474 gaim_account_get_username(account)); | 1474 gaim_account_get_username(account)); |
1475 | 1475 |
1476 if (b != NULL && strcmp(b->name, gaim_get_buddy_alias(b))) | 1476 if (b != NULL && strcmp(b->name, gaim_get_buddy_alias(b))) |
1477 who = gaim_get_buddy_alias(b); | 1477 who = gaim_get_buddy_alias(b); |
1478 else if (gaim_account_get_alias(account) != NULL) | 1478 else if (gaim_account_get_alias(account) != NULL) |
1479 who = account->alias; | 1479 who = account->alias; |
2268 GaimConversationType type; | 2268 GaimConversationType type; |
2269 | 2269 |
2270 type = gaim_conversation_get_type(conv); | 2270 type = gaim_conversation_get_type(conv); |
2271 | 2271 |
2272 if (type == GAIM_CONV_IM) { | 2272 if (type == GAIM_CONV_IM) { |
2273 struct buddy *b; | 2273 GaimBuddy *b; |
2274 struct group *grp = NULL; | 2274 GaimGroup *grp = NULL; |
2275 GList *wins, *convs; | 2275 GList *wins, *convs; |
2276 | 2276 |
2277 b = gaim_find_buddy(gaim_conversation_get_account(conv), | 2277 b = gaim_find_buddy(gaim_conversation_get_account(conv), |
2278 gaim_conversation_get_name(conv)); | 2278 gaim_conversation_get_name(conv)); |
2279 | 2279 |
2282 | 2282 |
2283 /* Go through the list of IMs and find one with this group. */ | 2283 /* Go through the list of IMs and find one with this group. */ |
2284 for (wins = gaim_get_windows(); wins != NULL; wins = wins->next) { | 2284 for (wins = gaim_get_windows(); wins != NULL; wins = wins->next) { |
2285 GaimWindow *win2; | 2285 GaimWindow *win2; |
2286 GaimConversation *conv2; | 2286 GaimConversation *conv2; |
2287 struct buddy *b2; | 2287 GaimBuddy *b2; |
2288 struct group *g2 = NULL; | 2288 GaimGroup *g2 = NULL; |
2289 | 2289 |
2290 win2 = (GaimWindow *)wins->data; | 2290 win2 = (GaimWindow *)wins->data; |
2291 | 2291 |
2292 for (convs = gaim_window_get_conversations(win2); | 2292 for (convs = gaim_window_get_conversations(win2); |
2293 convs != NULL; | 2293 convs != NULL; |
2311 | 2311 |
2312 /* Make a new window. */ | 2312 /* Make a new window. */ |
2313 conv_placement_new_window(conv); | 2313 conv_placement_new_window(conv); |
2314 } | 2314 } |
2315 else if (type == GAIM_CONV_CHAT) { | 2315 else if (type == GAIM_CONV_CHAT) { |
2316 struct chat *chat; | 2316 GaimBlistChat *chat; |
2317 struct group *group = NULL; | 2317 GaimGroup *group = NULL; |
2318 GList *wins, *convs; | 2318 GList *wins, *convs; |
2319 | 2319 |
2320 chat = gaim_blist_find_chat(gaim_conversation_get_account(conv), | 2320 chat = gaim_blist_find_chat(gaim_conversation_get_account(conv), |
2321 gaim_conversation_get_name(conv)); | 2321 gaim_conversation_get_name(conv)); |
2322 | 2322 |
2325 | 2325 |
2326 /* Go through the list of chats and find one with this group. */ | 2326 /* Go through the list of chats and find one with this group. */ |
2327 for (wins = gaim_get_windows(); wins != NULL; wins = wins->next) { | 2327 for (wins = gaim_get_windows(); wins != NULL; wins = wins->next) { |
2328 GaimWindow *win2; | 2328 GaimWindow *win2; |
2329 GaimConversation *conv2; | 2329 GaimConversation *conv2; |
2330 struct chat *chat2; | 2330 GaimBlistChat *chat2; |
2331 struct group *group2 = NULL; | 2331 GaimGroup *group2 = NULL; |
2332 | 2332 |
2333 win2 = (GaimWindow *)wins->data; | 2333 win2 = (GaimWindow *)wins->data; |
2334 | 2334 |
2335 for (convs = gaim_window_get_conversations(win2); | 2335 for (convs = gaim_window_get_conversations(win2); |
2336 convs != NULL; | 2336 convs != NULL; |