Browse Source

Fix dark mode in CCUploadFromOtherUpp

Signed-off-by: Philippe Weidmann <philippe.weidmann@infomaniak.com>
Philippe Weidmann 5 years ago
parent
commit
c8c37239b8

+ 3 - 0
iOSClient/Images.xcassets/uploadCloud.imageset/Contents.json

@@ -19,5 +19,8 @@
   "info" : {
     "version" : 1,
     "author" : "xcode"
+  },
+  "properties" : {
+    "template-rendering-intent" : "template"
   }
 }

+ 1 - 2
iOSClient/UploadFromOtherUpp/CCUploadFromOtherUpp.m

@@ -57,7 +57,7 @@
 
 - (void)changeTheming
 {
-    [appDelegate changeTheming:self tableView:self.tableView collectionView:nil form:false];
+    [appDelegate changeTheming:self tableView:self.tableView collectionView:nil form:true];
 }
 
 #pragma --------------------------------------------------------------------------------------------
@@ -68,7 +68,6 @@
 {
     if (section == 0) return NSLocalizedString(@"_file_to_upload_", nil);
     else if (section == 2) return NSLocalizedString(@"_destination_", nil);
-    else if (section == 4) return NSLocalizedString(@"_upload_file_", nil);
     
     return @"";
 }

+ 68 - 43
iOSClient/UploadFromOtherUpp/CCUploadFromOtherUpp.storyboard

@@ -1,12 +1,9 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="14113" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES">
-    <device id="retina4_7" orientation="portrait">
-        <adaptation id="fullscreen"/>
-    </device>
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="15705" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES">
+    <device id="retina4_7" orientation="portrait" appearance="light"/>
     <dependencies>
         <deployment identifier="iOS"/>
-        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14088"/>
-        <capability name="Constraints to layout margins" minToolsVersion="6.0"/>
+        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="15706"/>
         <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
     </dependencies>
     <scenes>
@@ -14,28 +11,32 @@
         <scene sceneID="5cw-rg-CWI">
             <objects>
                 <tableViewController id="GWz-Q7-0mE" customClass="CCUploadFromOtherUpp" sceneMemberID="viewController">
-                    <tableView key="view" clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" dataMode="static" style="grouped" separatorStyle="default" rowHeight="44" sectionHeaderHeight="10" sectionFooterHeight="10" id="5dt-Am-942">
+                    <tableView key="view" clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" dataMode="static" style="grouped" separatorStyle="none" rowHeight="44" sectionHeaderHeight="10" sectionFooterHeight="10" id="5dt-Am-942">
                         <rect key="frame" x="0.0" y="0.0" width="375" height="667"/>
                         <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
-                        <color key="backgroundColor" red="0.93725490199999995" green="0.93725490199999995" blue="0.95686274510000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                        <color key="backgroundColor" cocoaTouchSystemColor="groupTableViewBackgroundColor"/>
                         <sections>
                             <tableViewSection id="dXl-sd-Urw">
                                 <cells>
                                     <tableViewCell contentMode="scaleToFill" selectionStyle="default" indentationWidth="10" rowHeight="44" id="6gb-Di-82G">
-                                        <rect key="frame" x="0.0" y="35" width="375" height="44"/>
+                                        <rect key="frame" x="0.0" y="10" width="375" height="44"/>
                                         <autoresizingMask key="autoresizingMask"/>
                                         <tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="6gb-Di-82G" id="JCP-km-emo">
-                                            <rect key="frame" x="0.0" y="0.0" width="375" height="43.5"/>
+                                            <rect key="frame" x="0.0" y="0.0" width="375" height="44"/>
                                             <autoresizingMask key="autoresizingMask"/>
                                             <subviews>
-                                                <label opaque="NO" userInteractionEnabled="NO" tag="100" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" text="nomefile" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="YUf-D3-gNl">
-                                                    <rect key="frame" x="15" y="11" width="577" height="21"/>
-                                                    <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
+                                                <label opaque="NO" userInteractionEnabled="NO" tag="100" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="nomefile" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="YUf-D3-gNl">
+                                                    <rect key="frame" x="16" y="14" width="351" height="16"/>
                                                     <fontDescription key="fontDescription" type="boldSystem" pointSize="13"/>
-                                                    <color key="textColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                                                    <nil key="textColor"/>
                                                     <nil key="highlightedColor"/>
                                                 </label>
                                             </subviews>
+                                            <constraints>
+                                                <constraint firstItem="YUf-D3-gNl" firstAttribute="centerY" secondItem="JCP-km-emo" secondAttribute="centerY" id="NeI-HV-QRi"/>
+                                                <constraint firstAttribute="trailing" secondItem="YUf-D3-gNl" secondAttribute="trailing" constant="8" id="PEb-is-K0b"/>
+                                                <constraint firstItem="YUf-D3-gNl" firstAttribute="leading" secondItem="JCP-km-emo" secondAttribute="leading" constant="16" id="ZrS-0B-kUT"/>
+                                            </constraints>
                                         </tableViewCellContentView>
                                     </tableViewCell>
                                 </cells>
@@ -46,21 +47,20 @@
                             <tableViewSection headerTitle="destinazione" id="1rJ-Io-6Ln">
                                 <cells>
                                     <tableViewCell contentMode="scaleToFill" selectionStyle="default" accessoryType="disclosureIndicator" hidesAccessoryWhenEditing="NO" indentationLevel="1" indentationWidth="0.0" editingAccessoryType="disclosureIndicator" id="vod-Kf-qgz">
-                                        <rect key="frame" x="0.0" y="147" width="375" height="44"/>
+                                        <rect key="frame" x="0.0" y="122" width="375" height="44"/>
                                         <autoresizingMask key="autoresizingMask"/>
                                         <tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="vod-Kf-qgz" id="xv4-l4-pic">
-                                            <rect key="frame" x="0.0" y="0.0" width="341" height="43.5"/>
+                                            <rect key="frame" x="0.0" y="0.0" width="348" height="44"/>
                                             <autoresizingMask key="autoresizingMask"/>
                                             <subviews>
-                                                <label opaque="NO" userInteractionEnabled="NO" tag="101" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" text="Home " lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Dk7-2l-tvL">
-                                                    <rect key="frame" x="67" y="11" width="500" height="21"/>
-                                                    <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
+                                                <label opaque="NO" userInteractionEnabled="NO" tag="101" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Home " lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Dk7-2l-tvL">
+                                                    <rect key="frame" x="64" y="14" width="268" height="16"/>
                                                     <fontDescription key="fontDescription" type="system" pointSize="13"/>
-                                                    <color key="textColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                                                    <nil key="textColor"/>
                                                     <nil key="highlightedColor"/>
                                                 </label>
                                                 <imageView userInteractionEnabled="NO" tag="201" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="folder" translatesAutoresizingMaskIntoConstraints="NO" id="h6z-By-cxY">
-                                                    <rect key="frame" x="16" y="5" width="40" height="40"/>
+                                                    <rect key="frame" x="16" y="2" width="40" height="40"/>
                                                     <constraints>
                                                         <constraint firstAttribute="height" constant="40" id="5Pa-kG-08C"/>
                                                         <constraint firstAttribute="width" constant="40" id="ihD-Ad-LnQ"/>
@@ -69,7 +69,10 @@
                                             </subviews>
                                             <constraints>
                                                 <constraint firstItem="h6z-By-cxY" firstAttribute="leading" secondItem="xv4-l4-pic" secondAttribute="leadingMargin" id="3DU-qa-4EG"/>
-                                                <constraint firstItem="h6z-By-cxY" firstAttribute="top" secondItem="xv4-l4-pic" secondAttribute="topMargin" constant="-6" id="iBk-es-jTL"/>
+                                                <constraint firstItem="Dk7-2l-tvL" firstAttribute="leading" secondItem="h6z-By-cxY" secondAttribute="trailing" constant="8" id="RBu-yE-nP7"/>
+                                                <constraint firstItem="Dk7-2l-tvL" firstAttribute="centerY" secondItem="xv4-l4-pic" secondAttribute="centerY" id="bDC-Nv-mUj"/>
+                                                <constraint firstAttribute="trailingMargin" secondItem="Dk7-2l-tvL" secondAttribute="trailing" constant="8" id="c44-W8-kJw"/>
+                                                <constraint firstItem="h6z-By-cxY" firstAttribute="centerY" secondItem="xv4-l4-pic" secondAttribute="centerY" id="hx4-b6-dQa"/>
                                             </constraints>
                                         </tableViewCellContentView>
                                     </tableViewCell>
@@ -78,35 +81,57 @@
                             <tableViewSection id="uI9-Ue-M9N">
                                 <cells/>
                             </tableViewSection>
-                            <tableViewSection headerTitle="aggiungi file" id="rfo-BS-PT3">
+                            <tableViewSection id="rfo-BS-PT3">
                                 <cells>
-                                    <tableViewCell contentMode="scaleToFill" selectionStyle="default" indentationWidth="10" id="LZK-2t-v0f">
-                                        <rect key="frame" x="0.0" y="259" width="375" height="44"/>
+                                    <tableViewCell contentMode="scaleToFill" selectionStyle="none" indentationWidth="10" rowHeight="62" id="LZK-2t-v0f">
+                                        <rect key="frame" x="0.0" y="206" width="375" height="62"/>
                                         <autoresizingMask key="autoresizingMask"/>
                                         <tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="LZK-2t-v0f" id="hAV-mK-1yo">
-                                            <rect key="frame" x="0.0" y="0.0" width="375" height="43.5"/>
+                                            <rect key="frame" x="0.0" y="0.0" width="375" height="62"/>
                                             <autoresizingMask key="autoresizingMask"/>
                                             <subviews>
-                                                <label opaque="NO" userInteractionEnabled="NO" tag="102" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" text="Aggiungi " lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="uss-79-34j">
-                                                    <rect key="frame" x="67" y="11" width="525" height="21"/>
-                                                    <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
-                                                    <fontDescription key="fontDescription" type="system" pointSize="13"/>
-                                                    <color key="textColor" red="0.50588235290000005" green="0.50588235290000005" blue="0.50588235290000005" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
-                                                    <nil key="highlightedColor"/>
-                                                </label>
-                                                <imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="uploadCloud" translatesAutoresizingMaskIntoConstraints="NO" id="lAw-g4-lYL">
-                                                    <rect key="frame" x="16" y="5" width="40" height="40"/>
+                                                <view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="xRI-9K-ta8">
+                                                    <rect key="frame" x="32" y="0.0" width="311" height="62"/>
+                                                    <subviews>
+                                                        <imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="uploadCloud" translatesAutoresizingMaskIntoConstraints="NO" id="lAw-g4-lYL">
+                                                            <rect key="frame" x="16" y="11" width="40" height="40"/>
+                                                            <color key="tintColor" red="0.40000000000000002" green="0.40000000000000002" blue="0.40000000000000002" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
+                                                            <constraints>
+                                                                <constraint firstAttribute="width" constant="40" id="fzD-wh-6fX"/>
+                                                                <constraint firstAttribute="height" constant="40" id="lcQ-Y6-EhU"/>
+                                                            </constraints>
+                                                        </imageView>
+                                                        <label opaque="NO" userInteractionEnabled="NO" tag="102" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Aggiungi " textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="uss-79-34j">
+                                                            <rect key="frame" x="64" y="22" width="183" height="18"/>
+                                                            <fontDescription key="fontDescription" type="system" weight="semibold" pointSize="15"/>
+                                                            <nil key="highlightedColor"/>
+                                                        </label>
+                                                    </subviews>
+                                                    <color key="backgroundColor" cocoaTouchSystemColor="tableCellGroupedBackgroundColor"/>
                                                     <constraints>
-                                                        <constraint firstAttribute="width" constant="40" id="fzD-wh-6fX"/>
-                                                        <constraint firstAttribute="height" constant="40" id="lcQ-Y6-EhU"/>
+                                                        <constraint firstItem="lAw-g4-lYL" firstAttribute="centerY" secondItem="xRI-9K-ta8" secondAttribute="centerY" id="6NL-vp-9Tn"/>
+                                                        <constraint firstItem="uss-79-34j" firstAttribute="leading" secondItem="lAw-g4-lYL" secondAttribute="trailing" constant="8" id="Rot-ha-PAl"/>
+                                                        <constraint firstItem="uss-79-34j" firstAttribute="centerX" secondItem="xRI-9K-ta8" secondAttribute="centerX" id="XTG-Tz-Br2"/>
+                                                        <constraint firstItem="uss-79-34j" firstAttribute="centerY" secondItem="xRI-9K-ta8" secondAttribute="centerY" id="kmy-DA-g42"/>
+                                                        <constraint firstItem="lAw-g4-lYL" firstAttribute="leading" secondItem="xRI-9K-ta8" secondAttribute="leading" constant="16" id="wBb-V8-3ah"/>
                                                     </constraints>
-                                                </imageView>
+                                                    <userDefinedRuntimeAttributes>
+                                                        <userDefinedRuntimeAttribute type="number" keyPath="layer.CornerRadius">
+                                                            <integer key="value" value="5"/>
+                                                        </userDefinedRuntimeAttribute>
+                                                    </userDefinedRuntimeAttributes>
+                                                </view>
                                             </subviews>
+                                            <color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
                                             <constraints>
-                                                <constraint firstItem="lAw-g4-lYL" firstAttribute="leading" secondItem="hAV-mK-1yo" secondAttribute="leadingMargin" id="AS7-Ot-tE7"/>
-                                                <constraint firstItem="lAw-g4-lYL" firstAttribute="top" secondItem="hAV-mK-1yo" secondAttribute="topMargin" constant="-6" id="Mb7-bP-8p9"/>
+                                                <constraint firstItem="xRI-9K-ta8" firstAttribute="leading" secondItem="hAV-mK-1yo" secondAttribute="leading" constant="32" id="0FZ-3J-P3d"/>
+                                                <constraint firstAttribute="trailing" secondItem="xRI-9K-ta8" secondAttribute="trailing" constant="32" id="1gL-2R-tzI"/>
+                                                <constraint firstAttribute="bottom" secondItem="xRI-9K-ta8" secondAttribute="bottom" id="fOD-cV-c8a"/>
+                                                <constraint firstItem="xRI-9K-ta8" firstAttribute="top" secondItem="hAV-mK-1yo" secondAttribute="top" id="tK9-sF-Cq7"/>
                                             </constraints>
                                         </tableViewCellContentView>
+                                        <color key="backgroundColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
+                                        <inset key="separatorInset" minX="0.0" minY="0.0" maxX="0.0" maxY="0.0"/>
                                     </tableViewCell>
                                 </cells>
                             </tableViewSection>
@@ -126,7 +151,7 @@
                 </tableViewController>
                 <placeholder placeholderIdentifier="IBFirstResponder" id="A9E-rL-ZUe" userLabel="First Responder" sceneMemberID="firstResponder"/>
             </objects>
-            <point key="canvasLocation" x="9683" y="-90"/>
+            <point key="canvasLocation" x="9682.3999999999996" y="-90.404797601199405"/>
         </scene>
         <!--Navigation Controller-->
         <scene sceneID="X9k-hu-nkv">
@@ -134,7 +159,7 @@
                 <navigationController storyboardIdentifier="CCUploadNavigationViewController" automaticallyAdjustsScrollViewInsets="NO" useStoryboardIdentifierAsRestorationIdentifier="YES" id="2nu-YR-W0N" sceneMemberID="viewController">
                     <toolbarItems/>
                     <navigationBar key="navigationBar" contentMode="scaleToFill" id="7WU-Q2-JEB">
-                        <rect key="frame" x="0.0" y="20" width="375" height="44"/>
+                        <rect key="frame" x="0.0" y="0.0" width="375" height="44"/>
                         <autoresizingMask key="autoresizingMask"/>
                     </navigationBar>
                     <nil name="viewControllers"/>
@@ -148,7 +173,7 @@
         </scene>
     </scenes>
     <resources>
-        <image name="folder" width="25" height="25"/>
+        <image name="folder" width="300" height="300"/>
         <image name="uploadCloud" width="25" height="25"/>
     </resources>
 </document>