SCUMM: Handle all triggers for the debugger console in the same spot, to ensure uniform behavior

svn-id: r27777
This commit is contained in:
Max Horn 2007-06-29 22:39:52 +00:00
parent 328858d454
commit 314ef72bb1

View File

@ -79,7 +79,8 @@ void ScummEngine::parseEvents() {
_fastMode ^= 1;
} else if (event.kbd.flags == Common::KBD_CTRL && event.kbd.keycode == 'g') {
_fastMode ^= 2;
} else if (event.kbd.flags == Common::KBD_CTRL && event.kbd.keycode == 'd') {
} else if ((event.kbd.flags == Common::KBD_CTRL && event.kbd.keycode == 'd') ||
event.kbd.ascii == '~' || event.kbd.ascii == '#') {
_debugger->attach();
} else if (event.kbd.flags == Common::KBD_CTRL && event.kbd.keycode == 's') {
_res->resourceStats();
@ -559,9 +560,6 @@ void ScummEngine::processKeyboard(Common::KeyState lastKeyHit) {
if (VAR_CHARINC != 0xFF)
VAR(VAR_CHARINC) = _defaultTalkDelay;
} else if (lastKeyHit.ascii == '~' || lastKeyHit.ascii == '#') { // Debug console
_debugger->attach();
} else {
// FIXME: Possibly convert even more keycode/ascii pairs to their SCUMM counterparts?
if (lastKeyHit.keycode >= Common::KEYCODE_F1 && lastKeyHit.keycode <= Common::KEYCODE_F9) {