I am making an Android app in which I show a Dialog Fragment where users can sumbit text. The problem is that the keyboard shows over the dialog and I couldn't find any way to fix it! I've tried doing the following with no luck:
Adding the
android:windowSoftInputMode
attribute in myAndroidManifest.xml
with multiple values like"adjustPan|adjustResize"
Using
dialog.getWindow().setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_STATE_HIDDEN);
withSOFT_INPUT_STATE_HIDDEN
,SOFT_INPUT_ADJUST_RESIZE
but that just crushes the content of the dialog.This answer: https://stackoverflow.com/a/51821469/6766678 where the screenshots are what I want to achieve.
This is what my dialog looks like when the keyboard is open:
Any help is appreciated!