From eabedee9444409c9de5f779e5f392440989db52e Mon Sep 17 00:00:00 2001 From: Christian Schneppe Date: Sat, 7 Apr 2018 23:47:48 +0200 Subject: do not highlight users when not participating --- .../java/de/pixart/messenger/services/XmppConnectionService.java | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'src/main/java/de/pixart/messenger/services') diff --git a/src/main/java/de/pixart/messenger/services/XmppConnectionService.java b/src/main/java/de/pixart/messenger/services/XmppConnectionService.java index 5c19a9de2..cfdf14f9a 100644 --- a/src/main/java/de/pixart/messenger/services/XmppConnectionService.java +++ b/src/main/java/de/pixart/messenger/services/XmppConnectionService.java @@ -1853,6 +1853,7 @@ public class XmppConnectionService extends Service { return conversation; } conversation = databaseBackend.findConversation(account, jid); + Log.d(Config.LOGTAG, "loaded from db: " + conversation.getNextMessage()); final boolean loadMessagesFromDb; if (conversation != null) { conversation.setStatus(Conversation.STATUS_AVAILABLE); @@ -1978,6 +1979,7 @@ public class XmppConnectionService extends Service { public void archiveConversation(Conversation conversation) { getNotificationService().clear(conversation); conversation.setStatus(Conversation.STATUS_ARCHIVED); + conversation.setNextMessage(null); synchronized (this.conversations) { getMessageArchiveService().kill(conversation); if (conversation.getMode() == Conversation.MODE_MULTI) { @@ -3370,12 +3372,7 @@ public class XmppConnectionService extends Service { } public void updateConversation(final Conversation conversation) { - mDatabaseWriterExecutor.execute(new Runnable() { - @Override - public void run() { - databaseBackend.updateConversation(conversation); - } - }); + mDatabaseWriterExecutor.execute(() -> databaseBackend.updateConversation(conversation)); } private void reconnectAccount(final Account account, final boolean force, final boolean interactive) { -- cgit v1.2.3