aboutsummaryrefslogtreecommitdiff
path: root/engines/pegasus
diff options
context:
space:
mode:
authorMatthew Hoops2014-06-01 22:36:45 -0400
committerMatthew Hoops2014-06-01 22:38:05 -0400
commitc293611f62d83359e3c780ce556859151900864b (patch)
tree1b104e490880d9b0ed1b0baf9a33b267aeaf528e /engines/pegasus
parent62e5fdc95cf68e74b1c3b448051e621fd66ac70b (diff)
downloadscummvm-rg350-c293611f62d83359e3c780ce556859151900864b.tar.gz
scummvm-rg350-c293611f62d83359e3c780ce556859151900864b.tar.bz2
scummvm-rg350-c293611f62d83359e3c780ce556859151900864b.zip
PEGASUS: Stop using num lock for a way to open the inventory drawer
Diffstat (limited to 'engines/pegasus')
-rw-r--r--engines/pegasus/input.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/engines/pegasus/input.cpp b/engines/pegasus/input.cpp
index 283d55421f..3f16acc2f6 100644
--- a/engines/pegasus/input.cpp
+++ b/engines/pegasus/input.cpp
@@ -57,7 +57,6 @@ InputDeviceManager::InputDeviceManager() {
_keyMap[Common::KEYCODE_p] = false;
_keyMap[Common::KEYCODE_TILDE] = false;
_keyMap[Common::KEYCODE_BACKQUOTE] = false;
- _keyMap[Common::KEYCODE_NUMLOCK] = false;
_keyMap[Common::KEYCODE_BACKSPACE] = false;
_keyMap[Common::KEYCODE_KP_MULTIPLY] = false;
_keyMap[Common::KEYCODE_LALT] = false;
@@ -113,7 +112,12 @@ void InputDeviceManager::getInput(Input &input, const InputBits filter) {
if (_keyMap[Common::KEYCODE_ESCAPE] || _keyMap[Common::KEYCODE_p])
currentBits |= (kRawButtonDown << kMod3ButtonShift);
- if (_keyMap[Common::KEYCODE_TILDE] || _keyMap[Common::KEYCODE_BACKQUOTE] || _keyMap[Common::KEYCODE_NUMLOCK])
+ // The original also used clear (aka "num lock" on Mac keyboards) here, but it doesn't
+ // work right on most systems. Either SDL or the OS treats num lock specially and the
+ // events don't come as expected. In many cases, the key down event is sent many times
+ // causing the drawer to open and close constantly until pressed again. It only causes
+ // more grief than anything else.
+ if (_keyMap[Common::KEYCODE_TILDE] || _keyMap[Common::KEYCODE_BACKQUOTE])
currentBits |= (kRawButtonDown << kLeftFireButtonShift);
if (_keyMap[Common::KEYCODE_BACKSPACE] || _keyMap[Common::KEYCODE_KP_MULTIPLY])