diff options
author | Max Horn | 2009-03-11 02:05:49 +0000 |
---|---|---|
committer | Max Horn | 2009-03-11 02:05:49 +0000 |
commit | e3b5e5a74c7db8f1adbeb7891518348390c9e608 (patch) | |
tree | 6a28fc57f233c1f3959b668bf8775d4a1dc6a969 /engines/sci/gfx | |
parent | 47cf6a0151114ab560b4ed0aaf9eef7e5163a63f (diff) | |
download | scummvm-rg350-e3b5e5a74c7db8f1adbeb7891518348390c9e608.tar.gz scummvm-rg350-e3b5e5a74c7db8f1adbeb7891518348390c9e608.tar.bz2 scummvm-rg350-e3b5e5a74c7db8f1adbeb7891518348390c9e608.zip |
SCI: Restored code to triger debugger console by Ctrl-d (accidentally removed it in rev 39201)
svn-id: r39326
Diffstat (limited to 'engines/sci/gfx')
-rw-r--r-- | engines/sci/gfx/operations.cpp | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/engines/sci/gfx/operations.cpp b/engines/sci/gfx/operations.cpp index 9890df918d..0aa8598cc6 100644 --- a/engines/sci/gfx/operations.cpp +++ b/engines/sci/gfx/operations.cpp @@ -1485,6 +1485,21 @@ static sci_event_t scummvm_get_event(gfx_driver_t *drv) { input.data = ev.kbd.keycode; input.character = ev.kbd.ascii; + // Debug console + if (ev.kbd.flags == Common::KBD_CTRL && ev.kbd.keycode == Common::KEYCODE_d) { + + ((Sci::SciEngine*)g_engine)->_console->attach(); + ((Sci::SciEngine*)g_engine)->_console->onFrame(); + + // Clear keyboard event + input.type = SCI_EVT_NONE; + input.character = 0; + input.data = 0; + input.buckybits = 0; + + return input; + } + if (!(input.data & 0xFF00)) { // Directly accept most common keys without conversion input.type = SCI_EVT_KEYBOARD; |