|
@@ -180,12 +180,12 @@ class KMConvertPDFManager: NSObject {
|
|
|
convertString.append("if not isRun then quit\n")
|
|
|
convertString.append("end tell\n")
|
|
|
|
|
|
-// let dic: AutoreleasingUnsafeMutablePointer<NSDictionary?>? = nil
|
|
|
-// let docScript = NSAppleScript(source: convertString)
|
|
|
-// docScript?.executeAndReturnError(dic)
|
|
|
- let dic = KMOCTool.convertOfficeFile(toPdf: convertString)
|
|
|
+ var dic: NSDictionary?
|
|
|
+ let docScript = NSAppleScript(source: convertString)
|
|
|
+ docScript?.executeAndReturnError(&dic)
|
|
|
+// let dic = KMOCTool.convertOfficeFile(toPdf: convertString)
|
|
|
DispatchQueue.main.async {
|
|
|
- completionHandler(true, dic as NSDictionary)
|
|
|
+ completionHandler(true, dic)
|
|
|
}
|
|
|
}
|
|
|
}
|