Mercurial > pidgin
diff libpurple/prpl.h @ 26108:d6e23439b77c
Change purple_prpl_can_do_media to purple_prpl_get_media_caps.
This allows for it to only be called once. From the caps returned you
can then tell which media capabilities a buddy has without having to
call the function for each different type.
author | Mike Ruprecht <maiku@soc.pidgin.im> |
---|---|
date | Wed, 11 Feb 2009 00:01:20 +0000 |
parents | f0c2e27c7ae7 |
children | ff4212a5268f |
line wrap: on
line diff
--- a/libpurple/prpl.h Sun Feb 08 23:17:51 2009 +0000 +++ b/libpurple/prpl.h Wed Feb 11 00:01:20 2009 +0000 @@ -466,11 +466,10 @@ * * @param conn The connection the contact is on. * @param who The remote user to check for media capability with. - * @param type The type of media session to check for. - * @return @c TRUE The contact supports the given media type, or @c FALSE otherwise. + * @return The media caps the contact supports. */ - gboolean (*can_do_media)(PurpleConnection *gc, const char *who, - PurpleMediaSessionType type); + PurpleMediaCaps (*get_media_caps)(PurpleConnection *gc, + const char *who); }; #define PURPLE_PROTOCOL_PLUGIN_HAS_FUNC(prpl, member) \ @@ -765,13 +764,11 @@ * * @param account The account the user is on. * @param who The name of the contact to check capabilities for. - * @param type The type of media session to check for. * - * @return @c TRUE if the contact supports the session type, else @c FALSE. + * @return The media caps the contact supports. */ -gboolean purple_prpl_can_do_media(PurpleAccount *account, - const char *who, - PurpleMediaSessionType type); +PurpleMediaCaps purple_prpl_get_media_caps(PurpleAccount *account, + const char *who); /** * Initiates a media session with the given contact.