Pārlūkot izejas kodu

add ViewerQuickLook

Signed-off-by: Marino Faggiana <marino@marinofaggiana.com>
Marino Faggiana 2 gadi atpakaļ
vecāks
revīzija
c49c751854
1 mainītis faili ar 19 papildinājumiem un 2 dzēšanām
  1. 19 2
      iOSClient/Main/Create cloud/NCUploadAssets.swift

+ 19 - 2
iOSClient/Main/Create cloud/NCUploadAssets.swift

@@ -61,7 +61,7 @@ class NCUploadAssets: NSObject, ObservableObject, NCCreateFormUploadConflictDele
     /*
 
      */
-    let resizeImagePreview: Double = 200
+    let resizeImagePreview: Double = 300
     let sizeImagePreview: Double = 100
     let compressionQuality: CGFloat = 0.5
 
@@ -315,10 +315,27 @@ struct UploadAssetsView: View {
                                                     if item.asset.type == .photo || item.asset.type == .livePhoto {
                                                         presentedQuickLook(size: max(geo.size.height, geo.size.height), index: index)
                                                     }
-                                                }.fullScreenCover(isPresented: $isPresentedQuickLook) {
+                                                }
+                                                .onLongPressGesture {
+
+                                                }
+                                                .fullScreenCover(isPresented: $isPresentedQuickLook) {
                                                     ViewerQuickLook(url: URL(fileURLWithPath: fileNamePath), index: $index, isPresentedQuickLook: $isPresentedQuickLook, uploadAssets: uploadAssets)
                                                         .ignoresSafeArea()
                                                 }
+                                                .contextMenu {
+                                                    Button {
+                                                        // print("Change country setting")
+                                                    } label: {
+                                                        Label("Choose Country", systemImage: "globe")
+                                                    }
+
+                                                    Button {
+                                                        // print("Enable geolocation")
+                                                    } label: {
+                                                        Label("Detect Location", systemImage: "location.circle")
+                                                    }
+                                                }
                                             if item.asset.type == .livePhoto {
                                                 Image(systemName: "livephoto")
                                                     .resizable()