Signed-off-by: Felix Paul Kühne <fkuehne@videolan.org>
@@ -31,6 +31,8 @@
@property (nonatomic, retain) BoxItem *boxFile;
@property (nonatomic, retain) VLCOneDriveObject *oneDriveFile;
+@property (nonatomic, readwrite) BOOL isDownloadable;
+
+ (VLCCloudStorageTableViewCell *)cellWithReuseIdentifier:(NSString *)ident;
+ (CGFloat)heightOfCell;
@@ -204,4 +204,9 @@
return 48.;
}
+- (void)setIsDownloadable:(BOOL)isDownloadable
+{
+ self.downloadButton.hidden = !isDownloadable;
+}
@end
@@ -107,6 +107,11 @@
cell = [VLCCloudStorageTableViewCell cellWithReuseIdentifier:CellIdentifier];
cell.driveFile = _googleDriveController.currentListFiles[indexPath.row];
+ if ([cell.driveFile.mimeType isEqualToString:@"application/vnd.google-apps.folder"])
+ [cell setIsDownloadable:NO];
+ else
+ [cell setIsDownloadable:YES];
cell.delegate = self;
return cell;