From f93bb8eedc66524fa63d68fc679c88898c709f1f Mon Sep 17 00:00:00 2001 From: mfranz Date: Wed, 23 Nov 2005 12:28:27 +0000 Subject: [PATCH] remove a few if's to make the ugly fix a little less ugly; they only save a few CPU cycles but are really redundant --- src/Input/input.cxx | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/src/Input/input.cxx b/src/Input/input.cxx index f1e91d0d5..4c80da2dd 100644 --- a/src/Input/input.cxx +++ b/src/Input/input.cxx @@ -265,19 +265,13 @@ 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); + 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); } } -- 2.39.5