Mercurial > pidgin
comparison src/protocols/toc/toc.c @ 5679:0a0116686d51
[gaim-migrate @ 6097]
let the prpls know about the new API changes
committer: Tailor Script <tailor@pidgin.im>
| author | Nathan Walp <nwalp@pidgin.im> |
|---|---|
| date | Mon, 02 Jun 2003 22:24:07 +0000 |
| parents | 0bdfa28c678e |
| children | 46d7ad0dfa26 |
comparison
equal
deleted
inserted
replaced
| 5678:619bca773b2e | 5679:0a0116686d51 |
|---|---|
| 788 serv_got_chat_in(gc, id, who, w, m, time((time_t)NULL)); | 788 serv_got_chat_in(gc, id, who, w, m, time((time_t)NULL)); |
| 789 } else if (!g_ascii_strcasecmp(c, "CHAT_UPDATE_BUDDY")) { | 789 } else if (!g_ascii_strcasecmp(c, "CHAT_UPDATE_BUDDY")) { |
| 790 int id; | 790 int id; |
| 791 char *in, *buddy; | 791 char *in, *buddy; |
| 792 GSList *bcs = gc->buddy_chats; | 792 GSList *bcs = gc->buddy_chats; |
| 793 struct gaim_conversation *b = NULL; | 793 GaimConversation *b = NULL; |
| 794 struct gaim_chat *chat; | 794 GaimChat *chat; |
| 795 | 795 |
| 796 sscanf(strtok(NULL, ":"), "%d", &id); | 796 sscanf(strtok(NULL, ":"), "%d", &id); |
| 797 in = strtok(NULL, ":"); | 797 in = strtok(NULL, ":"); |
| 798 | 798 |
| 799 chat = GAIM_CHAT(b); | 799 chat = GAIM_CHAT(b); |
| 800 | 800 |
| 801 while (bcs) { | 801 while (bcs) { |
| 802 b = (struct gaim_conversation *)bcs->data; | 802 b = (GaimConversation *)bcs->data; |
| 803 if (id == gaim_chat_get_id(chat)) | 803 if (id == gaim_chat_get_id(chat)) |
| 804 break; | 804 break; |
| 805 bcs = bcs->next; | 805 bcs = bcs->next; |
| 806 b = NULL; | 806 b = NULL; |
| 807 } | 807 } |
| 829 g_hash_table_replace(components, g_strdup("id"), g_strdup_printf("%d", id)); | 829 g_hash_table_replace(components, g_strdup("id"), g_strdup_printf("%d", id)); |
| 830 | 830 |
| 831 serv_got_chat_invite(gc, name, who, message, components); | 831 serv_got_chat_invite(gc, name, who, message, components); |
| 832 } else if (!g_ascii_strcasecmp(c, "CHAT_LEFT")) { | 832 } else if (!g_ascii_strcasecmp(c, "CHAT_LEFT")) { |
| 833 GSList *bcs = gc->buddy_chats; | 833 GSList *bcs = gc->buddy_chats; |
| 834 struct gaim_conversation *b = NULL; | 834 GaimConversation *b = NULL; |
| 835 int id; | 835 int id; |
| 836 | 836 |
| 837 sscanf(strtok(NULL, ":"), "%d", &id); | 837 sscanf(strtok(NULL, ":"), "%d", &id); |
| 838 | 838 |
| 839 while (bcs) { | 839 while (bcs) { |
| 840 b = (struct gaim_conversation *)bcs->data; | 840 b = (GaimConversation *)bcs->data; |
| 841 if (id == gaim_chat_get_id(GAIM_CHAT(b))) | 841 if (id == gaim_chat_get_id(GAIM_CHAT(b))) |
| 842 break; | 842 break; |
| 843 b = NULL; | 843 b = NULL; |
| 844 bcs = bcs->next; | 844 bcs = bcs->next; |
| 845 } | 845 } |
| 1232 } | 1232 } |
| 1233 | 1233 |
| 1234 static void toc_chat_leave(GaimConnection *g, int id) | 1234 static void toc_chat_leave(GaimConnection *g, int id) |
| 1235 { | 1235 { |
| 1236 GSList *bcs = g->buddy_chats; | 1236 GSList *bcs = g->buddy_chats; |
| 1237 struct gaim_conversation *b = NULL; | 1237 GaimConversation *b = NULL; |
| 1238 char buf[BUF_LEN * 2]; | 1238 char buf[BUF_LEN * 2]; |
| 1239 | 1239 |
| 1240 while (bcs) { | 1240 while (bcs) { |
| 1241 b = (struct gaim_conversation *)bcs->data; | 1241 b = (GaimConversation *)bcs->data; |
| 1242 if (id == gaim_chat_get_id(GAIM_CHAT(b))) | 1242 if (id == gaim_chat_get_id(GAIM_CHAT(b))) |
| 1243 break; | 1243 break; |
| 1244 b = NULL; | 1244 b = NULL; |
| 1245 bcs = bcs->next; | 1245 bcs = bcs->next; |
| 1246 } | 1246 } |
