我在DialogFragment底部有一个AppCompatAutoCompleteTextView.
@H_502_2@在横向模式下的平板电脑(API 19)上,当建议列表中只有一个元素时,键盘会覆盖下拉列表.当有更多元素时,下拉列表会向上移动,并且工作正常.
@H_502_2@在移动设备(API 22)上,即使建议列表中只有一个元素,也没有任何问题,下拉列表始终向上显示.
@H_502_2@我已经将man:windowSoftInputMode =“adjustPan | stateHidden”添加到Manifest中的活动中.
@H_502_2@如何使下拉键始终向上或不被键盘覆盖?
解决方法
Work around the below the completionThreshold. Hope it works for you! <AutoCompleteTextView android:id="@+id/someID" android:layout_width="200dp" android:layout_height="wrap_content" android:completionThreshold="1" />@H_502_2@要么
autocomplete.setThreshold(2);