update method

  1. @override
void update(
  1. covariant MultiChildRenderObjectWidget newWidget
)
override

Change the widget used to configure this element.

The framework calls this function when the parent wishes to use a different widget to configure this element. The new widget is guaranteed to have the same runtimeType as the old widget.

This function is called only during the "active" lifecycle state.

Implementation

@override
void update(MultiChildRenderObjectWidget newWidget) {
  super.update(newWidget);
  final MultiChildRenderObjectWidget multiChildRenderObjectWidget = widget as MultiChildRenderObjectWidget;
  assert(widget == newWidget);
  assert(!debugChildrenHaveDuplicateKeys(widget, multiChildRenderObjectWidget.children));
  _children = updateChildren(_children, multiChildRenderObjectWidget.children, forgottenChildren: _forgottenChildren);
  _forgottenChildren.clear();
}