pause method

void pause()

Pauses an active timer.

The elapsed time is not accounted anymore and the timer will not be fired until it is started again.

Nothing happens if the timer isPaused, isExpired or isCancelled.

Implementation

void pause() {
  _stopwatch?.stop();
  _timer?.cancel();
  _timer = null;
}