jumpTo method

  1. @override
void jumpTo({
  1. required int index,
  2. double alignment = 0,
  3. bool automaticAlignment = true,
})

Jumps to the element at index. The element will be placed under the group header. To set a custom alignment set automaticAlignment to false.

See ItemScrollController.jumpTo

Implementation

@override
void jumpTo({
  required int index,
  double alignment = 0,
  bool automaticAlignment = true,
}) {
  if (automaticAlignment) {
    alignment = _stickyGroupedListViewState!.headerDimension ?? alignment;
  }
  return super.jumpTo(index: index * 2 + 1, alignment: alignment);
}