Browse Source

fix video

marinofaggiana 4 years ago
parent
commit
dfb0d16172

+ 3 - 3
Nextcloud.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved

@@ -14,9 +14,9 @@
         "package": "NCCommunication",
         "repositoryURL": "https://github.com/nextcloud/ios-communication-library/",
         "state": {
-          "branch": "develop",
-          "revision": "ef31faa26d440a073c07e4a128247ee0594d8ef6",
-          "version": null
+          "branch": null,
+          "revision": "9a9c1fdaf4cda70dc3502f5fa24d4e9f04949add",
+          "version": "0.82.0"
         }
       },
       {

+ 2 - 1
iOSClient/Viewer/NCViewerImage/NCViewerImage.swift

@@ -677,6 +677,7 @@ extension NCViewerImage: UIGestureRecognizerDelegate {
         
         if currentMetadata.typeFile == k_metadataTypeFile_video || currentMetadata.typeFile == k_metadataTypeFile_audio {
             
+            let currentSeekTime = player?.currentTime()
             videoStop()
             
             if pictureInPictureOcId != currentMetadata.ocId {
@@ -686,7 +687,7 @@ extension NCViewerImage: UIGestureRecognizerDelegate {
 
                 appDelegate.activeViewerVideo = NCViewerVideo()
                 appDelegate.activeViewerVideo?.metadata = currentMetadata
-                appDelegate.activeViewerVideo?.seekTime = player?.currentTime()
+                appDelegate.activeViewerVideo?.seekTime = currentSeekTime
                 appDelegate.activeViewerVideo?.delegateViewerVideo = self
                 if let currentViewerVideo = appDelegate.activeViewerVideo {
                     present(currentViewerVideo, animated: false) { }