SDLK_Pause to toggle "mute"

This commit is contained in:
Chris Danford
2004-04-17 20:14:59 +00:00
parent 3df5082068
commit aec7f829b3
+9
View File
@@ -1352,6 +1352,15 @@ bool HandleGlobalInputs( DeviceInput DeviceI, InputEventType type, GameInput Gam
}
}
if(DeviceI == DeviceInput(DEVICE_KEYBOARD, SDLK_PAUSE))
{
static bool bMute = false;
bMute = !bMute;
SOUNDMAN->SetPrefs( bMute ? 0 : PREFSMAN->m_fSoundVolume );
SCREENMAN->SystemMessage( bMute ? "Mute on" : "Mute off" );
return true;
}
return false;
}