mirror of
https://github.com/MarekZegare4/MeshCore-Solo.git
synced 2026-08-02 18:26:11 +00:00
feat: DM chat history, per-contact unread badges, bot history, contact index fix
- Add DM_HIST phase in QuickMsgScreen: 32-entry ring buffer tracks incoming and outgoing DMs per contact; selecting a contact now opens history view before compose - Per-contact DM unread badge in contact list (replaces hop count display) - Bot replies (DM and channel) stored in history so they appear on-screen - Fix contact index truncation: _sorted was uint8_t (max 255), causing contacts at indices 256-349 to map to wrong entries; changed to uint16_t - Add addDMMsg() virtual to AbstractUITask; wire through MyMesh.cpp - Incoming chat DMs call addDMMsg(); outgoing after successful send too - msgRead(0) from companion app clears per-contact unread table Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Sonnet 4.6
parent
d1fcd56b59
commit
855f0dada4
@@ -40,8 +40,9 @@ public:
|
||||
void enableSerial() { _serial->enable(); }
|
||||
void disableSerial() { _serial->disable(); }
|
||||
virtual void msgRead(int msgcount) = 0;
|
||||
virtual void newMsg(uint8_t path_len, const char* from_name, const char* text, int msgcount, uint8_t contact_type = 0) = 0;
|
||||
virtual void newMsg(uint8_t path_len, const char* from_name, const char* text, int msgcount, uint8_t contact_type = 0, const uint8_t* pub_key = nullptr) = 0;
|
||||
virtual void notify(UIEventType t = UIEventType::none) = 0;
|
||||
virtual void addChannelMsg(uint8_t channel_idx, const char* text) {}
|
||||
virtual void addDMMsg(const uint8_t* pub_key, bool outgoing, const char* text) {}
|
||||
virtual void loop() = 0;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user