Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android ListView alpha scroller for quickly scrolling long list

The Contacts app shows a button on the side of the screen that acts as a little thumb to allow you to quickly scroll the big list. I have a very long list that would benefit from this navigation behavior, but can't find any documentation as to how to enable it.

Is it a behavior that's built into the SDK, or must I write it myself?

like image 367
Ecton Avatar asked Feb 26 '10 23:02

Ecton


1 Answers

Yes, it is included in the sdk. See here:

http://developer.android.com/reference/android/widget/AbsListView.html#attr_android:fastScrollEnabled

just set this property. If you want to further enhance this like the contacts that shows the letters for the section you are in you can use this.

http://developer.android.com/reference/android/widget/SectionIndexer.html

like image 136
broschb Avatar answered Sep 27 '22 18:09

broschb