Scrolling drop-down-menu over the keyboard in autocompletetextview

后端 未结 6 1386
一生所求
一生所求 2021-01-04 02:16

I have an Autocompletetextview dropping down the suggestions list, up to the border of the soft-keyboard.

Then, when scrolling over the suggestions list: - (in a g

6条回答
  •  有刺的猬
    2021-01-04 02:55

    Let me explain my little trick to avoid that the "drop-down" displays behind the keyboard. The trick is with the dropDownAnchor property. The solution is set the anchor with a view located on the top of the screen, so the menu will leave from that position, and therefore, will not be covered by the keyboard. For example:

    android:dropDownAnchor="@+id/topview"

    I know that is an ugly solution but this control is too limited.

提交回复
热议问题