comparison src/conversation.c @ 4687:283fb289c510

[gaim-migrate @ 4998] This is a new buddy list. Lots of things about it just Don't Work. I probably already know about those things, and you'd just be wasting my time in submitting a bug report about it. I decided that instead of getting it to all work perfectly before committing, that I'd get it in cvs, and slowly fix it with regular commits. That way, it's easier to keep track of things, and other developers can help. Plus, I'm getting pissed off at the buddy list and want it to die. It's kinda boring, and doing nothing but the buddy list for such a long time has just gotten me very bitter. After 0.60 is released later this week, Gaim will resume being fun. This week is going to be very stressful, though, I'm sure. Things you ought to know about this buddy list: - It crashes - It leaks - There's no way to edit the buddy list, or access offline buddies - Most of the menus and buttons and whatnot just plain ol' don't work. - Status icons are only implemented for AIM. That's mostly just because I'm lazy. As such, you may want to be wary of updating this. If you do decide to update this, you may want to learn "cvs update -D yesterday" as well :) All the art there is just placeholder art. You probably won't really have as many problems as it sounds like you will from reading this. This message is extra-negative to stress that I don't want to be bothered with complaints about something not working about it :). I'll repeat: If something doesn't work, I probably already know about it. If you want to actually help with something, I'd be delighted to have it. IM me. -s. committer: Tailor Script <tailor@pidgin.im>
author Sean Egan <seanegan@gmail.com>
date Mon, 10 Mar 2003 05:30:31 +0000
parents ba87412b1a57
children 677d3cb193a1
comparison
equal deleted inserted replaced
4686:a1de8a9c99ba 4687:283fb289c510
1161 1161
1162 account = gaim_conversation_get_account(conv); 1162 account = gaim_conversation_get_account(conv);
1163 name = gaim_conversation_get_name(conv); 1163 name = gaim_conversation_get_name(conv);
1164 1164
1165 if (((im_options & OPT_IM_ALIAS_TAB) == OPT_IM_ALIAS_TAB) && 1165 if (((im_options & OPT_IM_ALIAS_TAB) == OPT_IM_ALIAS_TAB) &&
1166 account != NULL && ((b = find_buddy(account, name)) != NULL)) { 1166 account != NULL && ((b = gaim_find_buddy(account, name)) != NULL)) {
1167 1167
1168 text = get_buddy_alias(b); 1168 text = gaim_get_buddy_alias(b);
1169 } 1169 }
1170 else 1170 else
1171 text = name; 1171 text = name;
1172 1172
1173 gaim_conversation_set_title(conv, text); 1173 gaim_conversation_set_title(conv, text);
1414 1414
1415 if (gaim_conversation_get_type(conv) == GAIM_CONV_IM || 1415 if (gaim_conversation_get_type(conv) == GAIM_CONV_IM ||
1416 !(account->gc->prpl->options & OPT_PROTO_UNIQUE_CHATNAME)) { 1416 !(account->gc->prpl->options & OPT_PROTO_UNIQUE_CHATNAME)) {
1417 1417
1418 if (who == NULL) { 1418 if (who == NULL) {
1419 if ((flags & WFLAG_SEND)) { 1419 if (flags & WFLAG_SEND) {
1420 b = find_buddy(account, account->gc->username); 1420 b = gaim_find_buddy(account, account->gc->username);
1421 1421 if (b != NULL && strcmp(b->name, gaim_get_buddy_alias(b)))
1422 if (b != NULL && strcmp(b->name, get_buddy_alias(b))) 1422 who = gaim_get_buddy_alias(b);
1423 who = get_buddy_alias(b);
1424 else if (*account->alias) 1423 else if (*account->alias)
1425 who = account->alias; 1424 who = account->alias;
1426 else if (*account->gc->displayname) 1425 else if (*account->gc->displayname)
1427 who = account->gc->displayname; 1426 who = account->gc->displayname;
1428 else 1427 else
1429 who = account->gc->username; 1428 who = account->gc->username;
1430 } 1429 }
1431 else { 1430 else {
1432 b = find_buddy(account, gaim_conversation_get_name(conv)); 1431 b = gaim_find_buddy(account, gaim_conversation_get_name(conv));
1433 1432
1434 if (b != NULL) 1433 if (b != NULL)
1435 who = get_buddy_alias(b); 1434 who = gaim_get_buddy_alias(b);
1436 else 1435 else
1437 who = gaim_conversation_get_name(conv); 1436 who = gaim_conversation_get_name(conv);
1438 } 1437 }
1439 } 1438 }
1440 else { 1439 else {
1441 b = find_buddy(account, who); 1440 b = gaim_find_buddy(account, who);
1442 1441
1443 if (b != NULL) 1442 if (b != NULL)
1444 who = get_buddy_alias(b); 1443 who = gaim_get_buddy_alias(b);
1445 } 1444 }
1446 } 1445 }
1447 1446
1448 ops->write_conv(conv, who, message, length, flags, mtime); 1447 ops->write_conv(conv, who, message, length, flags, mtime);
1449 1448
2114 else { 2113 else {
2115 struct buddy *b; 2114 struct buddy *b;
2116 struct group *grp = NULL; 2115 struct group *grp = NULL;
2117 GList *wins, *convs; 2116 GList *wins, *convs;
2118 2117
2119 b = find_buddy(gaim_conversation_get_account(conv), 2118 b = gaim_find_buddy(gaim_conversation_get_account(conv),
2120 gaim_conversation_get_name(conv)); 2119 gaim_conversation_get_name(conv));
2121 2120
2122 if (b != NULL) 2121 if (b != NULL)
2123 grp = find_group_by_buddy(b); 2122 grp = gaim_find_buddys_group(b);
2124 2123
2125 /* Go through the list of IMs and find one with this group. */ 2124 /* Go through the list of IMs and find one with this group. */
2126 for (wins = gaim_get_windows(); wins != NULL; wins = wins->next) { 2125 for (wins = gaim_get_windows(); wins != NULL; wins = wins->next) {
2127 struct gaim_window *win2; 2126 struct gaim_window *win2;
2128 struct gaim_conversation *conv2; 2127 struct gaim_conversation *conv2;
2135 convs != NULL; 2134 convs != NULL;
2136 convs = convs->next) { 2135 convs = convs->next) {
2137 2136
2138 conv2 = (struct gaim_conversation *)convs->data; 2137 conv2 = (struct gaim_conversation *)convs->data;
2139 2138
2140 b2 = find_buddy(gaim_conversation_get_account(conv2), 2139 b2 = gaim_find_buddy(gaim_conversation_get_account(conv2),
2141 gaim_conversation_get_name(conv2)); 2140 gaim_conversation_get_name(conv2));
2142 2141
2143 if (b2 != NULL) 2142 if (b2 != NULL)
2144 g2 = find_group_by_buddy(b2); 2143 g2 = gaim_find_buddys_group(b2);
2145 2144
2146 if (grp == g2) { 2145 if (grp == g2) {
2147 gaim_window_add_conversation(win2, conv); 2146 gaim_window_add_conversation(win2, conv);
2148 2147
2149 return; 2148 return;