diff options
author | Sven Moritz Hallberg <pesco@khjk.org> | 2010-06-03 12:31:46 +0200 |
---|---|---|
committer | Sven Moritz Hallberg <pesco@khjk.org> | 2010-06-03 12:31:46 +0200 |
commit | 3f81999c20852f14a5fb27a6ef6c5ea44db61a4d (patch) | |
tree | 14fa6a79d444049e758be853277270117e11692b /protocols/nogaim.h | |
parent | fc34fb5d0b717d90edfc7ed78f11166eb23c536e (diff) | |
parent | 2e44b1f12fb58a6969a8fbaf2946d6ecdace484a (diff) |
merge in bitlbee 1.2.4
Diffstat (limited to 'protocols/nogaim.h')
-rw-r--r-- | protocols/nogaim.h | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/protocols/nogaim.h b/protocols/nogaim.h index 83091c02..0229badf 100644 --- a/protocols/nogaim.h +++ b/protocols/nogaim.h @@ -227,6 +227,10 @@ struct prpl { /* Mainly for AOL, since they think "Bung hole" == "Bu ngho le". *sigh* * - Most protocols will just want to set this to g_strcasecmp().*/ int (* handle_cmp) (const char *who1, const char *who2); + + /* Implement these callbacks if you want to use imcb_ask_auth() */ + void (* auth_allow) (struct im_connection *, const char *who); + void (* auth_deny) (struct im_connection *, const char *who); }; /* im_api core stuff. */ @@ -255,13 +259,20 @@ G_MODULE_EXPORT void imc_logout( struct im_connection *ic, int allow_reconnect ) G_MODULE_EXPORT void imcb_log( struct im_connection *ic, char *format, ... ) G_GNUC_PRINTF( 2, 3 ); /* To tell the user an error, ie. before logging out when an error occurs. */ G_MODULE_EXPORT void imcb_error( struct im_connection *ic, char *format, ... ) G_GNUC_PRINTF( 2, 3 ); + /* To ask a your about something. * - 'msg' is the question. * - 'data' can be your custom struct - it will be passed to the callbacks. * - 'doit' or 'dont' will be called depending of the answer of the user. */ G_MODULE_EXPORT void imcb_ask( struct im_connection *ic, char *msg, void *data, query_callback doit, query_callback dont ); -G_MODULE_EXPORT void imcb_ask_add( struct im_connection *ic, char *handle, const char *realname ); + +/* Two common questions you may want to ask: + * - X added you to his contact list, allow? + * - X is not in your contact list, want to add? + */ +G_MODULE_EXPORT void imcb_ask_auth( struct im_connection *ic, const char *handle, const char *realname ); +G_MODULE_EXPORT void imcb_ask_add( struct im_connection *ic, const char *handle, const char *realname ); /* Buddy management */ /* This function should be called for each handle which are visible to the |