summaryrefslogtreecommitdiff
path: root/toxcore/group_chats.h
diff options
context:
space:
mode:
Diffstat (limited to 'toxcore/group_chats.h')
-rw-r--r--toxcore/group_chats.h10
1 files changed, 8 insertions, 2 deletions
diff --git a/toxcore/group_chats.h b/toxcore/group_chats.h
index 2235a6e3..65f573fb 100644
--- a/toxcore/group_chats.h
+++ b/toxcore/group_chats.h
@@ -65,7 +65,7 @@ typedef struct Group_Chat {
65 uint32_t message_number; 65 uint32_t message_number;
66 void (*group_message)(struct Group_Chat *m, int, uint8_t *, uint16_t, void *); 66 void (*group_message)(struct Group_Chat *m, int, uint8_t *, uint16_t, void *);
67 void *group_message_userdata; 67 void *group_message_userdata;
68 void (*peer_namelistchange)(struct Group_Chat *m, void *); 68 void (*peer_namelistchange)(struct Group_Chat *m, int peer, uint8_t change, void *);
69 void *group_namelistchange_userdata; 69 void *group_namelistchange_userdata;
70 70
71 uint64_t last_sent_ping; 71 uint64_t last_sent_ping;
@@ -105,7 +105,13 @@ void callback_groupmessage(Group_Chat *chat, void (*function)(Group_Chat *chat,
105 * 105 *
106 * format of function is: function(Group_Chat *chat, userdata) 106 * format of function is: function(Group_Chat *chat, userdata)
107 */ 107 */
108void callback_namelistchange(Group_Chat *chat, void (*function)(Group_Chat *chat, void *), void *userdata); 108typedef enum {
109 CHAT_CHANGE_PEER_ADD,
110 CHAT_CHANGE_PEER_DEL,
111 CHAT_CHANGE_PEER_NAME,
112} CHAT_CHANGE;
113
114void callback_namelistchange(Group_Chat *chat, void (*function)(Group_Chat *chat, int peer, uint8_t change, void *), void *userdata);
109 115
110/* 116/*
111 * Send a message to the group. 117 * Send a message to the group.