mirror of
https://github.com/M66B/NetGuard.git
synced 2024-12-22 15:58:25 +00:00
Bypass DND
This commit is contained in:
parent
cb7281990a
commit
082e59c0b8
1 changed files with 2 additions and 0 deletions
|
@ -67,10 +67,12 @@ public class ApplicationEx extends Application {
|
||||||
|
|
||||||
NotificationChannel notify = new NotificationChannel("notify", getString(R.string.channel_notify), NotificationManager.IMPORTANCE_DEFAULT);
|
NotificationChannel notify = new NotificationChannel("notify", getString(R.string.channel_notify), NotificationManager.IMPORTANCE_DEFAULT);
|
||||||
notify.setSound(null, Notification.AUDIO_ATTRIBUTES_DEFAULT);
|
notify.setSound(null, Notification.AUDIO_ATTRIBUTES_DEFAULT);
|
||||||
|
notify.setBypassDnd(true);
|
||||||
nm.createNotificationChannel(notify);
|
nm.createNotificationChannel(notify);
|
||||||
|
|
||||||
NotificationChannel access = new NotificationChannel("access", getString(R.string.channel_access), NotificationManager.IMPORTANCE_DEFAULT);
|
NotificationChannel access = new NotificationChannel("access", getString(R.string.channel_access), NotificationManager.IMPORTANCE_DEFAULT);
|
||||||
access.setSound(null, Notification.AUDIO_ATTRIBUTES_DEFAULT);
|
access.setSound(null, Notification.AUDIO_ATTRIBUTES_DEFAULT);
|
||||||
|
access.setBypassDnd(true);
|
||||||
nm.createNotificationChannel(access);
|
nm.createNotificationChannel(access);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue