added a few todos to source code
This commit is contained in:
parent
b137681f86
commit
5d11fe7dc6
|
@ -741,7 +741,7 @@ public class MessageParser extends AbstractParser implements OnMessagePacketRece
|
||||||
if (packet.fromAccount(account)) {
|
if (packet.fromAccount(account)) {
|
||||||
Conversation conversation = mXmppConnectionService.find(account, counterpart.toBareJid());
|
Conversation conversation = mXmppConnectionService.find(account, counterpart.toBareJid());
|
||||||
if (conversation != null && (query == null || query.isCatchup())) {
|
if (conversation != null && (query == null || query.isCatchup())) {
|
||||||
mXmppConnectionService.markRead(conversation);
|
mXmppConnectionService.markRead(conversation); //TODO only mark messages read that are older than timestamp
|
||||||
}
|
}
|
||||||
} else if (isTypeGroupChat) {
|
} else if (isTypeGroupChat) {
|
||||||
Conversation conversation = mXmppConnectionService.find(account, counterpart.toBareJid());
|
Conversation conversation = mXmppConnectionService.find(account, counterpart.toBareJid());
|
||||||
|
|
|
@ -225,8 +225,10 @@ public class NotificationService {
|
||||||
}
|
}
|
||||||
synchronized (notifications) {
|
synchronized (notifications) {
|
||||||
markAsReadIfHasDirectReply(conversation);
|
markAsReadIfHasDirectReply(conversation);
|
||||||
|
//TODO: only update if something actually got removed?
|
||||||
notifications.remove(conversation.getUuid());
|
notifications.remove(conversation.getUuid());
|
||||||
final NotificationManagerCompat notificationManager = NotificationManagerCompat.from(mXmppConnectionService);
|
final NotificationManagerCompat notificationManager = NotificationManagerCompat.from(mXmppConnectionService);
|
||||||
|
//TODO on later androids (that have multiple Conversations) maybe canceling is enough + update summary notification
|
||||||
notificationManager.cancel(conversation.getUuid(), NOTIFICATION_ID);
|
notificationManager.cancel(conversation.getUuid(), NOTIFICATION_ID);
|
||||||
updateNotification(false);
|
updateNotification(false);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue