Changeset 9143aeb
- Timestamp:
- 2008-04-05T12:26:04Z (17 years ago)
- Branches:
- master
- Children:
- f35aee7
- Parents:
- f3351f0
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
protocols/jabber/jabber_util.c
rf3351f0 r9143aeb 246 246 }; 247 247 248 static void jabber_buddy_ask_yes( gpointer w, struct jabber_buddy_ask_data *bla ) 249 { 248 static void jabber_buddy_ask_yes( void *data ) 249 { 250 struct jabber_buddy_ask_data *bla = data; 251 250 252 presence_send_request( bla->ic, bla->handle, "subscribed" ); 251 253 … … 257 259 } 258 260 259 static void jabber_buddy_ask_no( gpointer w, struct jabber_buddy_ask_data *bla ) 260 { 261 static void jabber_buddy_ask_no( void *data ) 262 { 263 struct jabber_buddy_ask_data *bla = data; 264 261 265 presence_send_request( bla->ic, bla->handle, "subscribed" ); 262 266 -
protocols/msn/msn_util.c
rf3351f0 r9143aeb 90 90 }; 91 91 92 static void msn_buddy_ask_yes( gpointer w, struct msn_buddy_ask_data *bla ) 93 { 92 static void msn_buddy_ask_yes( void *data ) 93 { 94 struct msn_buddy_ask_data *bla = data; 95 94 96 msn_buddy_list_add( bla->ic, "AL", bla->handle, bla->realname ); 95 97 … … 102 104 } 103 105 104 static void msn_buddy_ask_no( gpointer w, struct msn_buddy_ask_data *bla ) 105 { 106 static void msn_buddy_ask_no( void *data ) 107 { 108 struct msn_buddy_ask_data *bla = data; 109 106 110 msn_buddy_list_add( bla->ic, "BL", bla->handle, bla->realname ); 107 111 -
protocols/nogaim.c
rf3351f0 r9143aeb 343 343 /* dialogs.c */ 344 344 345 void imcb_ask( struct im_connection *ic, char *msg, void *data, void *doit, void *dont ) 345 void imcb_ask( struct im_connection *ic, char *msg, void *data, 346 query_callback doit, query_callback dont ) 346 347 { 347 348 query_add( ic->irc, ic, msg, doit, dont, data ); … … 495 496 }; 496 497 497 void show_got_added_no( gpointer w, struct show_got_added_data*data )498 { 499 g_free( data->handle );498 void show_got_added_no( void *data ) 499 { 500 g_free( ((struct show_got_added_data*)data)->handle ); 500 501 g_free( data ); 501 502 } 502 503 503 void show_got_added_yes( gpointer w, struct show_got_added_data *data ) 504 { 505 data->ic->acc->prpl->add_buddy( data->ic, data->handle, NULL ); 506 /* imcb_add_buddy( data->ic, NULL, data->handle, data->handle ); */ 507 508 return show_got_added_no( w, data ); 504 void show_got_added_yes( void *data ) 505 { 506 struct show_got_added_data *sga = data; 507 508 sga->ic->acc->prpl->add_buddy( sga->ic, sga->handle, NULL ); 509 /* imcb_add_buddy( sga->ic, NULL, sga->handle, sga->handle ); */ 510 511 return show_got_added_no( data ); 509 512 } 510 513 -
protocols/nogaim.h
rf3351f0 r9143aeb 42 42 #include "account.h" 43 43 #include "proxy.h" 44 #include "query.h" 44 45 #include "md5.h" 45 46 … … 261 262 * - 'doit' or 'dont' will be called depending of the answer of the user. 262 263 */ 263 G_MODULE_EXPORT void imcb_ask( struct im_connection *ic, char *msg, void *data, void *doit, void *dont );264 G_MODULE_EXPORT void imcb_ask( struct im_connection *ic, char *msg, void *data, query_callback doit, query_callback dont ); 264 265 G_MODULE_EXPORT void imcb_ask_add( struct im_connection *ic, char *handle, const char *realname ); 265 266 -
protocols/oscar/oscar.c
rf3351f0 r9143aeb 1084 1084 } 1085 1085 1086 void oscar_accept_chat( gpointer w, struct aim_chat_invitation * inv);1087 void oscar_reject_chat( gpointer w, struct aim_chat_invitation * inv);1086 void oscar_accept_chat(void *data); 1087 void oscar_reject_chat(void *data); 1088 1088 1089 1089 static int incomingim_chan2(aim_session_t *sess, aim_conn_t *conn, aim_userinfo_t *userinfo, struct aim_incomingim_ch2_args *args) { … … 1119 1119 } 1120 1120 1121 static void gaim_icq_authgrant(gpointer w, struct icq_auth *data) { 1121 static void gaim_icq_authgrant(void *data_) { 1122 struct icq_auth *data = data_; 1122 1123 char *uin, message; 1123 1124 struct oscar_data *od = (struct oscar_data *)data->ic->proto_data; … … 1134 1135 } 1135 1136 1136 static void gaim_icq_authdeny(gpointer w, struct icq_auth *data) { 1137 static void gaim_icq_authdeny(void *data_) { 1138 struct icq_auth *data = data_; 1137 1139 char *uin, *message; 1138 1140 struct oscar_data *od = (struct oscar_data *)data->ic->proto_data; … … 2588 2590 } 2589 2591 2590 void oscar_accept_chat( gpointer w, struct aim_chat_invitation * inv)2592 void oscar_accept_chat(void *data) 2591 2593 { 2594 struct aim_chat_invitation * inv = data; 2595 2592 2596 oscar_chat_join(inv->ic, inv->name, NULL, NULL); 2593 2597 g_free(inv->name); … … 2595 2599 } 2596 2600 2597 void oscar_reject_chat( gpointer w, struct aim_chat_invitation * inv)2601 void oscar_reject_chat(void *data) 2598 2602 { 2603 struct aim_chat_invitation * inv = data; 2604 2599 2605 g_free(inv->name); 2600 2606 g_free(inv); -
protocols/yahoo/yahoo.c
rf3351f0 r9143aeb 797 797 } 798 798 799 static void byahoo_accept_conf( gpointer w, struct byahoo_conf_invitation *inv ) 800 { 799 static void byahoo_accept_conf( void *data ) 800 { 801 struct byahoo_conf_invitation *inv = data; 802 801 803 yahoo_conference_logon( inv->yid, NULL, inv->members, inv->name ); 802 804 imcb_chat_add_buddy( inv->c, inv->ic->acc->user ); … … 805 807 } 806 808 807 static void byahoo_reject_conf( gpointer w, struct byahoo_conf_invitation *inv ) 808 { 809 static void byahoo_reject_conf( void *data ) 810 { 811 struct byahoo_conf_invitation *inv = data; 812 809 813 yahoo_conference_decline( inv->yid, NULL, inv->members, inv->name, "User rejected groupchat" ); 810 814 imcb_chat_free( inv->c ); -
query.c
rf3351f0 r9143aeb 30 30 static query_t *query_default( irc_t *irc ); 31 31 32 query_t *query_add( irc_t *irc, struct im_connection *ic, char *question, void *yes, void *no, void *data ) 32 query_t *query_add( irc_t *irc, struct im_connection *ic, char *question, 33 query_callback yes, query_callback no, void *data ) 33 34 { 34 35 query_t *q = g_new0( query_t, 1 ); … … 144 145 else 145 146 irc_usermsg( irc, "Accepted: %s", q->question ); 146 q->yes( NULL,q->data );147 q->yes( q->data ); 147 148 } 148 149 else … … 152 153 else 153 154 irc_usermsg( irc, "Rejected: %s", q->question ); 154 q->no( NULL,q->data );155 q->no( q->data ); 155 156 } 156 157 q->data = NULL; -
query.h
rf3351f0 r9143aeb 27 27 #define _QUERY_H 28 28 29 typedef void (*query_callback) ( void *data ); 30 29 31 typedef struct query 30 32 { 31 33 struct im_connection *ic; 32 34 char *question; 33 void (* yes) ( gpointer w, void *data ); 34 void (* no) ( gpointer w, void *data ); 35 query_callback yes, no; 35 36 void *data; 36 37 struct query *next; 37 38 } query_t; 38 39 39 query_t *query_add( irc_t *irc, struct im_connection *ic, char *question, void *yes, void *no, void *data ); 40 query_t *query_add( irc_t *irc, struct im_connection *ic, char *question, 41 query_callback yes, query_callback no, void *data ); 40 42 void query_del( irc_t *irc, query_t *q ); 41 43 void query_del_by_conn( irc_t *irc, struct im_connection *ic );
Note: See TracChangeset
for help on using the changeset viewer.