Merge "Don't show ringer status if dnd overrides it" into pi-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
a4e8196cf8
@@ -1469,6 +1469,17 @@ public class ZenModeConfig implements Parcelable {
|
||||
&& !allowRepeatCallers;
|
||||
}
|
||||
|
||||
/**
|
||||
* Determines if DND is currently overriding the ringer
|
||||
*/
|
||||
public static boolean isZenOverridingRinger(int zen, ZenModeConfig zenConfig) {
|
||||
// TODO (beverlyt): check if apps can bypass dnd b/77729075
|
||||
return zen == Global.ZEN_MODE_NO_INTERRUPTIONS
|
||||
|| zen == Global.ZEN_MODE_ALARMS
|
||||
|| (zen == Global.ZEN_MODE_IMPORTANT_INTERRUPTIONS
|
||||
&& ZenModeConfig.areAllPriorityOnlyNotificationZenSoundsMuted(zenConfig));
|
||||
}
|
||||
|
||||
/**
|
||||
* Determines whether dnd behavior should mute all sounds controlled by ringer
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user