removeListener method Null safety

void removeListener(
  1. VoidCallback listener
)

Stop calling the listener every time the value of the animation changes.

Listeners can be added with addListener.

Implementation

void removeListener(VoidCallback listener) {
  final bool removed = _listeners.remove(listener);
  if (removed) {
    didUnregisterListener();
  }
}