Search code examples
androidandroid-listviewandroid-4.0-ice-cream-sandwich

Android ICS Contacts app SDK element


I have been looking at AlphabetIndexer and SectionIndexer and noticed in the Ice Cream Sandwich emulator that the Contact list UI is a little bit different now than in the previous Android versions (specifically how they pop up the current character when scrolling through contacts).

Does anyone know what SDK API they are using for this in ICS? Or if they are hand-rolling this?


Solution

  • It's a custom solution called PinnedHeaderListView.

    It was added in Froyo (for some reason I thought it had been added in ICS, oops!)...

    You can find it's source code here: https://android.googlesource.com/platform/packages/apps/Contacts/+/froyo-release/src/com/android/contacts/PinnedHeaderListView.java