update method

void update({
  1. double? percent,
  2. String? message,
})

Updates the percent (clamped between 0 and 100) and/or the message shown above the progress bar. Call this from inside the action as many times as needed to reflect the real progress (e.g. bytes downloaded).

Implementation

void update({double? percent, String? message}) {
  if (percent != null) _percent = percent.clamp(0, 100);
  if (message != null) _message = message;
}