I've got a grouped UITableView with a couple of rows, and I'm animating a few more rows in and out on the toggle of a button. The problem is that with any of the row animation types I'm using (top & bottom) the animation looks horrible! Here's a screenshot mid-animation:
(source: michaelwaterfall.com)
Is there a reason why it's looking so bad? Or do all grouped table view animations look this shocking!?
I think it only looks so bad when the first or last row in a section is being animated, so I'm just wondering if there's any way to get it looking a bit better!? Otherwise I think I'll just call reloadData and have it all just appear.
Thanks for your help!
Michael
If you remove, add and/or move several rows in a UITableView
at the same time, then you must enclose all these calls with beginUpdates
and endUpdates
. Otherwise the result is undetermined.
For example:
[tableView beginUpdates];
[tableView insertRowsAtIndexPaths:newRows
withAnimation:UITableViewRowAnimationTop];
[tableView deleteRowsAtIndexPaths:invalidRows:
withAnimation:UITableViewRowAnimationTop];
[tableView endUpdates];
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