How to create a clearable autocomplete dropdown with AutoCompleteTextView

I wanted to create a nice search box with autocomplete results dropdown in the ActionBar. I could have used the SearchView widget but I didn’t want to create a searchable activity and all the necessary overhead. Instead I used a more lightweight approach with AutoCompleteTextView. I’ll explain here the steps needed to be done in order to make it work. My model app was the Gmail app which looks like this : »

Author image Michael DeRazon on #android,