Duplicate:
Background ListView becomes black when scrolling
I have a listview within which each item contains black text on a white background. When testing on a Nexus One, when scrolling down to read through the text, a black highlight appears over the text and makes it unreadable.
I am trying to figure out what is this setting so I can turn it off. I do not want anything to get highlighted when scrolling down through the list. How can I accomplish this?
Thanks.
You probably want to set the cacheColorHint to the same color as your background.
So, when you're defining your layout, just add android:cacheColorHint='#fff'
to your ListView:
<ListView android:id="@+id/list"
android:cacheColorHint="#fff"
android:background="#fff"
...etc />
This may be a trick:
android:cacheColorHint="@android:color/transparent"
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With