KMCompareView.swift 731 B

12345678910111213141516171819202122232425262728293031323334353637
  1. //
  2. // KMCompareView.swift
  3. // PDF Master
  4. //
  5. // Created by lizhe on 2023/11/14.
  6. //
  7. import Cocoa
  8. typealias KMCompareViewCancelAction = (_ view: KMCompareView) -> Void
  9. class KMCompareView: KMBaseXibView {
  10. @IBOutlet weak var cancelButton: NSButton!
  11. @IBOutlet weak var doneButton: NSButton!
  12. var cancelAction: KMCompareViewCancelAction?
  13. override func draw(_ dirtyRect: NSRect) {
  14. super.draw(dirtyRect)
  15. // Drawing code here.
  16. }
  17. }
  18. extension KMCompareView {
  19. @IBAction func cancelButtonAction(_ sender: Any) {
  20. guard let callBack = cancelAction else { return }
  21. callBack(self)
  22. }
  23. @IBAction func convertButtonAction(_ sender: Any) {
  24. }
  25. }