How to handle persistent chat rooms / conversations

David Woodhouse <[email protected]>
Newsgroups gmane.comp.gnome.gaim.devel
Message-ID <[email protected]>
I'm working on a new prpl for a protocol where conversations are
persistent — all the historical messages are available.

For chat rooms, I've handled this by fetching all old messages when the
room is joined. The first time, I fetch everything; then I remember the
latest message (using purple_account_set_string(…"last-msg-$roomid"…)
and subsequent joins will only fetch the messages since then.

This isn't perfect, but it seems to work OK. Anyone got better
suggestions? Is there a way to mark chats as persistent from the back
end, rather than just in the UI? That would help.

It gets slightly more complex when I get to other "conversations" in
this protocol. Those are mostly two-party conversations which are
basically IM, but there are also multi-party conversations.

The simplest conversation has two parties, and should basically be
represented as IM. But how do I "insert" the history when the account
is first opened, including both incoming and outgoing messages? Is
there a way to get those to be represented as 'chat' conversations in
Pidgin? I could automatically call serv_got_joined_chat() for incoming
messages and even on outgoing... but the normal IM window would still
exist. Any other ideas? 

Then there's multi-party conversations, which I suppose will need to be
handled as chat conversations — will I need to do my own UI actions to
allow for creating, listing and joining those? 

_______________________________________________
Devel mailing list
[email protected]
https://pidgin.im/cgi-bin/mailman/listinfo/devel
smime.p7s (application/x-pkcs7-signature, 4.8 KB) - not displayed
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.