I launch an AlertDialog
in Android with an EditText
field. When I use portrait orientation runs fine, but when I change to landscape the keyboard hides my alert. How I can I solve this?
Asked
Active
Viewed 222 times
0

Cory Charlton
- 8,868
- 4
- 48
- 68

user3086708
- 375
- 3
- 17
-
You have your answer [here](http://stackoverflow.com/questions/4336762/disabling-the-fullscreen-editing-view-for-soft-keyboard-input-in-landscape). – Uma Kanth Jun 12 '15 at 13:04
1 Answers
0
In landscape, some android devices will cause the keyboard to fullscreen when the focus is on an editable feature of the layout (in your case, EditText).
You can flag the EditText to not fullscreen the keyboard in landscape in two ways:
XML: android:imeOptions="flagNoExtractUi"
Code: myEditText.setImeOptions(EditorInfo.IME_FLAG_NO_EXTRACT_UI);

d0nut
- 2,835
- 1
- 18
- 23