didChangeDependencies method

void didChangeDependencies()

Called when a dependency of this element changes.

The dependOnInheritedComponentOfExactType registers this element as depending on inherited information of the given type. When the information of that type changes at this location in the tree (e.g., because the InheritedElement updated to a new InheritedComponent and InheritedComponent.updateShouldNotify returned true), the framework calls this function to notify this element of the change.

Implementation

void didChangeDependencies() {
  assert(_lifecycleState == _ElementLifecycle.active);
  assert(_debugCheckOwnerBuildTargetExists('didChangeDependencies'));
  markNeedsBuild();
}