Landscape SW keyboard without text field above it?
SOLVED: Removed edittext and showed keyboard using
imgr.toggleSoftInput(0, 0);
Original question:
Hello, I am developing a remote controller app with touchpad/keyboard modes. My problem is with SW keyboard. When user presses a key on SW keyboard I need to send this value to PC. I managed to do that in portrait mode with hidden EditText but when I change the orientation to landscape, the SW keyboard opens with the white text field which covers all the space above the keyboard and it shows the text user has written. Is there any way i could open and listen to landscape keyboard without that text field?
My code for opening the SW keyboard:
InputMethodManager imgr = (InputMethodManager) getSystemSer开发者_如何学运维vice(this.INPUT_METHOD_SERVICE);
imgr.showSoftInput(edKeyListener, InputMethodManager.SHOW_FORCED);
And the EditText xml:
<EditText
android:id="@+id/keyListener"
android:layout_width="0dp"
android:layout_height="0dp"
android:inputType="textFilter" />
SOLVED: Removed edittext and showed keyboard using
imgr.toggleSoftInput(0, 0);
精彩评论