aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorMax Horn2009-02-25 19:05:54 +0000
committerMax Horn2009-02-25 19:05:54 +0000
commit71a07c7c9f7fd1de145c5e0466a0d4fe56f9d19b (patch)
tree9d978a851739f6fb383bad5137be4eaa33cdc5c6 /engines
parent3a000f3d84531288690a665297ec0180daab8b2d (diff)
downloadscummvm-rg350-71a07c7c9f7fd1de145c5e0466a0d4fe56f9d19b.tar.gz
scummvm-rg350-71a07c7c9f7fd1de145c5e0466a0d4fe56f9d19b.tar.bz2
scummvm-rg350-71a07c7c9f7fd1de145c5e0466a0d4fe56f9d19b.zip
SCI: Added remark that we don't track capslock, numlock, scrlock properly
svn-id: r38882
Diffstat (limited to 'engines')
-rw-r--r--engines/sci/gfx/gfx_driver.cpp11
1 files changed, 10 insertions, 1 deletions
diff --git a/engines/sci/gfx/gfx_driver.cpp b/engines/sci/gfx/gfx_driver.cpp
index 528904c7b5..e9b1036d79 100644
--- a/engines/sci/gfx/gfx_driver.cpp
+++ b/engines/sci/gfx/gfx_driver.cpp
@@ -336,6 +336,16 @@ static sci_event_t scummvm_get_event(gfx_driver_t *drv) {
// We add the modifier key status to buckybits
// SDL sends a keydown event if a modifier key is turned on and a keyup event if it's off
+ //
+ // FIXME: This code is semi-bogus. It only records the modifier key being *pressed*.
+ // It does not track correctly whether capslock etc. is active. To do that, we
+ // would have to record the fact that the modifier was pressed in global var,
+ // and also watch for Common::EVENT_KEYUP events.
+ // But this is still not quite good enough, because not all events might
+ // pass through here (e.g. the GUI might be running with its own event loop).
+ //
+ // The best solution likely would be to add code to the EventManager class
+ // for tracking which keys are pressed and which are not...
if (ev.type == Common::EVENT_KEYDOWN) {
switch (ev.kbd.keycode) {
case Common::KEYCODE_CAPSLOCK:
@@ -351,7 +361,6 @@ static sci_event_t scummvm_get_event(gfx_driver_t *drv) {
break;
}
}
-
//TODO: SCI_EVM_INSERT
switch (ev.type) {