docman 1.2.0
docman: ^1.2.0 copied to clipboard
Flutter File & Directory Plugin. Easy Android file operations with Storage Access Framework (SAF) API integration.
1.2.0 #
-
New Feature: Added method
all()forDocMan.dirhelper. It's a simple way to get all app directories in one call as map./// Get all app directories as map with keys as directory names and values as paths. final Map<String, String> dirs = await DocMan.dir.all(); ///Result example: { "cache": "/data/user/0/com.example.app/cache", "files": "/data/user/0/com.example.app/files", "data": "/data/user/0/com.example.app/app_flutter", // External directories, can be empty strings if not available. "cacheExt": "/storage/emulated/0/Android/data/com.example.app/cache", "filesExt": "/storage/emulated/0/Android/data/com.example.app/files", } -
Feature: Added ability to instantiate
DocumentThumbnailfromContent UriorFile.path. Same asDocumentFile.thumbnail()method, but now you can getDocumentThumbnaildirectly./// Create thumbnail from content uri or file path. final DocumentThumbnail thumbnail = await DocumentThumbnail.fromUri( contentUriOrFilePath, width: 100, height: 100, png: true, ); -
Feature: Added syntax sugar for
DocumentFileinstantiation fromContent UriorFile.path./// New syntax sugar for DocumentFile instantiation from content uri or file path. final DocumentFile? doc = await DocumentFile.fromUri(contentUriOrFilePath); /// Old way. final DocumentFile? doc = await DocumentFile(contentUriOrFilePath).get(); -
Fix: problem with parallel calls to
DocumentFileactionmethods, when working with different documents. Now it's fixed.DocManQueueManagerwas primarily used for allactivitymethods, and it caused the problem. For example, now it's possible to create list or grid of documents thumbnails without any problems. If you were getting errors in log likeError loading thumbnail: AlreadyRunning Method: documentfileaction, it should be fixed now. -
Fix: error in syntax in methods
DocumentFile.share()&DocumentFile.open(). Stringtitleparameter was not optional, but it should be. Now it's fixed.Please check your code and change
titleparameter to optional if you are using these methods.From:
final bool share = await doc.share('Share this document:'); final bool open = await doc.open('Open with:');To:
final bool share = await doc.share(title: 'Share this document:'); final bool open = await doc.open(title: 'Open with:'); -
Chore: Updated dependencies, updated example, updated README, some code cleanup & small fixes.
1.1.0 #
- New Feature: Implemented simple custom
DocumentsProvider - Small fixes
- Updated README
- Updated example
- Updated dependencies
1.0.2 #
- Fix: missed export of
PermissionsExceptionclass - Example: updated deprecated
withOpacitytowithAlpha - Documentation fixes
1.0.1 #
- Readme fixes
- Screenshot
- Workflow fixes
1.0.0 #
- DocMan initial release
