diff options
author | irungentoo <irungentoo@gmail.com> | 2014-03-16 13:24:39 -0400 |
---|---|---|
committer | irungentoo <irungentoo@gmail.com> | 2014-03-16 13:24:39 -0400 |
commit | 5babb281c05a48c0b4bbfe3c6be1527f439beec2 (patch) | |
tree | a38000591bc2e938a8dcd7783593bd614b31f14c /toxcore/friend_requests.h | |
parent | 95c8e9c2fb6c01a872871366e11aef18d49dc967 (diff) |
Friend request callback now contains the Tox object.
Diffstat (limited to 'toxcore/friend_requests.h')
-rw-r--r-- | toxcore/friend_requests.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/toxcore/friend_requests.h b/toxcore/friend_requests.h index 732dc4a2..722c7431 100644 --- a/toxcore/friend_requests.h +++ b/toxcore/friend_requests.h | |||
@@ -30,8 +30,9 @@ | |||
30 | 30 | ||
31 | typedef struct { | 31 | typedef struct { |
32 | uint32_t nospam; | 32 | uint32_t nospam; |
33 | void (*handle_friendrequest)(uint8_t *, uint8_t *, uint16_t, void *); | 33 | void (*handle_friendrequest)(void *, uint8_t *, uint8_t *, uint16_t, void *); |
34 | uint8_t handle_friendrequest_isset; | 34 | uint8_t handle_friendrequest_isset; |
35 | void *handle_friendrequest_object; | ||
35 | void *handle_friendrequest_userdata; | 36 | void *handle_friendrequest_userdata; |
36 | 37 | ||
37 | int (*filter_function)(uint8_t *, void *); | 38 | int (*filter_function)(uint8_t *, void *); |
@@ -57,8 +58,8 @@ uint32_t get_nospam(Friend_Requests *fr); | |||
57 | /* Set the function that will be executed when a friend request for us is received. | 58 | /* Set the function that will be executed when a friend request for us is received. |
58 | * Function format is function(uint8_t * public_key, uint8_t * data, uint16_t length, void * userdata) | 59 | * Function format is function(uint8_t * public_key, uint8_t * data, uint16_t length, void * userdata) |
59 | */ | 60 | */ |
60 | void callback_friendrequest(Friend_Requests *fr, void (*function)(uint8_t *, uint8_t *, uint16_t, void *), | 61 | void callback_friendrequest(Friend_Requests *fr, void (*function)(void *, uint8_t *, uint8_t *, uint16_t, void *), |
61 | void *userdata); | 62 | void *object, void *userdata); |
62 | 63 | ||
63 | /* Set the function used to check if a friend request should be displayed to the user or not. | 64 | /* Set the function used to check if a friend request should be displayed to the user or not. |
64 | * Function format is int function(uint8_t * public_key, void * userdata) | 65 | * Function format is int function(uint8_t * public_key, void * userdata) |