Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想在列表视图中每行显示多个列表项。显示没有问题,因为我覆盖了getView和getCount。但问题在于 onItemClickListener:我似乎无法区分单击了哪个列表项。关于如何做到这一点的任何想法?
感谢@dymmeh,我了解了 GridView 组件,它完全符合我的要求!谢谢@dymmeh
为了区分单击了哪个列表项,您可以在适配器的 getView() 方法中提供该项的单击侦听器。