mainAxisCellCount method

double mainAxisCellCount(
  1. int galleryLength,
  2. int index
)

Implementation

double mainAxisCellCount(int galleryLength, int index) {
  if (galleryLength == 1) {
    return 4;
  } else if (galleryLength != 2) {
    if (index == 0) return 3;
  }
  return 2;
}