« Return to Thread: libpurple / find active conversations

Re: libpurple / find active conversations

by Etan Reisner-2 :: Rate this Message:

Reply (Restricted by the Administrator) | Reply to Author | View in Thread

On Wed, Jul 08, 2009 at 05:06:07PM +0200, Cedric Roche wrote:
>
> I just want to send messages. If a PurpleConversation is already open between the two buddies, I want to use the existing one and not create a new one.
> I want to loop over the buddy list in order to use purple_find_conversation_with_account.
>
> I'm sorry I have  trouble to understand libpurple.
>
> Thx

If you know the buddy you are sending to then you don't need to loop over
the buddy list to find their name do you? So why can't you just use the
buddy name in the find_conversation_with_account call directly? If you
don't know the buddy name then how were you going to pick them from the
buddy list to send to at all?

But that's even more work than you technically need to do, as
purple_conversation_new will re-use an existing IM conversation if one
already exists.

    -Etan

_______________________________________________
Devel mailing list
Devel@...
http://pidgin.im/cgi-bin/mailman/listinfo/devel

 « Return to Thread: libpurple / find active conversations