Why does Wrap_Content fire BindView more than once

Viewed 1133

I am working on an Android app with a listView and am in the process of optimizing it. It uses a custom cursor adapter in one activity and I noticed that bindview() was firing twice for each row of the list. While researching the BindView() and NewView() methods here, I read in a post that having Wrap_Content for the width of my listview was a bad idea. I switched it to Fill_Parent and viola now bindview() and newview() each only fire once for each item.

So that I can better understand the internals of the Andorid OS, I would like to know why Wrap_Content caused bindview() to fire multiple times.

I have done several searches on Google, the android developer docs and here with no luck.

Any response is really appreciated.

Thanks, George

1 Answers
Related