diff options
author | Christian Schneppe <christian@pix-art.de> | 2016-06-29 10:48:29 +0200 |
---|---|---|
committer | Christian Schneppe <christian@pix-art.de> | 2016-06-29 10:48:29 +0200 |
commit | e20199d74c2a48eebab924a1de217b722ca7cf4d (patch) | |
tree | 0120cce4cf83209e6c1764f8170a86dc959c6fdc /src/main/java/eu/siacs/conversations/services/NotificationService.java | |
parent | bbc9ba78933cde7bd51508ba1ae4850504cdd637 (diff) |
vibrate on new messages when app is open
Diffstat (limited to '')
-rw-r--r-- | src/main/java/eu/siacs/conversations/services/NotificationService.java | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/main/java/eu/siacs/conversations/services/NotificationService.java b/src/main/java/eu/siacs/conversations/services/NotificationService.java index d6787301a..47cdc4f3b 100644 --- a/src/main/java/eu/siacs/conversations/services/NotificationService.java +++ b/src/main/java/eu/siacs/conversations/services/NotificationService.java @@ -143,8 +143,12 @@ public class NotificationService { final boolean isScreenOn = mXmppConnectionService.isInteractive(); if (this.mIsInForeground && isScreenOn && this.mOpenConversation == message.getConversation()) { Log.d(Config.LOGTAG,message.getConversation().getAccount().getJid().toBareJid()+": suppressing notification because conversation is open"); + mXmppConnectionService.vibrate(); return; } + if (this.mIsInForeground && isScreenOn) { + mXmppConnectionService.vibrate(); + } synchronized (notifications) { pushToStack(message); final Account account = message.getConversation().getAccount(); |