diff --git a/lib/generated/intl/messages_es.dart b/lib/generated/intl/messages_es.dart index 4f3c7fd06..c15ca1700 100644 --- a/lib/generated/intl/messages_es.dart +++ b/lib/generated/intl/messages_es.dart @@ -427,6 +427,8 @@ class MessageLookup extends MessageLookupByLibrary { "customRadius": MessageLookupByLibrary.simpleMessage("Radio personalizado"), "darkTheme": MessageLookupByLibrary.simpleMessage("Oscuro"), + "dayToday": MessageLookupByLibrary.simpleMessage("Hoy"), + "dayYesterday": MessageLookupByLibrary.simpleMessage("Ayer"), "decrypting": MessageLookupByLibrary.simpleMessage("Descifrando..."), "decryptingVideo": MessageLookupByLibrary.simpleMessage("Descifrando video..."), diff --git a/lib/ui/viewer/file/zoomable_live_image.dart b/lib/ui/viewer/file/zoomable_live_image.dart index cb2ebd060..9ae072f9f 100644 --- a/lib/ui/viewer/file/zoomable_live_image.dart +++ b/lib/ui/viewer/file/zoomable_live_image.dart @@ -125,7 +125,7 @@ class _ZoomableLiveImageState extends State return; } _isLoadingVideoPlayer = true; - io.File? videoFile = _file.fileType == FileType.livePhoto + final io.File? videoFile = _file.fileType == FileType.livePhoto ? await _getLivePhotoVideo() : await _getMotionPhotoVideo(); @@ -178,7 +178,7 @@ class _ZoomableLiveImageState extends State }); if (imageFile != null) { final motionPhoto = MotionPhotos(imageFile.path); - final index = motionPhoto.getMotionVideoIndex(); + final index = await motionPhoto.getMotionVideoIndex(); if (index != null) { if (widget.file.pubMagicMetadata?.mvi == null && (widget.file.ownerID ?? 0) == Configuration.instance.getUserID()!) { diff --git a/lib/utils/file_uploader_util.dart b/lib/utils/file_uploader_util.dart index 3f0e71644..fcda90210 100644 --- a/lib/utils/file_uploader_util.dart +++ b/lib/utils/file_uploader_util.dart @@ -163,7 +163,7 @@ Future _getMediaUploadDataFromAssetFile(ente.File file) async { if (io.Platform.isAndroid && asset.type == AssetType.image) { try { motionPhotoStartingIndex = - MotionPhotos(sourceFile.path).getMotionVideoIndex()?.start; + (await MotionPhotos(sourceFile.path).getMotionVideoIndex())?.start; } catch (e) { _logger.severe('error while detecthing motion photo start index', e); } diff --git a/pubspec.lock b/pubspec.lock index efc2b2495..f1d87e341 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -1186,7 +1186,7 @@ packages: description: path: "." ref: HEAD - resolved-ref: ceeaff6e16bd9e3c98e7da2b1109dc04a93098b9 + resolved-ref: "989ea86e513755d9a8cf945e7522100fc2877639" url: "https://github.com/ente-io/motion_photo.git" source: git version: "0.0.1"