开发者

Android sectioned listview with complex view

开发者 https://www.devze.com 2023-04-09 23:38 出处:网络
Iwant to use Jeff S. example for sectioned 开发者_C百科listview with headers. But I want to use more complex item view.

I want to use Jeff S. example for sectioned 开发者_C百科listview with headers.

But I want to use more complex item view.

Can you suggest me which approach is best to do this. I found two ways

  1. Put information in Map<String,String> item = new HashMap<String,String>(); using item.put() - example here

2.Using getView on ArrayAdapter (without overriding other methods ) - example here

Which way is better?

Thanks


Depending on the complexity of your listitems it might be better to write your own adapter by extending BaseAdapter. This link has a nice tutorial on how to write your own adapters.

0

精彩评论

暂无评论...
验证码 换一张
取 消