DownloadProgressIndicator class

Progress indicator for use with the FileDownloader

Configuration parameters: message message to show for a single download. Templates {filename} and {metadata} are replaced by a task's filename and metadata respectively collapsedMessage message to show when multiple file downloads are collapsed into a single row. The template {n} is replaced by the number of tasks finished, and {total} is replaced by the total number of tasks started in this batch. Both reset to 0 when all downloads finish. In collapsed mode, progress is indicated as {n}/{total} showPauseButton if true, shows a pause button if the task allows it showCancelButton if true, shows a cancel button height height of the DownloadProgressIndicator, and of each row when in expanded mode maxExpandable maximum number of rows the indicator can expand to, with each row showing one download in progress. If set to 1 (the default) the indicator will not expand: if the number of downloads in progress exceeds 1, the indicator will switch to a 'collapsed' state showing the number of files finished out of the total started. It will stay in 'collapsed' state until all downloads have finished. To start the indicator in collapsed state (i.e. never show the download progress of a single file), set maxExpandable to 0 backgroundColor background color for the widget

Inheritance

Constructors

DownloadProgressIndicator(Stream<TaskUpdate> updates, {String message = '{filename}', String collapsedMessage = '{n}/{total}', bool showPauseButton = false, bool showCancelButton = false, double height = 50, int maxExpandable = 1, Color backgroundColor = Colors.grey, Key? key})
const

Properties

backgroundColor Color
final
collapsedMessage String
final
hashCode int
The hash code for this object.
no setterinherited
height double
final
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
maxExpandable int
final
message String
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
showCancelButton bool
final
showPauseButton bool
final
updates Stream<TaskUpdate>
final

Methods

createElement() StatefulElement
Creates a StatefulElement to manage this widget's location in the tree.
inherited
createState() State<DownloadProgressIndicator>
Creates the mutable state for this widget at a given location in the tree.
override
debugDescribeChildren() List<DiagnosticsNode>
Returns a list of DiagnosticsNode objects describing this node's children.
inherited
debugFillProperties(DiagnosticPropertiesBuilder properties) → void
Add additional properties associated with the node.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toDiagnosticsNode({String? name, DiagnosticsTreeStyle? style}) DiagnosticsNode
Returns a debug representation of the object that is used by debugging tools and by DiagnosticsNode.toStringDeep.
inherited
toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) String
A string representation of this object.
inherited
toStringDeep({String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug}) String
Returns a string representation of this node and its descendants.
inherited
toStringShallow({String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) String
Returns a one-line detailed description of the object.
inherited
toStringShort() String
A short, textual description of this widget.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited