mirror of
https://github.com/MarekZegare4/MeshCore-Solo.git
synced 2026-07-30 16:58:12 +00:00
refactor(BaseChatMesh): extract onDiscoveredAdvert to keep upstream signature
Reverts onDiscoveredContact to the upstream 4-param signature, adding a separate virtual onDiscoveredAdvert(bool was_flood) with a default no-op implementation. Only MyMesh overrides the new virtual; simple_secure_chat and any future implementors need no changes on upstream merges. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -102,7 +102,8 @@ protected:
|
||||
virtual bool shouldOverwriteWhenFull() const { return false; }
|
||||
virtual uint8_t getAutoAddMaxHops() const { return 0; } // 0 = no limit, 1 = direct (0 hops), N = up to N-1 hops
|
||||
virtual void onContactOverwrite(const uint8_t* pub_key) {};
|
||||
virtual void onDiscoveredContact(ContactInfo& contact, bool is_new, uint8_t path_len, const uint8_t* path, bool was_flood) = 0;
|
||||
virtual void onDiscoveredContact(ContactInfo& contact, bool is_new, uint8_t path_len, const uint8_t* path) = 0;
|
||||
virtual void onDiscoveredAdvert(bool was_flood) {}
|
||||
virtual ContactInfo* processAck(const uint8_t *data) = 0;
|
||||
virtual void onContactPathUpdated(const ContactInfo& contact) = 0;
|
||||
virtual bool onContactPathRecv(ContactInfo& from, uint8_t* in_path, uint8_t in_path_len, uint8_t* out_path, uint8_t out_path_len, uint8_t extra_type, uint8_t* extra, uint8_t extra_len);
|
||||
|
||||
Reference in New Issue
Block a user