implementing: make raise-blind sound optional (#127)

This commit is contained in:
doitux
2012-03-27 09:38:45 +00:00
parent 295610fbf9
commit 9ee82a05c5
4 changed files with 23 additions and 11 deletions
+10 -8
View File
@@ -27,14 +27,16 @@ void SoundEvents::blindsWereSet(int sB)
lastSBValue = sB;
++lastSBLevel;
if(lastSBLevel == 1 || lastSBLevel == 2) {
mySDLPlayer->playSound("blinds_raises_level1", 0);
}
if(lastSBLevel == 3 || lastSBLevel == 4) {
mySDLPlayer->playSound("blinds_raises_level2", 0);
}
if(lastSBLevel >= 5) {
mySDLPlayer->playSound("blinds_raises_level3", 0);
if(myConfig->readConfigInt("PlayBlindRaiseNotification")) {
if(lastSBLevel == 1 || lastSBLevel == 2) {
mySDLPlayer->playSound("blinds_raises_level1", 0);
}
if(lastSBLevel == 3 || lastSBLevel == 4) {
mySDLPlayer->playSound("blinds_raises_level2", 0);
}
if(lastSBLevel >= 5) {
mySDLPlayer->playSound("blinds_raises_level3", 0);
}
}
}
}