file_picker_fork 4.6.4 file_picker_fork: ^4.6.4 copied to clipboard
A package that allows you to use a native file explorer to pick single or multiple absolute file paths, with extension filtering support.
Modify the file suffix.
Fix podspec error.
Modify the file suffix.
NULL. This prevents a crash observed
on the iOS simulator on Apple Silicon (#1040).
Add conditional compilation of media, audio and document pickers for iOS. This prevents error messages for permissions (NSPhotoLibraryUsageDescription, NSAppleMusicUsageDescription, etc.) when publishing to app store connect, in case you don't need either category. This addresses #783 in a different way.
Get the absolute path of the file you selected. Fix memory leaks.
display:none to the internal input element to fix a display issue in specific scenario's.
Changes the implementation of
getDirectoryPath() on Windows to provide a modern dialog that looks the same as a file picker dialog (#915).
Desktop (Linux, macOS, and Windows)
Adds the additional parameter
initialDirectory to configure the initial directory where the dialog should be opened. This parameter is supported for all three dialogs (pick files, pick directory, and save file). The only exception is that the parameter does not work on Windows for the function
getDirectoryPath(). Please note that this feature has not been implemented for Android and iOS.
Introduces two fixes for the KDE Plasma Linux implementation which uses
kdialog to open the file picker dialogs. Firstly, the selection of multiple files is fixed so that file paths with blanks/spaces are handled correctly. Secondly, file type filters are implemented. Thank you @w1th0utnam3.
Fixes the issue under Windows that the save-file dialog did not open if the specified file name contained an illegal character. Windows prohibits the usage of reserved characters in file names. Now the exception
IllegalCharacterInFileNameException is thrown if the specified file name contains forbidden characters
Adds KDE Plasma's
kdialog arguments, allowing
filepicker to invoke
kdialog for file system manipulation using shell scripts on distributions that use KDE Plasma as their Desktop Environment and don't ship
Adds the parameter
lockParentWindow for Windows desktop. This parameter makes the file picker dialog behave like a modal window. That is, the file picker always stays in front of the Flutter window until it is closed. Thank you @vinicios-cervantes.
Fixes the issue under Windows that the user could not select more than about 256 files (depending on the length of the file paths) because the buffer size for storing the selected file paths was too small. (#918).
Desktop (macOS & Windows)
Fixes the issue under Windows that the user could select all file types even though a file type filter was enabled. This error existed because the user could select the entry
All Files (*.*) in the file type filter dropdown. Also, fixes the bug under macOS that users could select files without file extension even when one of the pre-defined file type filters (audio, image, video, or media) was enabled. (#871).
Fixes the issue of picking filenames that contain a comma followed by a space (#890).
Fixed an issue that was creating a crash when media in PHPickerViewController in iOs was tapped several times very fast, we check that _result is not empty to avoid the crash. No Github issue created.
READ_EXTERNAL_STORAGE permission removal.
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/> permission from the platform implementation Manifest since may not be required for some applications and devs can manually add it to their own application if needed (#864).
Fixes an issue where
onFileLoading would be called while picking directories (#863).
identifier property to the
PlatformFile which references the original file identifier for both iOS & Android (#804).
Fixes the issue that users could not pick
.app files on macOS because FilePicker tried to determine the file size of
.app files. On macOS, these special kind of files are actually Unix directories in a special format (read more on StackExchange). Now, if a file is picked, which is actually a directory, then the file size will be zero. (#856)
- Fixes an issue that would prevent the call to return when both
allowMultiplewere set. (#843).
- Addresses an issue in the example app.
Addresses an issue where multiple media files couldn't be picked in some 3rd party explorers (#846). Thank you @innim98.
Fixes an issue where Live Photos were being picked as
.pvt packages (since iOS 15). From now on, if
allowCompression is set to
true, Live Photos will automatically be converted to static JPEG pictures. (#835)
Fixes the issue that on Linux the file type filter
FileType.any did not allow the selection of files without file extension. (#836)
Extends API by new function
saveFiles() for opening a save-file dialog as requested in #799. This feature is only supported on desktop platforms (Linux, macOS, and Windows).
Fixes custom extension filter. Thank you @jgoyvaerts.
Overrides equality and toString for
file_picker_result for better comparison different results. Thank you @Nolence.
- Changes the presentation type of the picker from
- Fixes regression of #746.
- Updates exception text when trying to access
pathon Web. Thank you @maxzod.
From now on, you'll be able to use file_picker with all your platforms, a big thanks to @philenius, which made this possible and allowed the flutter_file_picker_desktop to be merged with this one.
Have in mind that because of platforms differences, that the following API methods aren't available to use on Desktop:
onFileLoading()isn't necessary, hence,
FilePickerStatuswon't change, since it hasn't any effect on those;
clearTemporaryFiles()isn't necessary since those files aren't created — the platforms will always use a reference to the original file;
- There is a new optional parameter
dialogTitlewhich can be used to set the title of the modal dialog when picking the files;
onFileLoading() to Web. (#766).
- Addresses an issue where an invalid custom file extension wouldn't throw an error when it should. Thank you @Jahn08.
getDirectoryPath()#745. Thank you @tomm1e.
- Removes analysis_options.yaml from the plugin and fixes the Don't import implementation files from another package warning (#746).
- Addresses an issue where bytes might be missing after first picking when
withDatais set to
- Patches README import path. (Thank you @voynichteru)
sizeproperties are now non-nullable types.
- Updates README;
- Updates API docs;
- Updates Android example app to V2;
- Removes deprecated call warnings;
- Adds analysis_options.yaml with linter rule to surpress warnings from generated_plugin_registrant.
- Use MediaStore Opener (which goes through the gallery) instead of default explorer. (Thank you @tmthecoder).
- Add event when canceling the picker. (Thank you @letranloc).
- Updates example app to null safety.
- Addresses an issue on iOS 14 and later where events
onFileLoadingevents weren't being provided (#577).
- Web: Updates
PlatformFileto be in bytes instead of kb;
- Applies minor refactor to example app. Thank you @Abhishek01039;
iOS & Android: Updates
size property from
PlatformFile to be in bytes instead of kb.
iOS: Fixes iOS ViewController which is nil when UIWindow.rootViewController have changed. (#525). Thank you @devcxm.
withReadStream that allows bigger files to be streamed read into a
Stream<List<int>>. Thanks @redsolver.
extension helper getter to use the
name property instead of
path, since the latest isn't available on the Web, hence, the extension wouldn't be as well. Thank you @markgrancapal.
FileType.audio exports to support ipod-library content (non DRM protected). From now on, a cached asset (m4a) will be exported from the selected music file in the Music app, so it can later be used. Fixes (#441).
Minor fix on CHANGELOG regarding version
- iOS: Updates media picker to launch in app context (instead of modal).
- Minor update to README file.
Fixes an issue on iOS 14, where canceling with swipe gestures, could result in cancel event not being dispatched. (#431).
Fixes #425 and updates iOS to use NSDocumentDirectory on iOS 12 or lower. Thanks @allanwolski.
iOS: Fixes iOS 14 media picker (image & video) (#405, #407).
Desktop (Go): Fixes directory pick on Linux.
Android: Fixes out of memory issue on some devices when picking big files.
Fixes multi-pick example on README.
iOS: Fixes conditional import for backwards compatibility with Xcode 11.
Web: Adds mobile Safari support and other minor improvements. iOS: Adds conditional import for backwards compatibility with Xcode 11.
iOS: Addresses an issue that could prevent users from viewing picked media elements (pictures/videos) from gallery on iOS 14.
Fixes README screenshots.
iOS: Updates picker to use new PHPickerController for both single and multi media (image/video) picks (iOS 14 and above only).
- Unifies all platforms (IO, Web and Desktop) in a single plugin (file_picker) that can be used seamlessly across all. Both file_picker_interface and file_picker_web are no longer mantained from now on.
- You'll now have to use
FilePicker.platform.pickFiles()and extract the files from
- Because platforms are unified and mixing
Fileinstances from dart:io and dart:html required stubbing and bloated code, it's no longer available as helper method so you'll have to instanciate a
Filewith the picked paths;
- Simplified usage, now you only need to use
FilePicker.platform.pickFiles()with desired parameters which will return a
List<PlatformFile>containing the picked data;
- Added classes
PlatformFileclasses with helper getters;
- On Android all picked files are scoped cached which should result in most of files being available. Caching process is only made once, so once done, the picked instance should be the same;
- On iOS picking audio now supports multiple and cloud picks;
- Added parameter
withDatathat allows file data to be immediately available on memory as
PlatformFileinstance). This is particularly helpful on web or if you are going to upload to somehwere else;
- Major refactor with some clean-up and improvements;
- Single methods such as
getMultiFile()are no longer availble in favor o
Go: Updates MacOS directory picker to applescript (thank you @trister1997).
Android: fixes picking paths from Downloads directory on versions below Android Q.
Android: adds support to non-legacy picking on Android Q or above (thank you @lakshyab1995).
Fixes an issue that could prevent
1.13.0 from being built due to missing
allowCompression property that will define if media (video & image) files are allowed to be compressed by OS when picked. On Android this has no effect as it already returns the original file or an integral copy.
getDirectoryPath() desktop (go) implementation.
Updates tearDown() call order on Android's implementation.
Updates README file (iOS preview).
Updates README file.
onFileLoading handler for every picking method that will provide picking status:
FilePickerStatus.done so you can, for example, display a custom loader.
getDirectoryPath() method that allows you to select and pick directory paths. Android, requires SDK 21 or above for this to work, and iOS requires iOS 11 or above.
Adds a temporary workaround on Android where it can trigger
onRequestPermissionsResult twice, related to Flutter issue 49365 for anyone affected in Flutter versions below 1.14.6.
clearTemporaryFiles() that allows you to explicitly remove cached files — on Android applies typically to those picked from remote providers, on iOS all picked files are cached.
Updates podspec to use only PhotoGallery from DKImagePickerController (thanks @jamesdixon!)
Minor fix on
getFile() method — should affect only those on 1.8.0.
FileType.media that will allow you to pick video and images at the same time. On iOS, this will let you pick directly from Photos app (gallery), if you want to use Files app, you must use
FileType.custom with desired extensions.
Updates iOS multi gallery picker dependency and adds a modal loading while fetching exporting assets.
Added support for multi-picks of videos and photos from Photos app on iOS through DKImagePicker — use any of the
getMulti methods with
FileType.video. From now on, you'll need to add
use_frameworks! in your ios/Podfile.
- Fixes a crash on Android when a file has an id that can't be resolved and uses a name instead (#221);
- Minor fix on Go (Desktop) - Windows (thanks @marchellodev);
Addresses an issue with plugin calls on Go (Desktop) - Linux & Windows
Addresses an issue with plugin calls on Go (Desktop) - MacOS
Updates Go (Desktop) to support multiple extension filters.
Addresses an issue that could result in permission handler resolving requests from other activities.
- Adds multiple file extension filter support. From now on, you must provide a
Listof extensions with type
FileType.customwhen restricting types while picking.
- Other minor improvements;
- iOS: Fixes an issue that could result in a crash when selecting files (with repeated taps) from 3rd party remote providers (Google Drive, Dropbox etc.);
- Go: Updates channel name;
- Adds check that ensures that you one uses
FileType.customwhen providing a custom file extension filter;
Updates channel name on iOS.
Adds temporary workaround for (#49365)(https://github.com/flutter/flutter/issues/49365) until 1.14.6 lands on stable channel.
- Breaking change: Refactored
FileTypeto match lower camelCase Dart guideline (eg.
- Added support for new Android plugins APIs (Android V2 embedding);
Removes checked flutter_export_environment.sh from example app.
- Fixes an issue that could result in a crash when tapping multiple times in the same media file while picking, on some iOS devices (#171).
Updates go-flutter dependencies.
- Fixes an issue that could cause a crash when picking video files in iOS 13 or above due to SDK changes.
- Updates Go-Flutter with go 1.13.
Bug fix: Fixes an issue that could result in some cached files, picked from Google Photos (remote file), to have the name set as
Bug fix: Fixes an issue that could prevent internal storage files from being properly picked.
- Adds Desktop support throught go-flutter, you can see detailed instructions on how to get in runing here.
- Adds Desktop example, to run it just do
hover initand then
hover runwithin the plugin's example folder (you must have go and hover installed, check the previous point).
- Similar to
getFile, now there is also a
getMultiFilewhich behaves the same way, but returning a list of files instead.
- Updates Android SDK deprecated code.
- Sometimes when a big file was being picked from a remote directory (GDrive for example), the UI could be blocked. Now this shouldn't happen anymore.
Bug fix: Fixes an issue that could cause a crash when picking files with very long names.
Changes: Updates Android target API to 29.
Rollback - Breaking change: Re-adds runtime verification for external storage read permission. Don't forget to add the permission to the
AndroidManifest.xml file as well. More info in the README file.
Bug fix: Fixes a crash that could cause some Android API to crash when multiple files were selected from external storage.
- Removes the Android write permissions requirement.
- Minor improvements in the example app.
- Now the exceptions are rethrown in case the user wants to handle them, despite that already being done in the plugin call.
Bug fix: Fixes an issue that could prevent users to pick files from the iCloud Drive app, on versions below iOS 11.
Rollback: Removes a local dependency that shouldn't have been committed with
1.3.4 which would cause Android build to fail.
Bug fix: Protects the
registrar.activity() in the Android side of being accessed when it's
- Fixes an issue where sometimes a single file path was being returned as a
requestCodein Android intents are now restricted to 16 bits.
Bug fix: Returns a
null value in the
getFile() when the picker is canceled.
Bug fix: Fixes an issue on Android, where other activity would try to call
FilePicker's result object when it shouldn't.
FileType.CAMERAis no longer available, if you need it, you can use this package along with image_picker.
- You can now pick multiple files by using the
getMultiFilePath()method which will return a
Map<String,String>with all paths from selected files, where the key matches the file name and the value its path. Optionally, it also supports filtering by file extension, otherwise all files will be selectable. Nevertheless, you should keep using
getFilePath()for single path picking.
- You can now use
FileType.AUDIOto pick audio files. In iOS this will let you select from your music library. Paths from DRM protected files won't be loaded (see README for more details).
getFile()utility method that does the same of
getFilePath()but returns a
Fileobject instead, for the returned path.
Bug fixes and updates
- This package is no longer attached to the image_picker, and because of that, camera permission is also no longer required.
- Fixes an issue where sometimes the InputStream wasn't being properly closed. Also, its exception is now being forward to the plugin caller.
- Fixes an issue where the picker, when canceled, wasn't calling the result callback on the underlying platforms.
Breaking change: Migrate from the deprecated original Android Support Library to AndroidX. This shouldn't result in any functional changes, but it requires any Android apps using this plugin to also migrate if they're using the original support library.
- Updates README file.
FileType.PDFwas removed since now it can be used along with custom file types by using the
FileType.CUSTOMand providing the file extension (e.g. PDF, SVG, ZIP, etc.).
- Now it is possible to provide a custom file extension to filter file picking options by using
Bug fixes and updates
- Fixes file names from cloud on Android. Previously it would always display Document
- Fixes an issue on iOS where an exception was being thrown after canceling and re-opening the picker.
- Fixes an issue where collision could happen with request codes on Android.
- Adds public documentation to
- Example app updated.
- Updates .gitignore
- Minor update of README file.
- Adds comments for public API
- Version 1.0 release.
- Adds support for ANY and VIDEO files.
- Fixes an issue where permissions were recursively asked on Android.
- Fixes an issue where some paths from document files couldn't be loaded with Android 8.0.
- Updates README file to match changes.
- General refactor & cleanup.
- Replaces commons dependency with FilePath class on Android, to handle path resolution on different SDK.
- Minor correction in the README file.
- Changed Meta minimum version due to versioning conflict with flutter_localization.
- Updated readme.
- Changed license from Apache 2.0 to MIT.
- Adds demo screenshot.
- Adds license information (Apache 2.0).
- Adds CHANGELOG details.