Marino Faggiana 6 years ago
parent
commit
e330fa42ab

+ 0 - 1
iOSClient/Main/CCCellMain.h

@@ -36,7 +36,6 @@
 @property(nonatomic, weak) IBOutlet UILabel *labelTitle;
 @property(nonatomic, weak) IBOutlet UILabel *labelInfoFile;
 
-@property(nonatomic, weak) IBOutlet UIProgressView *progressView;
 @property(nonatomic, weak) IBOutlet UIButton *cancelTaskButton;
 
 @property(nonatomic, strong) UIImage *imageTitleSegue;

+ 0 - 1
iOSClient/Main/CCCellMainTransfer.h

@@ -36,7 +36,6 @@
 @property(nonatomic, weak) IBOutlet UILabel *labelTitle;
 @property(nonatomic, weak) IBOutlet UILabel *labelInfoFile;
 
-@property(nonatomic, weak) IBOutlet UIProgressView *progressView;
 @property(nonatomic, weak) IBOutlet UIButton *cancelTaskButton;
 
 @property(nonatomic, strong) UIImage *imageTitleSegue;

+ 2 - 14
iOSClient/Main/CCCellMainTransfer.xib

@@ -44,11 +44,6 @@
                             <constraint firstAttribute="width" constant="15" id="g4P-aH-jOh"/>
                         </constraints>
                     </imageView>
-                    <progressView opaque="NO" tag="40" contentMode="scaleToFill" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="Q4M-4B-abs">
-                        <rect key="frame" x="65" y="52" width="474" height="2"/>
-                        <color key="tintColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
-                        <color key="trackTintColor" white="0.0" alpha="0.0" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
-                    </progressView>
                     <button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="Kaz-0H-BSt" userLabel="Cancel Task Button">
                         <rect key="frame" x="547" y="5" width="50" height="50"/>
                         <constraints>
@@ -65,30 +60,23 @@
                     <constraint firstItem="QNC-8X-DAC" firstAttribute="leading" secondItem="5" secondAttribute="trailing" constant="10" id="0Oa-uE-QbX"/>
                     <constraint firstItem="5" firstAttribute="leading" secondItem="sQq-jC-UEV" secondAttribute="leading" constant="15" id="1B0-QJ-6w2"/>
                     <constraint firstAttribute="trailing" secondItem="5" secondAttribute="trailing" constant="545" id="1gX-zZ-TEK"/>
+                    <constraint firstItem="p7I-KN-FVZ" firstAttribute="leading" secondItem="5" secondAttribute="trailing" constant="10" id="4Xt-42-ra7"/>
                     <constraint firstItem="5" firstAttribute="leading" secondItem="DQR-yN-JaH" secondAttribute="trailing" constant="-10" id="6Op-l4-GTN"/>
                     <constraint firstItem="Kaz-0H-BSt" firstAttribute="leading" secondItem="p7I-KN-FVZ" secondAttribute="trailing" constant="8" id="BxA-Mn-Hrb"/>
                     <constraint firstItem="DQR-yN-JaH" firstAttribute="top" secondItem="5" secondAttribute="bottom" constant="-10" id="CGn-pQ-QmD"/>
-                    <constraint firstItem="Q4M-4B-abs" firstAttribute="leading" secondItem="p7I-KN-FVZ" secondAttribute="leading" id="MgY-Ht-CES"/>
-                    <constraint firstItem="Q4M-4B-abs" firstAttribute="top" secondItem="p7I-KN-FVZ" secondAttribute="bottom" constant="6" id="MvY-lo-siU"/>
                     <constraint firstItem="5" firstAttribute="centerY" secondItem="sQq-jC-UEV" secondAttribute="centerY" id="asW-ir-Cfb"/>
                     <constraint firstItem="Kaz-0H-BSt" firstAttribute="centerY" secondItem="sQq-jC-UEV" secondAttribute="centerY" id="cB6-gr-b5f"/>
                     <constraint firstItem="QNC-8X-DAC" firstAttribute="top" secondItem="sQq-jC-UEV" secondAttribute="top" constant="13" id="d78-LV-sUw"/>
                     <constraint firstItem="Kaz-0H-BSt" firstAttribute="leading" secondItem="QNC-8X-DAC" secondAttribute="trailing" constant="8" id="dPR-O3-hfC"/>
-                    <constraint firstItem="Q4M-4B-abs" firstAttribute="trailing" secondItem="p7I-KN-FVZ" secondAttribute="trailing" id="dbN-pC-qTS"/>
-                    <constraint firstItem="Q4M-4B-abs" firstAttribute="leading" secondItem="QNC-8X-DAC" secondAttribute="leading" id="n4M-Ua-KyP"/>
-                    <constraint firstItem="Q4M-4B-abs" firstAttribute="trailing" secondItem="QNC-8X-DAC" secondAttribute="trailing" id="nN0-sV-pWO"/>
+                    <constraint firstAttribute="bottom" secondItem="p7I-KN-FVZ" secondAttribute="bottom" constant="13.5" id="ofO-Ef-6wt"/>
                     <constraint firstAttribute="trailing" secondItem="Kaz-0H-BSt" secondAttribute="trailing" constant="3" id="pZl-oE-hE9"/>
                 </constraints>
             </tableViewCellContentView>
-            <constraints>
-                <constraint firstAttribute="bottom" secondItem="Q4M-4B-abs" secondAttribute="bottom" constant="6" id="AzC-rK-ZMp"/>
-            </constraints>
             <connections>
                 <outlet property="cancelTaskButton" destination="Kaz-0H-BSt" id="W4F-Ub-Sjv"/>
                 <outlet property="file" destination="5" id="h6v-aL-JbR"/>
                 <outlet property="labelInfoFile" destination="p7I-KN-FVZ" id="bIH-yL-aSv"/>
                 <outlet property="labelTitle" destination="QNC-8X-DAC" id="coV-Xj-n1Q"/>
-                <outlet property="progressView" destination="Q4M-4B-abs" id="Ouc-sW-VLX"/>
                 <outlet property="status" destination="DQR-yN-JaH" id="neR-jW-zwL"/>
             </connections>
             <point key="canvasLocation" x="414" y="244"/>

+ 1 - 26
iOSClient/Main/CCMain.m

@@ -2167,11 +2167,7 @@
         
         CCCellMainTransfer *cell = (CCCellMainTransfer *)[self.tableView cellForRowAtIndexPath:indexPath];
         
-        cell.labelInfoFile.text = [NSString stringWithFormat:@"%@ - %@", [CCUtility transformedSize:totalBytesExpected], [CCUtility transformedSize:totalBytes]];
-        
-        cell.progressView.progressTintColor = [UIColor blackColor];
-        cell.progressView.hidden = NO;
-        [cell.progressView setProgress:progress];
+        cell.labelInfoFile.text = [NSString stringWithFormat:@"%@ - %@", [CCUtility transformedSize:totalBytesExpected], [CCUtility transformedSize:totalBytes]];        
     }
 }
 
@@ -4433,9 +4429,6 @@
     cell.labelInfoFile.enabled = YES;
     cell.labelInfoFile.text = @"";
     
-    cell.progressView.progress = 0.0;
-    cell.progressView.hidden = YES;
-    
     cell.cancelTaskButton.hidden = YES;
     
     cell.labelTitle.textColor = [UIColor blackColor];
@@ -4671,15 +4664,6 @@
         cell.cancelTaskButton.hidden = NO;
 
         cell.labelInfoFile.text = [NSString stringWithFormat:@"%@", lunghezzaFile];
-        
-        float progress = [[appDelegate.listProgressMetadata objectForKey:metadata.fileID] floatValue];
-        if (progress > 0) {
-            
-            cell.progressView.progressTintColor = [UIColor blackColor];
-            
-            cell.progressView.progress = progress;
-            cell.progressView.hidden = NO;
-        }
     }
     
     // ----------------------------------------------------------------------------------------------------------
@@ -4714,15 +4698,6 @@
         
         cell.labelTitle.enabled = NO;
         cell.labelInfoFile.text = [NSString stringWithFormat:@"%@", lunghezzaFile];
-        
-        float progress = [[appDelegate.listProgressMetadata objectForKey:metadata.fileID] floatValue];
-        if (progress > 0) {
-            
-            cell.progressView.progressTintColor = [UIColor blackColor];
-            
-            cell.progressView.progress = progress;
-            cell.progressView.hidden = NO;
-        }
     }
     
     // ----------------------------------------------------------------------------------------------------------