emit "DC_EVENT_MEMBER_ADDED" and python plugin event "member_added" for securejoin or non-securejoin additions of a contact to a chat. also fixup some docs

This commit is contained in:
holger krekel
2020-02-26 16:51:08 +01:00
parent 57141e478c
commit 84f17b7539
12 changed files with 69 additions and 12 deletions

View File

@@ -4505,7 +4505,7 @@ int64_t dc_lot_get_timestamp (const dc_lot_t* lot);
/**
* This event is sent out to the inviter when a joiner successfully joined a group.
* (DEPRECATED)
*
* @param data1 (int) chat_id
* @param data2 (int) contact_id
@@ -4513,6 +4513,14 @@ int64_t dc_lot_get_timestamp (const dc_lot_t* lot);
*/
#define DC_EVENT_SECUREJOIN_MEMBER_ADDED 2062
/**
* This event is sent for each member that gets added to a (verified or unverified) chat.
*
* @param data1 (int) chat_id
* @param data2 (int) contact_id
* @return 0
*/
#define DC_EVENT_MEMBER_ADDED 2063
/**
* @}

View File

@@ -199,6 +199,10 @@ impl ContextWrapper {
Event::SecurejoinMemberAdded {
chat_id,
contact_id,
}
| Event::MemberAdded {
chat_id,
contact_id,
} => {
ffi_cb(
self,