mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge
synced 2024-11-27 12:26:48 +01:00
Map a few more apps to NotificationKind
This commit is contained in:
parent
4f80844016
commit
a73beceb44
@ -156,16 +156,26 @@ public class NotificationListener extends NotificationListenerService {
|
||||
|
||||
// Set application icons for generic notifications
|
||||
NotificationKind notificationKind;
|
||||
if (source.equals("org.mariotaku.twidere") ||
|
||||
source.equals("com.twitter.android") ||
|
||||
source.equals("org.andstatus.app")) {
|
||||
notificationKind = NotificationKind.TWITTER;
|
||||
} else if (source.equals("com.fsck.k9")) {
|
||||
notificationKind = NotificationKind.EMAIL;
|
||||
} else if (source.equals("eu.siacs.conversations")) {
|
||||
notificationKind = NotificationKind.CHAT;
|
||||
} else {
|
||||
notificationKind = NotificationKind.UNDEFINED;
|
||||
switch (source) {
|
||||
case "org.mariotaku.twidere":
|
||||
case "com.twitter.android":
|
||||
case "org.andstatus.app":
|
||||
case "org.mustard.android":
|
||||
notificationKind = NotificationKind.TWITTER;
|
||||
break;
|
||||
case "com.fsck.k9":
|
||||
case "com.android.email":
|
||||
notificationKind = NotificationKind.EMAIL;
|
||||
break;
|
||||
case "eu.siacs.conversations":
|
||||
notificationKind = NotificationKind.CHAT;
|
||||
break;
|
||||
case "org.indywidualni.fblite":
|
||||
notificationKind = NotificationKind.FACEBOOK;
|
||||
break;
|
||||
default:
|
||||
notificationKind = NotificationKind.UNDEFINED;
|
||||
break;
|
||||
}
|
||||
|
||||
LOG.info("Processing notification from source " + source);
|
||||
|
Loading…
Reference in New Issue
Block a user