Dart Documentationchrome.fileBrowserHandlerFileBrowserHandlerSelectFileParams

FileBrowserHandlerSelectFileParams class

class FileBrowserHandlerSelectFileParams extends ChromeObject {
 FileBrowserHandlerSelectFileParams({String suggestedName, List<String> allowedFileExtensions}) {
   if (suggestedName != null) this.suggestedName = suggestedName;
   if (allowedFileExtensions != null) this.allowedFileExtensions = allowedFileExtensions;
 }
 FileBrowserHandlerSelectFileParams.fromProxy(JsObject jsProxy): super.fromProxy(jsProxy);

 /**
  * Suggested name for the file.
  */
 String get suggestedName => jsProxy['suggestedName'];
 set suggestedName(String value) => jsProxy['suggestedName'] = value;

 /**
  * List of file extensions that the selected file can have. The list is also
  * used to specify what files to be shown in the select file dialog. Files
  * with the listed extensions are only shown in the dialog. Extensions should
  * not include the leading '.'. Example: ['jpg', 'png']
  */
 List<String> get allowedFileExtensions => listify(jsProxy['allowedFileExtensions']);
 set allowedFileExtensions(List<String> value) => jsProxy['allowedFileExtensions'] = jsify(value);
}

Extends

ChromeObject > FileBrowserHandlerSelectFileParams

Constructors

new FileBrowserHandlerSelectFileParams({String suggestedName, List<String> allowedFileExtensions}) #

Create a new instance of a ChromeObject, which creates and delegates to a JsObject proxy.

docs inherited from ChromeObject
FileBrowserHandlerSelectFileParams({String suggestedName, List<String> allowedFileExtensions}) {
 if (suggestedName != null) this.suggestedName = suggestedName;
 if (allowedFileExtensions != null) this.allowedFileExtensions = allowedFileExtensions;
}

new FileBrowserHandlerSelectFileParams.fromProxy(JsObject jsProxy) #

Create a new instance of a ChromeObject, which delegates to the given JsObject proxy.

docs inherited from ChromeObject
FileBrowserHandlerSelectFileParams.fromProxy(JsObject jsProxy): super.fromProxy(jsProxy);

Properties

List<String> allowedFileExtensions #

List of file extensions that the selected file can have. The list is also used to specify what files to be shown in the select file dialog. Files with the listed extensions are only shown in the dialog. Extensions should not include the leading '.'. Example: 'jpg', 'png'

List<String> get allowedFileExtensions => listify(jsProxy['allowedFileExtensions']);
set allowedFileExtensions(List<String> value) => jsProxy['allowedFileExtensions'] = jsify(value);

final jsProxy #

inherited from ChromeObject
final dynamic jsProxy

String suggestedName #

Suggested name for the file.

String get suggestedName => jsProxy['suggestedName'];
set suggestedName(String value) => jsProxy['suggestedName'] = value;

Methods

JsObject toJs() #

inherited from ChromeObject
JsObject toJs() => jsProxy;

String toString() #

inherited from ChromeObject

Returns a string representation of this object.

docs inherited from Object
String toString() => jsProxy.toString();