I have created a MultilineCell for my app, which shows first a UILabel consisting of 1-n lines of text and below that another UILabel with a single line of text.
To handle the corresponding UITableView entering editing mode, I check for self.editing in my overwritten -layoutSubviews and adjust the dimensions accordingly. This catches all changes in the layout that can result from the delete knob to the left and/or the delete button to the right appear.
However: on occasion, the additional widgets in editing mode cause the text in the multiline label to wrap in such a way that a new line is added. As I set out to adapt -heightForTableRowAtIndexPath: to calculate the height in a different way when editing mode is active, I noticed that -heightForTableRowAtIndexPath: is not called at all when the editing mode of the tableView changes. Looking further into UITableViewDelegate, I only found methods handling the editing of individual rows. But what I am looking for is a way to be notified when the UITableView as a whole has entered or left editing mode so I can call -setNeedsLayout so that the table queries the heights of the individual cells again.
You can override the
-setEditing:animatedmethod and do any necessary setup in there.