Android equivalent to iphone indexed UITableView

后端 未结 3 1266
执笔经年
执笔经年 2020-12-18 07:06

I am porting an iPhone app over to the Android platform. One of the views has a very large list of data and on the iPhone app, there\'s a scrollbar of sorts on the right han

相关标签:
3条回答
  • 2020-12-18 07:35

    The Android way to do this is to make the list filterable using the keyboard, like a Blackberry. You should do it this way to fit in with the platform experience.

    To implement this, you call the setTextFilterEnabled(boolean textFilterEnabled) method on your list view. See example below:

    myListView.setTextFilterEnabled(true);
    

    For a complete example, see Hello, ListView.


    If you can't use that, then you can use the fast scrolling like seen in the Contacts application. This is not a public API yet, but you can implement it from the Contacts source code at https://android.googlesource.com/platform/packages/apps/Contacts .

    0 讨论(0)
  • 2020-12-18 07:43

    Right side Alphabet indexer with working sources http://hello-android.blogspot.com/2010/11/sideindex-for-android.html

    0 讨论(0)
  • 2020-12-18 07:49

    I think this is implemented through AlphabetIndexer, though I have not tried it personally.

    0 讨论(0)
提交回复
热议问题