add invalidate
This commit is contained in:
parent
dd78ffa41e
commit
23378e2de4
|
|
@ -26,6 +26,8 @@ public protocol CellHeightCalculatable {
|
|||
|
||||
func height(row: Row, path: NSIndexPath) -> CGFloat
|
||||
func estimatedHeight(row: Row, path: NSIndexPath) -> CGFloat
|
||||
|
||||
func invalidate()
|
||||
}
|
||||
|
||||
public class PrototypeHeightStrategy: CellHeightCalculatable {
|
||||
|
|
@ -63,4 +65,8 @@ public class PrototypeHeightStrategy: CellHeightCalculatable {
|
|||
public func estimatedHeight(row: Row, path: NSIndexPath) -> CGFloat {
|
||||
return UITableViewAutomaticDimension
|
||||
}
|
||||
|
||||
public func invalidate() {
|
||||
cachedHeights.removeAll()
|
||||
}
|
||||
}
|
||||
Loading…
Reference in New Issue