Browse Source

【首页】图片转PDF,转换成功后未定位到具体文件

liujiajie 11 months ago
parent
commit
aa5484cff0

+ 1 - 1
PDF Office/PDF Master/Class/Batch/Tools/KMImageToPDFMethod.swift

@@ -194,7 +194,7 @@ class KMImageToPDFMethod: NSObject, KMGOCRManagerDelegate {
                     }
                 } else {
                     DispatchQueue.main.async {
-                        complete(path, self.errorArray as! Array<Any>, self.errorOCRArray as! Array<Any>)
+                        complete(newpath, self.errorArray as! Array<Any>, self.errorOCRArray as! Array<Any>)
                     }
                 }
 //            }

+ 1 - 1
PDF Office/PDF Master/Class/Batch/WindowController/VC/KMBatchOperateCompressViewController.swift

@@ -46,7 +46,7 @@ class KMBatchOperateCompressViewController: KMBatchOperateBaseViewController{
             super.interfaceStatus = newValue
             if newValue == .PrepareProcess {
                 DispatchQueue.main.asyncAfter(deadline: .now() + 0.4) {
-                    var files = NSMutableArray()
+                    let files = NSMutableArray()
                     for url in self.successFilePathURLArray! {
                         if FileManager.default.fileExists(atPath: url.path) {
                             files.add(url)

+ 1 - 1
PDF Office/PDF Master/Class/Batch/WindowController/VC/KMBatchOperateImageToPDFViewController.swift

@@ -41,7 +41,7 @@ class KMBatchOperateImageToPDFViewController: KMBatchOperateBaseViewController,
             super.interfaceStatus = newValue
             if newValue == .PrepareProcess {
                 DispatchQueue.main.asyncAfter(deadline: .now() + 0.4) {
-                    var files = NSMutableArray()
+                    let files = NSMutableArray()
                     for url in self.successFilePathURLArray! {
                         if FileManager.default.fileExists(atPath: url.path) {
                             files.add(url)