Browse Source

【优化】标记密文移除异步弹窗

lizhe 6 months ago
parent
commit
4a37159d93

+ 4 - 9
PDF Office/PDF Master/Class/PDFTools/Redact/Controller/KMPDFRedactViewController.swift

@@ -167,16 +167,11 @@ class KMPDFRedactViewController: NSViewController {
             return
         }
 
-        DispatchQueue.global().async {
-            let returnCode = KMAlertTool.runModelForMainThread_r(message: "", informative: KMLocalizedString("This will permanently remove the redacted information from this document. Once you save this document, you won’t be able to retrieve the redacted information.", nil), buttons: [KMLocalizedString("Apply", nil), KMLocalizedString("Cancel", nil)])
-            if returnCode == .alertFirstButtonReturn {
-                DispatchQueue.main.async {
-                    self.saveAsPath()
-                }
+        let returnCode = KMAlertTool.runModelForMainThread_r(message: "", informative: KMLocalizedString("This will permanently remove the redacted information from this document. Once you save this document, you won’t be able to retrieve the redacted information.", nil), buttons: [KMLocalizedString("Apply", nil), KMLocalizedString("Cancel", nil)])
+        if returnCode == .alertFirstButtonReturn {
+            DispatchQueue.main.async {
+                self.saveAsPath()
             }
-//        let returnCode = KMAlertTool.runModelForMainThread_r(message: "", informative: KMLocalizedString("This will permanently remove the redacted information from this document. Once you save this document, you won’t be able to retrieve the redacted information.", nil), buttons: [KMLocalizedString("Apply", nil), KMLocalizedString("Cancel", nil)])
-//        if returnCode == .alertFirstButtonReturn {
-//            self.saveAsPath()
         }
      }