12345678910111213141516171819202122232425262728293031323334353637 |
- //
- // KMTextHintWindowController.swift
- // PDF Reader Pro
- //
- // Created by kdanmobile on 2023/11/2.
- //
- import Cocoa
- class KMTextHintWindowController: NSWindowController{
-
- @IBOutlet var headerTextField: NSTextField!
-
- @IBOutlet var detailTextfield: NSTextField!
-
- @IBOutlet var actionButton: NSButton!
-
- override func windowDidLoad() {
- super.windowDidLoad()
- self.actionButton.title = NSLocalizedString("OK", comment: "")
- self.headerTextField.stringValue = NSLocalizedString("Cannot add conversion tasks.", comment: "")
- self.detailTextfield.stringValue = NSLocalizedString("The conversion is in progress... Please wait for the conversion to be completed before proceeding.", comment: "")
- }
-
- @IBAction func buttonClicked_Action(_ sender: NSButton) {
- if #available(macOS 10.13, *) {
- self.window?.endSheet(sender.window!)
- } else {
- NSApp.endSheet(self.window!)
- }
- self.window?.orderOut(self)
- }
- func updateTitleString(titleString: String, detailString: String) {
- self.headerTextField.stringValue = titleString
- self.detailTextfield.stringValue = detailString
- }
- }
|