aboutsummaryrefslogtreecommitdiffstats
path: root/protocols/purple/purple.c
diff options
context:
space:
mode:
authorjgeboski <jgeboski@gmail.com>2016-06-22 14:54:52 -0400
committerjgeboski <jgeboski@gmail.com>2016-07-19 16:40:55 -0400
commit2c2b211aacd2d0f7017b793046840ffcbc9a9c97 (patch)
tree99e3679fc6aaa143d76ec9b713f194229141a05a /protocols/purple/purple.c
parentf60dc5cb68ac91df714f01ef61ba819eeac584aa (diff)
Added an interface for the listing of existing chatrooms
Several protocols can provide a list of existing chatrooms that a user is able join. This is crucial for the usage of several protocols, most notably Purple and Facebook. Plugins wishing to support this extended functionality must implement the new prpl->chat_list() function. This implemented function will in most cases send a remote request for the list of chatrooms. Once the list of chatrooms is obtained, a bee_chat_info_t GSList must be created and assigned to the im_connection->chatlist field. Then a call to the bee_chat_list_finish() is needed to display the list to the user. The chat list is maintained entirely by the plugin, so it is important to ensure all pointers related to the chat list remain valid until the chat list is set to NULL. This list is used internally by bitlbee to calculate indexes, which then allows the user to join a chat with an index, rather than some random identifier. It also important to ensure the list is properly freed whenever it is updated, or when the account is disconnect via the prpl->logout() function. On the user interface side of things, the 'chat list' subcommand was recommissioned. For a user to list the existing chat rooms: chat list <account id> Afterwards a user can join a chatroom in the list with its index. This extends the functionality of the 'chat add' subcommand by adding in support for the exclamation point operator to denote an index. chat add <account id> !<index> [channel]
Diffstat (limited to 'protocols/purple/purple.c')
0 files changed, 0 insertions, 0 deletions