views:

24

answers:

0

I'm trying to make a simple accordion-style menu system for iPad using a UITableView and expanding rows.

The way I implement this is storing the selected index path and in heightForRowAtIndexPath: conditionally setting the row with that index to be larger. In didSelectRowAtIndexPath: I provide an empty update block so that the table will animate to the new row height.

This works great in iOS 3.1.3 and below. If I tap on a cell, the rows animate as expected.

However, if I build the same project in iOS 3.2, the animation is not what I want; instead of sliding, the row separators snap to their new location and then the rest of the cell follows. I haven't checked to see if this behavior is present in iOS 4.0.

I've attached a small example project to better illustrate what I'm talking about. Project Link

Is there another way to implement this behavior or a different way to animate the height changes? Is this really a problem or am I doing something wrong in my implementation?

Any thoughts are appreciated.