Hi!
So I have a screen, some Nifty controls on there like Sliders, TextFields etc and also, at the very bottom, a simple Nifty text element which is basically serving as a button for me, which means it is clickable and calls a method that changes the screen. I also made sure to enable its “focusable” attribute.
Now when the screen starts, the keyboard focus is on one of the Nifty controls as it should be, and as expected, by pressing the TAB button, the focus moves to the next control and so on. Once my text element gets the focus though, pressing TAB has no effect anymore, although the focus should actually move to the first element again. Also, pressing Enter has no effect (like it has on e.g. a CheckBox)
I’ve looked at the Nifty control definitions and don’t find any special code which deals with keyboard input, so how come keyboard handling (at least of the pre-defined default keys) works fine with Nifty Controls but not with my text element?
What do I have to do that my text element reacts to keyboard input, in particular the pre-defined default keys like TAB, Enter etc.?
Thanks in advance!
KB