I have a DialogFragment
with two input fields and two buttons. In portrait mode
everything is fine, but in landscape mode
when an input field is focused the whole Dialog disappears so the buttons are not there. Screen is then covered by a keyboard and a "next" buttons image (where does it come from ?). What can I do to prevent ? Tried setting android:windowSoftInputMode
but no difference
Asked
Active
Viewed 253 times
0

jreft56
- 199
- 1
- 12
-
You can prevent landscape mode. – fbwnd Jul 09 '17 at 12:53
-
This is not a solution. – jreft56 Jul 09 '17 at 13:05
1 Answers
0
Best way is to use different layouts:
res/layout [Portrait Mode; default]
main.xml
res/layout-land [Landscape Mode]
main.xml

Mojtaba Hosseini
- 95,414
- 31
- 268
- 278

Rasoul Miri
- 11,234
- 1
- 68
- 78
-
But how different ? DialogFragment gets hidden even if I have a single EditText in landscape layout – jreft56 Jul 09 '17 at 13:04