From ac324d040205ac593e61fab84d6e723984d47636 Mon Sep 17 00:00:00 2001 From: knotteye Date: Sun, 25 Apr 2021 17:33:07 -0500 Subject: [PATCH] Properly mark chats as read --- plchat.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/plchat.py b/plchat.py index b77836e..9e26dd1 100644 --- a/plchat.py +++ b/plchat.py @@ -736,7 +736,7 @@ class MessageArea(QWidget): if not self.last_read_id or not u or not i: return acc = ex.accts[u+i] - acc.markChatRead(self.chatID, self.last_read_id) + CallThread(acc.markChatRead, None, self.chatID, self.last_read_id).start() def addPage(self): if self.fetchingPage: @@ -756,6 +756,7 @@ class MessageArea(QWidget): for message in messages: if message['account_id'] == self.account['id']: self.last_read_id = message['id'] + break for i in reversed(range(self.layout.count())): self.layout.itemAt(i).widget().setParent(None) for message in reversed(messages):