void256/nifty-gui — pull request #151 by 3xp0n3nt (2013-10-13 04:47:01+00:00)
Title: Fix bugs in nifty-renderer-libgdx.

Fix several bugs in nifty-renderer-libgdx module:

1) Attempting to type a capital C (with either SHIFT + C or c with
CAPSLOCK on) in a TextField control is not typing a capital C but
instead is activating backspace. It turns out that the GdxInputSystem
needs to set the nifty key code to 0 for character keys, but in fact, it
is setting the key code to a completely incorrect value for every single
character key. The problem just happened to manifest with 'C' because it
is sending the key code of backspace with it. Now, for all printable
character keys, the key code sent to nifty will be 0, since it should be
ignored for all printable character keys - you only need the character
itself. Key codes for non-printable control keys are already correct,
and are not affected by this fix.

2) Forward delete is not working at all in a TextField control. It turns
out that GdxKeyboardInputEvent.getNiftyKeyCode, which maps libGDX key
codes to Nifty key codes, did not have a mapping set up for forward
delete. Add a mapping for forward delete so that it works in TextField
controls.

3) Set forward delete to repeat in nifty-examples-libgdx using the
GdxKeyRepeatSystem.