summaryrefslogtreecommitdiffstats
path: root/services/java/com
diff options
context:
space:
mode:
Diffstat (limited to 'services/java/com')
-rwxr-xr-xservices/java/com/android/server/NotificationManagerService.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/services/java/com/android/server/NotificationManagerService.java b/services/java/com/android/server/NotificationManagerService.java
index 93ae029..09a606e 100755
--- a/services/java/com/android/server/NotificationManagerService.java
+++ b/services/java/com/android/server/NotificationManagerService.java
@@ -1069,8 +1069,9 @@ public class NotificationManagerService extends INotificationManager.Stub
}
mSoundNotification = r;
// do not play notifications if stream volume is 0
- // (typically because ringer mode is silent).
- if (audioManager.getStreamVolume(audioStreamType) != 0) {
+ // (typically because ringer mode is silent) or if speech recognition is active.
+ if ((audioManager.getStreamVolume(audioStreamType) != 0)
+ && !audioManager.isSpeechRecognitionActive()) {
final long identity = Binder.clearCallingIdentity();
try {
final IRingtonePlayer player = mAudioService.getRingtonePlayer();