Skip to content

v3.8.0

Choose a tag to compare

@AlexV525 AlexV525 released this 21 Nov 14:23
· 59 commits to main since this release
72e1b34

What's Changed

Features

  • Add Swift Package Manager support for iOS and macOS.
  • Add cancelToken parameter to AssetEntity.loadFile.
  • Add cancelAllRequest method to PhotoManager.
  • The AssetEntity.getFile and AssetEntity.getOriginBytes methods are public.
  • Add relativePathAsync getter to AssetPathEntity.
  • Add iOS 18 smart album subtypes support:
    • smartAlbumSpatial - For spatial/3D photos
    • smartAlbumProRes - For ProRes videos
    • smartAlbumScreenRecordings - For screen recordings
    • smartAlbumReceipts - For receipts in the Utilities section
    • smartAlbumHandwriting - For handwriting in the Utilities section
    • smartAlbumIllustrations - For illustrations in the Utilities section
    • smartAlbumQRCodes - For QR codes in the Utilities section
  • Add optional latitude, longitude, and creationDate parameters to saveImage, saveImageWithPath, and saveVideo methods.
    • On iOS: Sets location and creation date metadata for saved assets.
    • On Android Q+: Sets DATE_TAKEN field and location metadata for saved assets.
  • Add batch asset move functionality using createWriteRequest API for Android 11+.

Improvements

  • Remove implied FilterOptionGroups when querying paths and assets.
    This fixes assets finding when they were created in the future.
    Some edge cases regarding performance drops caused by the complicated sort queries might also get fixed.
  • Add PermissionState.isLimited.

Fixes

  • Fix type 'Null' is not a subtype of type 'Map<dynamic, dynamic>' error on Android when copying or moving assets fails.
    • Android now properly throws exceptions instead of returning null when copyAssetToGallery or moveAssetToGallery operations fail.
    • Dart side now handles null responses gracefully by throwing a PlatformException.
  • Fix PHImageManager crash on iOS by ensuring all PHImageManager/PHCachingImageManager methods are called on the main thread.
    This resolves race conditions and deadlocks when thumbnail operations are dispatched to QoS background queues.
  • Fix EXC_BAD_ACCESS crash caused by accessing deallocated memory in async blocks on iOS.
    • Fixed PHCachingImageManager methods: fetchThumb, exportAssetToFile, fetchFullSizeImageFile.
    • Fixed PHAssetResourceManager methods: fetchVideoResourceToFile, fetchOriginImageFile.
    • Fixed PHPhotoLibrary save methods: saveImage, saveImageWithPath, saveVideo, saveLivePhoto.
  • Fix AssetEntity.latlngAsync() returning zero location for videos on Android by using MediaMetadataRetriever to extract location data from video files.
  • Fix nullability mismatch for title parameter in saveVideo and saveImageWithPath methods.

New Contributors

Full Changelog: v3.7.1...v3.8.0