I have a grouped table that I want the user to be able to reorder. I would like to have two groups. When I move a row from group A, to group B, I would like the top row from group B to be moved to the bottom of group A. When I move a row from group B to group A, I would like the bottom row of group A to be moved to the top of Group B.
This way the size of each group in the table is maintained. Is this possible?
Thank you very much!
I have not been able to find an obvious way to do this in a way that causes the rows to move while the drag is in progress.
However, I do have something that should work once the drag is complete. However, for some reason I don't understand, the display is screwed up when the drag completes. Here is how I'm doing it:
This should be right, but when the drag is complete, cells go totally missing from the display (with only the background visible where the cell should be).
I've tried calling [self.tableview reloadData] from within moveRowAtIndexPath, but Apple's documentation says "It should not be called in the methods that insert or delete rows, especially within an animation block implemented with calls to beginUpdates and endUpdates"
I'm stuck on this and seeking input on how to fix the display issue.