我使用适配器来填充 AutoCompleteTextView。起初,一切都很好。AutoCompleteTextView 工作正常。然后我想去另一个活动做一些工作。但是当我回来时,即使适配器有正确的数据,AutoCompleteTextView 也不显示任何下拉列表。我该如何解决?
ArrayAdapter adapterStart;
AutoCompleteTextview busInfo_start;
AutoCompleteTextview busInfo_start;
List<AutoCotent> auto_list;// Before the code below,these variable have already initialized
adapterStart = new AutoTipAdapter(view.getContext(),R.layout.auto_tip_item, auto_list);
busInfo_start.clearListSelection();
busInfo_start.clearComposingText();
busInfo_start.setFocusable(true);
busInfo_start.setAdapter(adapterStart);
adapterStart.notifyDataSetChanged();