AutoCompleteTextView force to show all items

前端 未结 12 1794
隐瞒了意图╮
隐瞒了意图╮ 2020-12-25 08:10

There is a moment in my app, that I need to force to show all items in the suggestion list, no matter what the user has typed. How can I do that?

I tried to do somet

12条回答
  •  陌清茗
    陌清茗 (楼主)
    2020-12-25 08:32

    Simple and easy answer is:

    after autoCompleteTextView.setText("") simply remove filter from adapter like this:

    autoCompleteTextView.adapter.filter.filter(null)

    thats it, filtering is gone and whole dropdown list is shown.

提交回复
热议问题