From a56e35ef741925bc46a8f2202eca6a023b34d85a Mon Sep 17 00:00:00 2001 From: mfranz <mfranz> Date: Wed, 23 Nov 2005 12:48:09 +0000 Subject: [PATCH] of course I should have known that it would only work in tests *before* committing, and would instantly break afterwards. Causes endless loops. Re-uglify. Sorry for the noise. :-/ --- src/Input/input.cxx | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/Input/input.cxx b/src/Input/input.cxx index 4c80da2dd..48ea1c2b4 100644 --- a/src/Input/input.cxx +++ b/src/Input/input.cxx @@ -265,13 +265,19 @@ FGInput::doKey (int k, int modifiers, int x, int y) b.last_state = 0; } else { if (k >= 1 && k <= 26) { + if (_key_bindings[k + '@'].last_state) doKey(k + '@', KEYMOD_RELEASED, x, y); + if (_key_bindings[k + '`'].last_state) doKey(k + '`', KEYMOD_RELEASED, x, y); } else if (k >= 'A' && k <= 'Z') { + if (_key_bindings[k - '@'].last_state) doKey(k - '@', KEYMOD_RELEASED, x, y); + if (_key_bindings[tolower(k)].last_state) doKey(tolower(k), KEYMOD_RELEASED, x, y); } else if (k >= 'a' && k <= 'z') { + if (_key_bindings[k - '`'].last_state) doKey(k - '`', KEYMOD_RELEASED, x, y); + if (_key_bindings[toupper(k)].last_state) doKey(toupper(k), KEYMOD_RELEASED, x, y); } }