//
//  TableView.swift
//  MVMCoreUI
//
//  Created by Scott Pfeil on 4/22/20.
//  Copyright © 2020 Verizon Wireless. All rights reserved.
//

import Foundation

@objcMembers open class TableView: UITableView {
    
    /// A block that gets called on tableview frame changes
    public var frameChangeAction: (() -> ())?
    
    private var previousFrame = CGRect.zero
    
    open override func layoutSubviews() {
        super.layoutSubviews()
        if frame != previousFrame {
            frameChangeAction?()
        }
        previousFrame = frame
    }
}
