marinofaggiana 5 жил өмнө
parent
commit
b3ce34c603

+ 16 - 16
iOSClient/Main/NCDetailViewController.swift

@@ -240,22 +240,6 @@ class NCDetailViewController: UIViewController {
         }
     }
     
-    @objc func downloadFile(_ notification: NSNotification) {
-        if let userInfo = notification.userInfo as NSDictionary? {
-            if let metadata = userInfo["metadata"] as? tableMetadata, let errorCode = userInfo["errorCode"] as? Int {
-                
-                if metadata.account == self.metadata?.account && metadata.serverUrl == self.metadata?.serverUrl {
-                    
-                    if errorCode == 0 && metadata.typeFile == k_metadataTypeFile_image && viewerImageViewController != nil {
-                        viewerImageViewController?.reloadContentViews()
-                    }
-                    
-                    setProgressBar()
-                }
-            }
-        }
-    }
-    
     @objc func moveFile(_ notification: NSNotification) {
         if let userInfo = notification.userInfo as NSDictionary? {
             if let metadata = userInfo["metadata"] as? tableMetadata, let errorCode = userInfo["errorCode"] as? Int {
@@ -318,6 +302,22 @@ class NCDetailViewController: UIViewController {
         }
     }
     
+    @objc func downloadFile(_ notification: NSNotification) {
+        if let userInfo = notification.userInfo as NSDictionary? {
+            if let metadata = userInfo["metadata"] as? tableMetadata, let errorCode = userInfo["errorCode"] as? Int {
+                
+                if metadata.account == self.metadata?.account && metadata.serverUrl == self.metadata?.serverUrl {
+                    
+                    if errorCode == 0 && metadata.typeFile == k_metadataTypeFile_image && viewerImageViewController != nil {
+                        viewerImageViewController?.reloadContentViews()
+                    }
+                    
+                    setProgressBar()
+                }
+            }
+        }
+    }
+    
     @objc func renameFile(_ notification: NSNotification) {
         if let userInfo = notification.userInfo as NSDictionary? {
             if let metadata = userInfo["metadata"] as? tableMetadata, let errorCode = userInfo["errorCode"] as? Int {