Переглянути джерело

fix: not able to play some HEIC motion photos on android

ashilkn 1 рік тому
батько
коміт
9f4e77c038
1 змінених файлів з 1 додано та 4 видалено
  1. 1 4
      lib/utils/file_util.dart

+ 1 - 4
lib/utils/file_util.dart

@@ -174,8 +174,6 @@ Future<File?> getFileFromServer(
   return _fileDownloadsInProgress[downloadID];
   return _fileDownloadsInProgress[downloadID];
 }
 }
 
 
-
-
 Future<bool> isFileCached(EnteFile file, {bool liveVideo = false}) async {
 Future<bool> isFileCached(EnteFile file, {bool liveVideo = false}) async {
   final cacheManager = (file.fileType == FileType.video || liveVideo)
   final cacheManager = (file.fileType == FileType.video || liveVideo)
       ? VideoCacheManager.instance
       ? VideoCacheManager.instance
@@ -301,8 +299,7 @@ Future<File?> _downloadAndCache(
     final decryptedFilePath = decryptedFile.path;
     final decryptedFilePath = decryptedFile.path;
     final String fileExtension = getExtension(file.title ?? '');
     final String fileExtension = getExtension(file.title ?? '');
     File outputFile = decryptedFile;
     File outputFile = decryptedFile;
-    if ((fileExtension == "unknown" && file.fileType == FileType.image) ||
-        (Platform.isAndroid && fileExtension == "heic")) {
+    if ((fileExtension == "unknown" && file.fileType == FileType.image)) {
       final compressResult = await FlutterImageCompress.compressAndGetFile(
       final compressResult = await FlutterImageCompress.compressAndGetFile(
         decryptedFilePath,
         decryptedFilePath,
         decryptedFilePath + ".jpg",
         decryptedFilePath + ".jpg",