stop method

void stop()

Stops listening; a scheduled suspend is dropped.

Implementation

void stop() {
  if (!_started) return;
  _started = false;
  _pending?.cancel();
  _pending = null;
  WidgetsBinding.instance.removeObserver(this);
}