updateProgress method

Future<void> updateProgress({
  1. required int completed,
  2. required int total,
})

Updates the progress and saves it to platform storage.

completed is the number of completed tasks. total is the total number of tasks.

Implementation

Future<void> updateProgress({
  required int completed,
  required int total,
}) async {
  _currentProgress = TaskProgressIndicator(
    completed: completed,
    total: total,
  );
  await _platform.saveProgress(
    completed: completed,
    total: total,
  );
}