Fix attention notice

This commit is contained in:
Victor Shcherb 2013-07-30 01:01:14 +02:00
parent 7b9ade94e8
commit e09118f389

View file

@ -236,12 +236,12 @@ public class VoiceRouter {
} }
} else if (alarm.getTime() == AlarmInfo.SPEED_CAMERA) { } else if (alarm.getType() == AlarmInfo.SPEED_CAMERA) {
if (router.getSettings().SPEAK_SPEED_CAMERA.get() && ms - lastAnnouncedSpeedCamera > 100 * 1000) { if (router.getSettings().SPEAK_SPEED_CAMERA.get() && ms - lastAnnouncedSpeedCamera > 100 * 1000) {
CommandBuilder p = getNewCommandPlayerToPlay(); CommandBuilder p = getNewCommandPlayerToPlay();
if (p != null) { if (p != null) {
lastAnnouncedSpeedCamera = ms; lastAnnouncedSpeedCamera = ms;
p.speedAlarm().play(); p.attention(alarm.getType()+"").play();
} }
} }
} else { } else {
@ -249,7 +249,7 @@ public class VoiceRouter {
CommandBuilder p = getNewCommandPlayerToPlay(); CommandBuilder p = getNewCommandPlayerToPlay();
if (p != null) { if (p != null) {
lastAnnouncedWarning = ms; lastAnnouncedWarning = ms;
p.speedAlarm().play(); p.attention(alarm.getType()+"").play();
} }
} }
} }