I have a similar issue, but my listview is the 2nd view on a page that is dynamically created, so I want to do this with jquery. I tried this:
But the class was applied to all li's. I ran just $('#tasklist-listview li:nth-child(odd)') in the chrome console, and it appeared to return just the alternate li's. Below is the code I use to create the listview.