insertAllItems method
inherited
Insert multiple items at index
and start an animation that will be passed
to AnimatedGrid.itemBuilder
or AnimatedList.itemBuilder
when the items
are visible.
If using AnimatedList.separated the animation will also be passed to separatorBuilder
.
Implementation
void insertAllItems(int index, int length, { Duration duration = _kDuration, bool isAsync = false }) {
if (widget.removedSeparatorBuilder == null) {
_sliverAnimatedMultiBoxKey.currentState!.insertAllItems(index, length, duration: duration);
} else {
final int itemIndex = _computeItemIndex(index);
final int lengthWithSeparators = _itemsCount == 0 ? length * 2 - 1 : length * 2;
_sliverAnimatedMultiBoxKey.currentState!.insertAllItems(itemIndex, lengthWithSeparators, duration: duration);
}
}