install method

  1. @override
void install()
override

Wire the watcher's listening hook (event subscription, override, etc.).

Implementation

@override
void install() {
  if (_installed || _anyInstalled) return;
  _installed = true;
  _anyInstalled = true;

  // 1. Frame magnitude. Purely additive: no previous handler to save, and
  //    nothing to restore beyond removing this one callback.
  SchedulerBinding.instance.addTimingsCallback(_timingsCallback);

  // 2. Per-frame attribution and liveness, both from the post-frame drain.
  _scheduleDrain();
}