toxcore update and add private ngc ip getter

This commit is contained in:
Green Sky 2024-03-11 11:45:03 +01:00
parent 3b75a1c5d3
commit cf3679018b
No known key found for this signature in database
2 changed files with 10 additions and 2 deletions

View File

@ -2,13 +2,21 @@
#include <cstdint> #include <cstdint>
#include <string>
#include <optional>
#include <tuple>
#include "./toxcore_enums.hpp"
// defines the private interface for tox // defines the private interface for tox
struct ToxPrivateI { struct ToxPrivateI {
static constexpr const char* version {"1"}; static constexpr const char* version {"2"};
virtual ~ToxPrivateI(void) {} virtual ~ToxPrivateI(void) {}
virtual uint16_t toxDHTGetNumCloselist(void) = 0; virtual uint16_t toxDHTGetNumCloselist(void) = 0;
virtual uint16_t toxDHTGetNumCloselistAnnounceCapable(void) = 0; virtual uint16_t toxDHTGetNumCloselistAnnounceCapable(void) = 0;
virtual std::tuple<std::optional<std::string>, Tox_Err_Group_Peer_Query> toxGroupPeerGetIPAddress(uint32_t group_number, uint32_t peer_id) = 0;
}; };

View File

@ -255,10 +255,10 @@ enum Tox_Err_Group_Send_Private_Message {
TOX_ERR_GROUP_SEND_PRIVATE_MESSAGE_PEER_NOT_FOUND, TOX_ERR_GROUP_SEND_PRIVATE_MESSAGE_PEER_NOT_FOUND,
TOX_ERR_GROUP_SEND_PRIVATE_MESSAGE_TOO_LONG, TOX_ERR_GROUP_SEND_PRIVATE_MESSAGE_TOO_LONG,
TOX_ERR_GROUP_SEND_PRIVATE_MESSAGE_EMPTY, TOX_ERR_GROUP_SEND_PRIVATE_MESSAGE_EMPTY,
TOX_ERR_GROUP_SEND_PRIVATE_MESSAGE_BAD_TYPE,
TOX_ERR_GROUP_SEND_PRIVATE_MESSAGE_PERMISSIONS, TOX_ERR_GROUP_SEND_PRIVATE_MESSAGE_PERMISSIONS,
TOX_ERR_GROUP_SEND_PRIVATE_MESSAGE_FAIL_SEND, TOX_ERR_GROUP_SEND_PRIVATE_MESSAGE_FAIL_SEND,
TOX_ERR_GROUP_SEND_PRIVATE_MESSAGE_DISCONNECTED, TOX_ERR_GROUP_SEND_PRIVATE_MESSAGE_DISCONNECTED,
TOX_ERR_GROUP_SEND_PRIVATE_MESSAGE_BAD_TYPE,
}; };
enum Tox_Err_Group_Self_Status_Set { enum Tox_Err_Group_Self_Status_Set {