properly clear notifications. fixed #921
This commit is contained in:
parent
3c64839daf
commit
0eeead495f
|
@ -262,8 +262,12 @@ public class ConversationActivity extends XmppActivity
|
||||||
}
|
}
|
||||||
|
|
||||||
public void sendReadMarkerIfNecessary(final Conversation conversation) {
|
public void sendReadMarkerIfNecessary(final Conversation conversation) {
|
||||||
if (!mActivityPaused && conversation != null && !conversation.isRead()) {
|
if (!mActivityPaused && conversation != null) {
|
||||||
|
if (!conversation.isRead()) {
|
||||||
xmppConnectionService.sendReadMarker(conversation);
|
xmppConnectionService.sendReadMarker(conversation);
|
||||||
|
} else {
|
||||||
|
xmppConnectionService.markRead(conversation);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -742,9 +746,11 @@ public class ConversationActivity extends XmppActivity
|
||||||
if (this.xmppConnectionServiceBound) {
|
if (this.xmppConnectionServiceBound) {
|
||||||
this.xmppConnectionService.getNotificationService().setIsInForeground(true);
|
this.xmppConnectionService.getNotificationService().setIsInForeground(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!isConversationsOverviewVisable() || !isConversationsOverviewHideable()) {
|
if (!isConversationsOverviewVisable() || !isConversationsOverviewHideable()) {
|
||||||
sendReadMarkerIfNecessary(getSelectedConversation());
|
sendReadMarkerIfNecessary(getSelectedConversation());
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
Loading…
Reference in a new issue