Fixes double playing of audio notification if notification and playback device are the same.

cusax-fix
Damian Minkov 13 years ago
parent 69dd878775
commit a754cc94e0

@ -49,14 +49,33 @@ public void start(SoundNotificationAction action, NotificationData data)
if(isMute())
return;
if(action.isSoundNotificationEnabled())
boolean playOnlyOnPlayback = true;
AudioNotifierService audioNotifService
= NotificationActivator.getAudioNotifier();
if(audioNotifService != null)
playOnlyOnPlayback =
audioNotifService.audioOutAndNotificationsShareSameDevice();
if(playOnlyOnPlayback)
{
play(action, data, false);
if(action.isSoundNotificationEnabled()
|| action.isSoundPlaybackEnabled())
{
play(action, data, true);
}
}
if(action.isSoundPlaybackEnabled())
else
{
play(action, data, true);
if(action.isSoundNotificationEnabled())
{
play(action, data, false);
}
if(action.isSoundPlaybackEnabled())
{
play(action, data, true);
}
}
if(action.isSoundPCSpeakerEnabled())

Loading…
Cancel
Save