diff options
author | George Hazan <george.hazan@gmail.com> | 2025-02-02 14:40:34 +0300 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2025-02-02 14:40:34 +0300 |
commit | 29b658000f364d4d33a9eff4ac4eb51d9cbf638e (patch) | |
tree | 33c2361796449df67afbb545a8ac571e96d47d3d /protocols/Tox/libtox/src/toxcore/Messenger.h | |
parent | 8b85a1d4242aadcdcb682a90059061cc72a868c0 (diff) |
libtox: update to 0.2.20
Diffstat (limited to 'protocols/Tox/libtox/src/toxcore/Messenger.h')
-rw-r--r-- | protocols/Tox/libtox/src/toxcore/Messenger.h | 51 |
1 files changed, 0 insertions, 51 deletions
diff --git a/protocols/Tox/libtox/src/toxcore/Messenger.h b/protocols/Tox/libtox/src/toxcore/Messenger.h index cace3340b2..998a009f15 100644 --- a/protocols/Tox/libtox/src/toxcore/Messenger.h +++ b/protocols/Tox/libtox/src/toxcore/Messenger.h @@ -200,20 +200,10 @@ typedef void m_friend_lossy_packet_cb(Messenger *m, uint32_t friend_number, uint size_t length, void *user_data); typedef void m_friend_lossless_packet_cb(Messenger *m, uint32_t friend_number, uint8_t packet_id, const uint8_t *data, size_t length, void *user_data); -typedef void m_friend_connectionstatuschange_internal_cb(Messenger *m, uint32_t friend_number, - bool is_online, void *user_data); typedef void m_conference_invite_cb(Messenger *m, uint32_t friend_number, const uint8_t *cookie, uint16_t length, void *user_data); typedef void m_group_invite_cb(const Messenger *m, uint32_t friend_number, const uint8_t *invite_data, size_t length, const uint8_t *group_name, size_t group_name_length, void *user_data); -typedef void m_msi_packet_cb(Messenger *m, uint32_t friend_number, const uint8_t *data, uint16_t length, - void *user_data); -typedef int m_lossy_rtp_packet_cb(Messenger *m, uint32_t friend_number, const uint8_t *data, uint16_t length, void *object); - -typedef struct RTP_Packet_Handler { - m_lossy_rtp_packet_cb *function; - void *object; -} RTP_Packet_Handler; typedef struct Friend { uint8_t real_pk[CRYPTO_PUBLIC_KEY_SIZE]; @@ -243,8 +233,6 @@ typedef struct Friend { uint32_t num_sending_files; struct File_Transfers file_receiving[MAX_CONCURRENT_FILE_PIPES]; - RTP_Packet_Handler lossy_rtp_packethandlers[PACKET_ID_RANGE_LOSSY_AV_SIZE]; - struct Receipts *receipts_start; struct Receipts *receipts_end; } Friend; @@ -301,8 +289,6 @@ struct Messenger { m_friend_typing_cb *friend_typingchange; m_friend_read_receipt_cb *read_receipt; m_friend_connection_status_cb *friend_connectionstatuschange; - m_friend_connectionstatuschange_internal_cb *friend_connectionstatuschange_internal; - void *friend_connectionstatuschange_internal_userdata; struct Group_Chats *conferences_object; m_conference_invite_cb *conference_invite; @@ -314,9 +300,6 @@ struct Messenger { m_file_recv_chunk_cb *file_filedata; m_file_chunk_request_cb *file_reqchunk; - m_msi_packet_cb *msi_packet; - void *msi_packet_userdata; - m_friend_lossy_packet_cb *lossy_packethandler; m_friend_lossless_packet_cb *lossless_packethandler; @@ -614,10 +597,6 @@ non_null() void m_callback_read_receipt(Messenger *m, m_friend_read_receipt_cb * */ non_null() void m_callback_connectionstatus(Messenger *m, m_friend_connection_status_cb *function); -/** Same as previous but for internal A/V core usage only */ -non_null() void m_callback_connectionstatus_internal_av( - Messenger *m, m_friend_connectionstatuschange_internal_cb *function, void *userdata); - /** @brief Set the callback for typing changes. */ non_null() void m_callback_core_connection(Messenger *m, m_self_connection_status_cb *function); @@ -731,29 +710,6 @@ non_null(1) nullable(5) int send_file_data(const Messenger *m, int32_t friendnumber, uint32_t filenumber, uint64_t position, const uint8_t *data, uint16_t length); -/*** A/V related */ - -/** @brief Set the callback for msi packets. */ -non_null(1) nullable(2, 3) -void m_callback_msi_packet(Messenger *m, m_msi_packet_cb *function, void *userdata); - -/** @brief Send an msi packet. - * - * @retval true on success - * @retval false on failure - */ -non_null() -bool m_msi_packet(const Messenger *m, int32_t friendnumber, const uint8_t *data, uint16_t length); - -/** @brief Set handlers for lossy rtp packets. - * - * @retval -1 on failure. - * @retval 0 on success. - */ -non_null(1) nullable(4, 5) -int m_callback_rtp_packet(Messenger *m, int32_t friendnumber, uint8_t byte, - m_lossy_rtp_packet_cb *function, void *object); - /*** CUSTOM PACKETS */ /** @brief Set handlers for custom lossy packets. */ @@ -761,13 +717,6 @@ non_null() void custom_lossy_packet_registerhandler(Messenger *m, m_friend_lossy /** @brief High level function to send custom lossy packets. * - * TODO(oxij): this name is confusing, because this function sends both av and custom lossy packets. - * Meanwhile, m_handle_lossy_packet routes custom packets to custom_lossy_packet_registerhandler - * as you would expect from its name. - * - * I.e. custom_lossy_packet_registerhandler's "custom lossy packet" and this "custom lossy packet" - * are not the same set of packets. - * * @retval -1 if friend invalid. * @retval -2 if length wrong. * @retval -3 if first byte invalid. |