I need to animate the insertion of a tableview header view. I want that the table rows to slide down while the header view expands its frame.
So far the best result I go
The selected answer didn't work for me. Had to do the following:
[UIView animateWithDuration: 0.5f
animations: ^{
CGRect frame = self.tableView.tableHeaderView.frame;
frame.size.height = self.headerViewController.preferredHeight;
self.tableView.tableHeaderView.frame = frame;
self.tableView.tableHeaderView = self.tableView.tableHeaderView;
}];
The really peculiar part is that this works in one view but not in a subclass of the same view controller / view hierarchy.