fix speed_alarm prompt

This commit is contained in:
sonora 2013-08-01 19:29:28 +02:00
parent d79687f366
commit dc96d250a3

View file

@ -214,7 +214,7 @@ public class VoiceRouter {
return;
}
long ms = System.currentTimeMillis();
if (alarm.getTime() == AlarmInfo.SPEED_LIMIT) {
if (alarm.getType() == AlarmInfo.SPEED_LIMIT) {
if (waitAnnouncedSpeedLimit == 0) {
// wait 10 seconds before announcement
@ -234,8 +234,7 @@ public class VoiceRouter {
}
}
}
} else if (alarm.getType() == AlarmInfo.SPEED_CAMERA) {
if (router.getSettings().SPEAK_SPEED_CAMERA.get() && ms - lastAnnouncedSpeedCamera > 100 * 1000) {
CommandBuilder p = getNewCommandPlayerToPlay();
@ -253,7 +252,6 @@ public class VoiceRouter {
}
}
}
}
/**