createPageController static method

PageController createPageController({
  1. bool reverse = false,
  2. int index = 0,
  3. int itemCount = 0,
  4. bool loop = false,
  5. double viewportFraction = 0,
})

Implementation

static PageController createPageController(
    {bool reverse = false,
    int index = 0,
    int itemCount = 0,
    bool loop = false,
    double viewportFraction = 0}) {
  return PageController(
      initialPage: getRealIndexFromRenderIndex(
          reverse: reverse, index: index, itemCount: itemCount, loop: loop),
      viewportFraction: viewportFraction);
}