]> git.mxchange.org Git - flightgear.git/commitdiff
of course I should have known that it would only work in tests *before*
authormfranz <mfranz>
Wed, 23 Nov 2005 12:48:09 +0000 (12:48 +0000)
committermfranz <mfranz>
Wed, 23 Nov 2005 12:48:09 +0000 (12:48 +0000)
committing, and would instantly break afterwards. Causes endless loops.
Re-uglify. Sorry for the noise.  :-/

src/Input/input.cxx

index 4c80da2ddc48c98c89f8f020c070a290df34f823..48ea1c2b49bd0790625b9473643abfaadd9fd0fe 100644 (file)
@@ -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);
       }
     }