pickFiles method
- String? dialogTitle,
- String? initialDirectory,
- FileType type = FileType.any,
- List<
String> ? allowedExtensions, - dynamic onFileLoading()?,
- int compressionQuality = 0,
- AndroidOptions androidOptions = const AndroidOptions(),
- WindowsOptions windowsOptions = const WindowsOptions(),
- LinuxOptions linuxOptions = const LinuxOptions(),
- WebOptions webOptions = const WebOptions(),
Pick multiple files using the native file picker.
The dialogTitle, if provided, will be used as the title for the picker dialog.
The initialDirectory, if provided, will be used as the initial directory path for the picker.
The type parameter specifies the type of files to be picked and defaults to FileType.any.
The allowedExtensions parameter, if provided, restricts selection to specified file extensions
when type is set to FileType.custom.
The onFileLoading callback, if provided, is triggered when the picker changes status.
The compressionQuality parameter specifies image/video compression quality (0-100) on supported platforms.
The androidOptions, windowsOptions, linuxOptions, and webOptions parameters
allow platform-specific configurations for the file picker.
Returns a list of PlatformFile objects containing the selected files, or an empty list if the user canceled the operation.
Implementation
Future<List<PlatformFile>> pickFiles({
String? dialogTitle,
String? initialDirectory,
FileType type = FileType.any,
List<String>? allowedExtensions,
Function(FilePickerStatus)? onFileLoading,
int compressionQuality = 0,
AndroidOptions androidOptions = const AndroidOptions(),
WindowsOptions windowsOptions = const WindowsOptions(),
LinuxOptions linuxOptions = const LinuxOptions(),
WebOptions webOptions = const WebOptions(),
}) {
throw UnimplementedError('pickFiles() has not been implemented.');
}