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.dir
helper. 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
DocumentThumbnail
fromContent Uri
orFile.path
. Same asDocumentFile.thumbnail()
method, but now you can getDocumentThumbnail
directly./// 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
DocumentFile
instantiation fromContent Uri
orFile.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
DocumentFile
action
methods, when working with different documents. Now it's fixed.DocManQueueManager
was primarily used for allactivity
methods, 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()
. Stringtitle
parameter was not optional, but it should be. Now it's fixed.Please check your code and change
title
parameter 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
PermissionsException
class - Example: updated deprecated
withOpacity
towithAlpha
- Documentation fixes
1.0.1 #
- Readme fixes
- Screenshot
- Workflow fixes
1.0.0 #
- DocMan initial release