Question Regarding EditFields and VirtualKeyboards

211 views Asked by At

I have posted a StackOverflow question about the behaviour of the VirtualKeyboard on the Torch simulator. As a follow up question, where does an EditField get it's reference to the Virtual Keyboard on touch devices?

I am trying to display a Real Numeric keyboard (the proper style bit is set on the EditField), yet the keyboard that is displayed (on the Torch simulator when the slider is closed) is a "qwerty" keyboard.

3

There are 3 answers

0
Mike D On BEST ANSWER

Fixed. The answer can be found on my StackOverflow question "Blackberry Torch Simulator and EditField Problem". The trick as to subclass directly from Manager.

The issue was the GridFieldManager, which I had subclassed. I am still not sure how that caused the behaviour I described above. If anyone has any idea please enlighten me.

1
Alexander Farber On

For the follow up question - through the Screen, for example:

    // hide the virtual keyboard by default
    final Screen screen = getScreen();
    if (screen != null) {
        final VirtualKeyboard virtualKeyboard = screen.getVirtualKeyboard();
        if (virtualKeyboard != null) {
            virtualKeyboard.setVisibility(VirtualKeyboard.HIDE);
        }
    }
0
Vivek Kumar Srivastava On

You can add NullField before the EditField. NullField is the invisible Field with FOCUSABLE property.