Changeset 64bed24 for protocols/skype
- Timestamp:
- 2015-10-13T05:05:22Z (9 years ago)
- Branches:
- master
- Children:
- 0b1ae59
- Parents:
- fdc6d84
- Location:
- protocols/skype
- Files:
-
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
protocols/skype/skype.c
rfdc6d84 r64bed24 323 323 } 324 324 325 static struct groupchat *skype_chat_get_or_create(struct im_connection *ic, char *id) 326 { 327 struct skype_data *sd = ic->proto_data; 328 struct groupchat *gc = bee_chat_by_title(ic->bee, ic, id); 329 330 if (!gc) { 331 gc = imcb_chat_new(ic, id); 332 imcb_chat_name_hint(gc, id); 333 imcb_chat_add_buddy(gc, sd->username); 334 335 skype_printf(ic, "GET CHAT %s ADDER\n", id); 336 skype_printf(ic, "GET CHAT %s TOPIC\n", id); 337 skype_printf(ic, "GET CHAT %s ACTIVEMEMBERS\n", id); 338 } 339 340 return gc; 341 } 342 325 343 static void skype_parse_users(struct im_connection *ic, char *line) 326 344 { … … 687 705 info += 9; 688 706 if (sd->handle && sd->body && sd->type) { 689 struct groupchat *gc = bee_chat_by_title(ic->bee,ic, info);707 struct groupchat *gc = skype_chat_get_or_create(ic, info); 690 708 int i; 691 709 for (i = 0; i < g_list_length(sd->body); i++) { … … 1025 1043 } 1026 1044 if (!strcmp(info, "STATUS MULTI_SUBSCRIBED")) { 1027 gc = bee_chat_by_title(ic->bee, ic, id); 1028 if (!gc) { 1029 gc = imcb_chat_new(ic, id); 1030 imcb_chat_name_hint(gc, id); 1031 } 1032 skype_printf(ic, "GET CHAT %s ADDER\n", id); 1033 skype_printf(ic, "GET CHAT %s TOPIC\n", id); 1045 skype_chat_get_or_create(ic, id); 1034 1046 } else if (!strcmp(info, "STATUS DIALOG") && sd->groupchat_with) { 1035 gc = imcb_chat_new(ic, id); 1036 imcb_chat_name_hint(gc, id); 1047 gc = skype_chat_get_or_create(ic, id); 1037 1048 /* According to the docs this 1038 1049 * is necessary. However it … … 1045 1056 sd->groupchat_with); 1046 1057 imcb_chat_add_buddy(gc, buf); 1047 imcb_chat_add_buddy(gc, sd->username);1048 1058 g_free(sd->groupchat_with); 1049 1059 sd->groupchat_with = NULL; 1050 skype_printf(ic, "GET CHAT %s ADDER\n", id);1051 skype_printf(ic, "GET CHAT %s TOPIC\n", id);1052 1060 } else if (!strcmp(info, "STATUS UNSUBSCRIBED")) { 1053 1061 gc = bee_chat_by_title(ic->bee, ic, id); -
protocols/skype/t/groupchat-invite-bitlbee.mock
rfdc6d84 r64bed24 7 7 >> :bob!bob@skype.com JOIN :&bitlbee 8 8 << PRIVMSG &bitlbee :chat with bob 9 >> 353 alice = ##alice/$bob;a7ab206ec78 :@alice bob@root9 >> 353 alice = ##alice/$bob;a7ab206ec78 :@alice @root 10 10 << INVITE cecil ##alice/$bob;a7ab206ec78 11 11 >> cecil@skype.com JOIN :##alice/$bob;a7ab206ec78 -
protocols/skype/t/groupchat-invite-skyped.mock
rfdc6d84 r64bed24 26 26 >> GET CHAT #alice/$bob;a7ab206ec78060f1 TOPIC 27 27 << CHAT #alice/$bob;a7ab206ec78060f1 TOPIC 28 >> GET CHAT #alice/$bob;a7ab206ec78060f1 ACTIVEMEMBERS 29 << CHAT #alice/$bob;a7ab206ec78060f1 ACTIVEMEMBERS 28 30 << CHATMESSAGE 206 STATUS SENDING 29 31 << CHAT #alice/$bob;a7ab206ec78060f1 STATUS DIALOG -
protocols/skype/t/groupchat-invited-bitlbee.mock
rfdc6d84 r64bed24 6 6 << PRIVMSG &bitlbee :account skype on 7 7 >> JOIN :##cecil/$bob;4d8cc996579 8 >> 353 alice = ##cecil/$bob;4d8cc996579 :@alice bob cecil@root8 >> 353 alice = ##cecil/$bob;4d8cc996579 :@alice @root -
protocols/skype/t/groupchat-leave-bitlbee.mock
rfdc6d84 r64bed24 7 7 << PRIVMSG &bitlbee :account skype on 8 8 >> JOIN :##cecil/$bob;4d8cc996579 9 >> 353 alice = ##cecil/$bob;4d8cc996579 :@alice bob cecil@root9 >> 353 alice = ##cecil/$bob;4d8cc996579 :@alice @root 10 10 << PART ##cecil/$bob;4d8cc996579 11 11 >> PRIVMSG &bitlbee :alice: CHAT #cecil/$bob;4d8cc9965791c6b9 STATUS UNSUBSCRIBED -
protocols/skype/t/groupchat-leave-skyped.mock
rfdc6d84 r64bed24 36 36 >> GET CHAT #cecil/$bob;4d8cc9965791c6b9 TOPIC 37 37 << CHAT #cecil/$bob;4d8cc9965791c6b9 TOPIC 38 >> GET CHAT #cecil/$bob;4d8cc9965791c6b9 ADDER 39 << CHAT #cecil/$bob;4d8cc9965791c6b9 ADDER bob 40 >> GET CHAT #cecil/$bob;4d8cc9965791c6b9 TOPIC 41 << CHAT #cecil/$bob;4d8cc9965791c6b9 TOPIC 42 >> GET CHAT #cecil/$bob;4d8cc9965791c6b9 ADDER 43 << CHAT #cecil/$bob;4d8cc9965791c6b9 ADDER bob 44 >> GET CHAT #cecil/$bob;4d8cc9965791c6b9 TOPIC 45 << CHAT #cecil/$bob;4d8cc9965791c6b9 TOPIC 38 >> GET CHAT #cecil/$bob;4d8cc9965791c6b9 ACTIVEMEMBERS 39 << CHAT #cecil/$bob;4d8cc9965791c6b9 ACTIVEMEMBERS 46 40 >> GET CHATMESSAGE 188 FROM_HANDLE 47 41 << CHATMESSAGE 188 FROM_HANDLE bob -
protocols/skype/t/groupchat-msg-bitlbee.mock
rfdc6d84 r64bed24 7 7 << PRIVMSG &bitlbee :account skype on 8 8 >> JOIN :##cecil/$bob;4d8cc996579 9 >> 353 alice = ##cecil/$bob;4d8cc996579 :@alice bob cecil@root9 >> 353 alice = ##cecil/$bob;4d8cc996579 :@alice @root 10 10 << PRIVMSG ##cecil/$bob;4d8cc996579 :hello 11 11 >> PRIVMSG &bitlbee :alice: CHAT #cecil/$bob;4d8cc9965791c6b9 ACTIVITY_TIMESTAMP -
protocols/skype/t/groupchat-msg-skyped.mock
rfdc6d84 r64bed24 36 36 >> GET CHAT #cecil/$bob;4d8cc9965791c6b9 TOPIC 37 37 << CHAT #cecil/$bob;4d8cc9965791c6b9 TOPIC 38 >> GET CHAT #cecil/$bob;4d8cc9965791c6b9 ADDER 39 << CHAT #cecil/$bob;4d8cc9965791c6b9 ADDER bob 40 >> GET CHAT #cecil/$bob;4d8cc9965791c6b9 TOPIC 41 << CHAT #cecil/$bob;4d8cc9965791c6b9 TOPIC 42 >> GET CHAT #cecil/$bob;4d8cc9965791c6b9 ADDER 43 << CHAT #cecil/$bob;4d8cc9965791c6b9 ADDER bob 44 >> GET CHAT #cecil/$bob;4d8cc9965791c6b9 TOPIC 45 << CHAT #cecil/$bob;4d8cc9965791c6b9 TOPIC 38 >> GET CHAT #cecil/$bob;4d8cc9965791c6b9 ACTIVEMEMBERS 39 << CHAT #cecil/$bob;4d8cc9965791c6b9 ACTIVEMEMBERS bob cecil alice 46 40 >> GET CHATMESSAGE 188 FROM_HANDLE 47 41 << CHATMESSAGE 188 FROM_HANDLE bob -
protocols/skype/t/groupchat-topic-bitlbee.mock
rfdc6d84 r64bed24 6 6 << PRIVMSG &bitlbee :account skype on 7 7 >> JOIN :##cecil/$bob;4d8cc996579 8 >> 353 alice = ##cecil/$bob;4d8cc996579 :@alice bob cecil@root8 >> 353 alice = ##cecil/$bob;4d8cc996579 :@alice @root 9 9 << TOPIC ##cecil/$bob;4d8cc996579 :topic 10 10 >> TOPIC ##cecil/$bob;4d8cc996579 :topic
Note: See TracChangeset
for help on using the changeset viewer.