KMCompareSaveWindow.swift 803 B

1234567891011121314151617181920212223242526272829303132333435
  1. //
  2. // KMCompareSaveWindow.swift
  3. // PDF Reader Pro
  4. //
  5. // Created by lizhe on 2023/11/22.
  6. //
  7. import Cocoa
  8. class KMCompareSaveWindow: NSWindowController {
  9. @IBOutlet weak var saveView: KMCompareSaveView!
  10. var fileSaveFolderPath: String {
  11. get {
  12. return saveView.fileSaveFolderPath
  13. }
  14. }
  15. var cancelHandle:((_ controller: KMCompareSaveWindow) -> Void)?
  16. var saveHandle:((_ controller: KMCompareSaveWindow, _ saveType: Int) -> Void)?
  17. override func windowDidLoad() {
  18. super.windowDidLoad()
  19. saveView.saveHandle = { [unowned self] view, saveType in
  20. self.saveHandle?(self, saveType)
  21. }
  22. saveView.cancelHandle = { [unowned self] view in
  23. self.cancelHandle?(self)
  24. }
  25. }
  26. }