Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- context = this;
- locations = getResources().getStringArray(R.array.locations);
- final String[] from = new String[] {"locationName"};
- final int[] to = new int[] {android.R.id.text1};
- locationAdapter = new SimpleCursorAdapter(context,
- android.R.layout.simple_list_item_1,
- null,
- from,
- to,
- CursorAdapter.FLAG_REGISTER_CONTENT_OBSERVER);
- toSearch = (SearchView) findViewById(R.id.toSearch);
- toSearch.setSuggestionsAdapter(locationAdapter);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement