Don't resolve a key to a deprecated name.

This commit is contained in:
Erik Broes 2012-11-27 16:15:43 +01:00
parent ef62a8371b
commit ee69763707
1 changed files with 2 additions and 1 deletions

View File

@ -229,7 +229,8 @@ public class Keyboard {
&& Modifier.isPublic(field.getModifiers())
&& Modifier.isFinal(field.getModifiers())
&& field.getType().equals(int.class)
&& field.getName().startsWith("KEY_") ) {
&& field.getName().startsWith("KEY_")
&& !field.getName().endsWith("WIN") ) { /* Don't use deprecated names */
int key = field.getInt(null);
String name = field.getName().substring(4);