aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java
diff options
context:
space:
mode:
authorDaniel Gultsch <daniel@gultsch.de>2015-07-03 22:08:23 +0200
committerDaniel Gultsch <daniel@gultsch.de>2015-07-03 22:08:23 +0200
commit2fbeb0bbb2db84a54a67f91e45602c55bfd92ea4 (patch)
treebc83cc8e610357a5cb985316badb5da7bd6addd4 /src/main/java
parentd30fb6f0a15fe574069694732bb23c339f0c30d1 (diff)
make sure unread count is initialized as 0. fixes #1270
Diffstat (limited to 'src/main/java')
-rw-r--r--src/main/java/eu/siacs/conversations/services/XmppConnectionService.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/main/java/eu/siacs/conversations/services/XmppConnectionService.java b/src/main/java/eu/siacs/conversations/services/XmppConnectionService.java
index a0961d69..3b64872e 100644
--- a/src/main/java/eu/siacs/conversations/services/XmppConnectionService.java
+++ b/src/main/java/eu/siacs/conversations/services/XmppConnectionService.java
@@ -233,7 +233,7 @@ public class XmppConnectionService extends Service implements OnPhoneContactsLoa
private MessageArchiveService mMessageArchiveService = new MessageArchiveService(this);
private OnConversationUpdate mOnConversationUpdate = null;
private int convChangedListenerCount = 0;
- private int unreadCount = 0;
+ private int unreadCount = -1;
private OnAccountUpdate mOnAccountUpdate = null;
private OnStatusChanged statusListener = new OnStatusChanged() {
@@ -602,6 +602,7 @@ public class XmppConnectionService extends Service implements OnPhoneContactsLoa
this.pm = (PowerManager) getSystemService(Context.POWER_SERVICE);
this.wakeLock = pm.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK,"XmppConnectionService");
toggleForegroundService();
+ updateUnreadCountBadge();
}
public void toggleForegroundService() {