comparison libpurple/prpl.h @ 26606:df9042312063

Switch media to store accounts rather than connections. This for the most part stops it from crashing when ending a session when the connection has been interrupted.
author Mike Ruprecht <maiku@soc.pidgin.im>
date Thu, 09 Apr 2009 21:35:06 +0000
parents f5f08111da52
children 4851546210a1 83e6e710cbf3
comparison
equal deleted inserted replaced
26605:6a3943412f2d 26606:df9042312063
462 GHashTable *(*get_account_text_table)(PurpleAccount *account); 462 GHashTable *(*get_account_text_table)(PurpleAccount *account);
463 463
464 /** 464 /**
465 * Initiate a media session with the given contact. 465 * Initiate a media session with the given contact.
466 * 466 *
467 * @param conn The connection to initiate the media session on. 467 * @param account The account to initiate the media session on.
468 * @param who The remote user to initiate the session with. 468 * @param who The remote user to initiate the session with.
469 * @param type The type of media session to initiate. 469 * @param type The type of media session to initiate.
470 * @return TRUE if the call succeeded else FALSE. (Doesn't imply the media session or stream will be successfully created) 470 * @return TRUE if the call succeeded else FALSE. (Doesn't imply the media session or stream will be successfully created)
471 */ 471 */
472 gboolean (*initiate_media)(PurpleConnection *gc, const char *who, 472 gboolean (*initiate_media)(PurpleAccount *account, const char *who,
473 PurpleMediaSessionType type); 473 PurpleMediaSessionType type);
474 474
475 /** 475 /**
476 * Checks to see if the given contact supports the given type of media session. 476 * Checks to see if the given contact supports the given type of media session.
477 * 477 *
478 * @param conn The connection the contact is on. 478 * @param account The account the contact is on.
479 * @param who The remote user to check for media capability with. 479 * @param who The remote user to check for media capability with.
480 * @return The media caps the contact supports. 480 * @return The media caps the contact supports.
481 */ 481 */
482 PurpleMediaCaps (*get_media_caps)(PurpleConnection *gc, 482 PurpleMediaCaps (*get_media_caps)(PurpleAccount *account,
483 const char *who); 483 const char *who);
484 }; 484 };
485 485
486 #define PURPLE_PROTOCOL_PLUGIN_HAS_FUNC(prpl, member) \ 486 #define PURPLE_PROTOCOL_PLUGIN_HAS_FUNC(prpl, member) \
487 (((G_STRUCT_OFFSET(PurplePluginProtocolInfo, member) < G_STRUCT_OFFSET(PurplePluginProtocolInfo, struct_size)) \ 487 (((G_STRUCT_OFFSET(PurplePluginProtocolInfo, member) < G_STRUCT_OFFSET(PurplePluginProtocolInfo, struct_size)) \