[Scummvm-cvs-logs] SF.net SVN: scummvm:[55568] scummvm/trunk/engines/toon/toon.cpp
thebluegr at users.sourceforge.net
thebluegr at users.sourceforge.net
Thu Jan 27 15:20:17 CET 2011
Revision: 55568
http://scummvm.svn.sourceforge.net/scummvm/?rev=55568&view=rev
Author: thebluegr
Date: 2011-01-27 14:20:16 +0000 (Thu, 27 Jan 2011)
Log Message:
-----------
TOON: Check for the state of modifier keys (control/alt/shift) when handling game hotkeys
Fixes bug #3166522 at engine level (fix 2/2)
Modified Paths:
--------------
scummvm/trunk/engines/toon/toon.cpp
Modified: scummvm/trunk/engines/toon/toon.cpp
===================================================================
--- scummvm/trunk/engines/toon/toon.cpp 2011-01-27 14:17:59 UTC (rev 55567)
+++ scummvm/trunk/engines/toon/toon.cpp 2011-01-27 14:20:16 UTC (rev 55568)
@@ -180,27 +180,27 @@
while (_event->pollEvent(event)) {
switch (event.type) {
case Common::EVENT_KEYUP:
- if (event.kbd.ascii == 27 || event.kbd.ascii == 32) {
+ if ((event.kbd.ascii == 27 || event.kbd.ascii == 32) && !event.kbd.flags) {
_audioManager->stopCurrentVoice();
}
- if (event.kbd.keycode == Common::KEYCODE_F5) {
+ if (event.kbd.keycode == Common::KEYCODE_F5 && !event.kbd.flags) {
if(canSaveGameStateCurrently())
saveGame(-1, Common::String());
}
- if (event.kbd.keycode == Common::KEYCODE_F6) {
+ if (event.kbd.keycode == Common::KEYCODE_F6 && !event.kbd.flags) {
if(canLoadGameStateCurrently())
loadGame(-1);
}
- if (event.kbd.ascii == 't') {
+ if (event.kbd.ascii == 't' && !event.kbd.flags) {
_showConversationText = !_showConversationText;
}
- if (event.kbd.ascii == 'm') {
+ if (event.kbd.ascii == 'm' && !event.kbd.flags) {
_audioManager->muteMusic(!_audioManager->isMusicMuted());
}
- if (event.kbd.ascii == 'd') {
+ if (event.kbd.ascii == 'd' && !event.kbd.flags) {
_audioManager->muteVoice(!_audioManager->isVoiceMuted());
}
- if (event.kbd.ascii == 's') {
+ if (event.kbd.ascii == 's' && !event.kbd.flags) {
_audioManager->muteSfx(!_audioManager->isSfxMuted());
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list