Reputation: 58083
In ListView
I can change the divider image using android:divider=image
but I want to display different divider images for different items how can I do that ?
Upvotes: 6
Views: 4797
Reputation: 1007099
AFAIK there is no means to have different dividers in different locations in a single list. Either follow Mr. Webb's recommendation (i.e., put the "dividers" in the list items), or keep a consistent divider, or perhaps subclass/reimplement ListView
to provide the functionality you seek.
Upvotes: 2
Reputation: 193714
Why not have no divider images and make the divider part of the View for each item?
For example, at the top of the view you have a label and an icon and at the bottom you have your divider image.
Upvotes: 6