marinofaggiana 4 years ago
parent
commit
a1c5db8607

+ 0 - 0
iOSClient/Images.xcassets/videoFavoriteOn.imageset/Contents.json → iOSClient/Images.xcassets/favoriteSmall.imageset/Contents.json


+ 0 - 0
iOSClient/Images.xcassets/videoFavoriteOn.imageset/videoFavoriteOn.pdf → iOSClient/Images.xcassets/favoriteSmall.imageset/videoFavoriteOn.pdf


+ 0 - 15
iOSClient/Images.xcassets/videoFavoriteOff.imageset/Contents.json

@@ -1,15 +0,0 @@
-{
-  "images" : [
-    {
-      "filename" : "videoFavoriteOff.pdf",
-      "idiom" : "universal"
-    }
-  ],
-  "info" : {
-    "author" : "xcode",
-    "version" : 1
-  },
-  "properties" : {
-    "preserves-vector-representation" : true
-  }
-}

+ 0 - 52
iOSClient/Images.xcassets/videoFavoriteOff.imageset/videoFavoriteOff.pdf

@@ -1,52 +0,0 @@
-%PDF-1.4
-%Óëéá
-1 0 obj
-<</Creator (Mozilla/5.0 \(Macintosh; Intel Mac OS X 10_15_7\) AppleWebKit/537.36 \(KHTML, like Gecko\) BoxySVG/3.42.2 Chrome/83.0.4103.122 Electron/9.1.2 Safari/537.36)
-/Producer (Skia/PDF m83)
-/CreationDate (D:20201104144401+00'00')
-/ModDate (D:20201104144401+00'00')>>
-endobj
-3 0 obj
-<</ca 1
-/BM /Normal>>
-endobj
-4 0 obj
-<</Filter /FlateDecode
-/Length 220>> stream
-xœ]PAn1¼ûœ+•°1¼ çžú€ªIÙHmÿ/v�h7ø`ÃÌ`dñ5 ÆyÅ]ʆÕàk)?%{DŠÑuÿüý.Ÿ/pLCS"ª¼2³ y{8ÿb Žâ5B`)6
h'\‹#sV:� X)ʽN`Å…¸Ø3!¹c‚\±®Üœ©à 'Dì䆆cdçI*ÝHÁN—œ4JDCÝëóºY"õÐÜ3\ËÀÖæ:‚>¶ïÈ-�7ež„á€ÇæœlV{K”‡ù(q)§òçX^¯
-endstream
-endobj
-2 0 obj
-<</Type /Page
-/Resources <</ProcSet [/PDF /Text /ImageB /ImageC /ImageI]
-/ExtGState <</G3 3 0 R>>>>
-/MediaBox [0 0 28.08 28.08]
-/Contents 4 0 R
-/StructParents 0
-/Parent 5 0 R>>
-endobj
-5 0 obj
-<</Type /Pages
-/Count 1
-/Kids [2 0 R]>>
-endobj
-6 0 obj
-<</Type /Catalog
-/Pages 5 0 R>>
-endobj
-xref
-0 7
-0000000000 65535 f 
-0000000015 00000 n 
-0000000628 00000 n 
-0000000301 00000 n 
-0000000338 00000 n 
-0000000820 00000 n 
-0000000875 00000 n 
-trailer
-<</Size 7
-/Root 6 0 R
-/Info 1 0 R>>
-startxref
-922
-%%EOF

+ 5 - 7
iOSClient/Viewer/NCViewerImage/NCViewerImage.storyboard

@@ -1,9 +1,9 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="17156" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES" initialViewController="ne8-hS-cp3">
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="17506" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES" initialViewController="ne8-hS-cp3">
     <device id="retina6_1" orientation="portrait" appearance="light"/>
     <dependencies>
         <deployment identifier="iOS"/>
-        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="17126"/>
+        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="17505"/>
         <capability name="Safe area layout guides" minToolsVersion="9.0"/>
         <capability name="System colors in document resources" minToolsVersion="11.0"/>
         <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
@@ -38,7 +38,6 @@
                                 <items>
                                     <barButtonItem systemItem="play" id="hHF-Q3-tyB"/>
                                     <barButtonItem style="plain" systemItem="flexibleSpace" id="tYH-bL-I0G"/>
-                                    <barButtonItem image="videoFavoriteOn" id="tuw-Qa-JgR"/>
                                     <barButtonItem image="audioOn" id="6mg-K7-nwa"/>
                                 </items>
                             </toolbar>
@@ -187,7 +186,7 @@
                                                     <action selector="touchLocation:" destination="P8R-4f-zAl" eventType="touchUpInside" id="Z9s-pM-WsS"/>
                                                 </connections>
                                             </button>
-                                            <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="dim" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="uYI-ic-d8g">
+                                            <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="lens" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="uYI-ic-d8g">
                                                 <rect key="frame" x="15" y="142" width="80" height="16"/>
                                                 <constraints>
                                                     <constraint firstAttribute="width" constant="80" id="egy-z4-Im6"/>
@@ -196,7 +195,7 @@
                                                 <color key="textColor" white="0.33333333329999998" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
                                                 <nil key="highlightedColor"/>
                                             </label>
-                                            <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="dim value" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="ix8-uQ-chU">
+                                            <label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="lens value" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="ix8-uQ-chU">
                                                 <rect key="frame" x="105" y="142" width="294" height="16"/>
                                                 <constraints>
                                                     <constraint firstAttribute="width" constant="294" id="yyq-S2-dks"/>
@@ -240,12 +239,12 @@
                                             <constraint firstItem="Son-CZ-zFa" firstAttribute="top" secondItem="WXS-Lw-DkI" secondAttribute="bottom" constant="10" id="z9W-ZR-cUN"/>
                                         </constraints>
                                         <connections>
-                                            <outlet property="LensModelValue" destination="ix8-uQ-chU" id="9dR-tZ-OCI"/>
                                             <outlet property="dateLabel" destination="Son-CZ-zFa" id="0Wi-XW-0hw"/>
                                             <outlet property="dateValue" destination="hBd-KD-Jq5" id="ple-nX-OpH"/>
                                             <outlet property="dimLabel" destination="uaE-Lv-t0Q" id="MkZ-ko-UrJ"/>
                                             <outlet property="dimValue" destination="n1C-OB-gq2" id="Ln4-gV-wXg"/>
                                             <outlet property="lensModelLabel" destination="uYI-ic-d8g" id="DUn-uJ-sVj"/>
+                                            <outlet property="lensModelValue" destination="ix8-uQ-chU" id="GNF-8F-10P"/>
                                             <outlet property="locationButton" destination="oov-9f-Oeu" id="cGg-Gb-m5S"/>
                                             <outlet property="mapHeightConstraint" destination="VRv-eR-bwo" id="jXn-vm-aJk"/>
                                             <outlet property="mapView" destination="Typ-A8-XIO" id="XCg-a6-NUq"/>
@@ -302,7 +301,6 @@
     <resources>
         <image name="audioOn" width="28" height="28"/>
         <image name="downloadImageFullRes" width="283" height="283"/>
-        <image name="videoFavoriteOn" width="28" height="28"/>
         <systemColor name="systemBackgroundColor">
             <color white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
         </systemColor>

+ 9 - 4
iOSClient/Viewer/NCViewerImage/NCViewerImage.swift

@@ -97,7 +97,7 @@ class NCViewerImage: UIViewController {
         NotificationCenter.default.addObserver(self, selector: #selector(deleteFile(_:)), name: NSNotification.Name(rawValue: k_notificationCenter_deleteFile), object: nil)
         NotificationCenter.default.addObserver(self, selector: #selector(renameFile(_:)), name: NSNotification.Name(rawValue: k_notificationCenter_renameFile), object: nil)
         NotificationCenter.default.addObserver(self, selector: #selector(moveFile(_:)), name: NSNotification.Name(rawValue: k_notificationCenter_moveFile), object: nil)
-        NotificationCenter.default.addObserver(self, selector: #selector(favoriteFile(_:)), name: NSNotification.Name(rawValue: k_notificationCenter_favoriteFile), object: nil)
+        //NotificationCenter.default.addObserver(self, selector: #selector(favoriteFile(_:)), name: NSNotification.Name(rawValue: k_notificationCenter_favoriteFile), object: nil)
         NotificationCenter.default.addObserver(self, selector: #selector(saveLivePhoto(_:)), name: NSNotification.Name(rawValue: k_notificationCenter_menuSaveLivePhoto), object: nil)
         
         NotificationCenter.default.addObserver(self, selector: #selector(viewUnload), name: NSNotification.Name(rawValue: k_notificationCenter_menuDetailClose), object: nil)
@@ -216,6 +216,7 @@ class NCViewerImage: UIViewController {
         }
     }
     
+    /*
     @objc func favoriteFile(_ notification: NSNotification) {
         if self.view?.window == nil { return }
         
@@ -232,6 +233,7 @@ class NCViewerImage: UIViewController {
             }
         }
     }
+    */
     
     @objc func saveLivePhoto(_ notification: NSNotification) {
         if self.view?.window == nil { return }
@@ -491,26 +493,27 @@ class NCViewerImage: UIViewController {
         
         var itemPlay = toolBar.items![0]
         let itemFlexibleSpace = toolBar.items![1]
-        var itemFavorite = toolBar.items![2]
-        var itemMute = toolBar.items![3]
+        var itemMute = toolBar.items![2]
         
         if player?.rate == 1 {
             itemPlay = UIBarButtonItem(barButtonSystemItem: UIBarButtonItem.SystemItem.pause, target: self, action: #selector(playerPause))
         } else {
             itemPlay = UIBarButtonItem(barButtonSystemItem: UIBarButtonItem.SystemItem.play, target: self, action: #selector(playerPlay))
         }
+        /*
         if currentMetadata.favorite {
             itemFavorite = UIBarButtonItem(image: UIImage(named: "videoFavoriteOn"), style: UIBarButtonItem.Style.plain, target: self, action: #selector(SetFavorite))
         } else {
             itemFavorite = UIBarButtonItem(image: UIImage(named: "videoFavoriteOff"), style: UIBarButtonItem.Style.plain, target: self, action: #selector(SetFavorite))
         }
+        */
         if mute {
             itemMute = UIBarButtonItem(image: UIImage(named: "audioOff"), style: UIBarButtonItem.Style.plain, target: self, action: #selector(SetMute))
         } else {
             itemMute = UIBarButtonItem(image: UIImage(named: "audioOn"), style: UIBarButtonItem.Style.plain, target: self, action: #selector(SetMute))
         }
         
-        toolBar.setItems([itemPlay, itemFlexibleSpace, itemFavorite, itemMute], animated: true)
+        toolBar.setItems([itemPlay, itemFlexibleSpace, itemMute], animated: true)
         toolBar.tintColor = NCBrandColor.sharedInstance.brandElement
         toolBar.barTintColor = view.backgroundColor
     }
@@ -527,9 +530,11 @@ class NCViewerImage: UIViewController {
         player?.isMuted = !mute
         setToolBar()
     }
+    /*
     @objc func SetFavorite() {
         NCNetworking.shared.favoriteMetadata(currentMetadata, urlBase: self.appDelegate.urlBase) { (errorCode, errorDescription) in }
     }
+    */
 }