PhotoViewGallery.builder constructor
const
PhotoViewGallery.builder({
- Key? key,
- required int? itemCount,
- required PhotoViewGalleryBuilder? builder,
- LoadingBuilder? loadingBuilder,
- BoxDecoration? backgroundDecoration,
- bool gaplessPlayback = false,
- bool reverse = false,
- PageController? pageController,
- PhotoViewGalleryPageChangedCallback? onPageChanged,
- ValueChanged<
PhotoViewScaleState> ? scaleStateChangedCallback, - bool enableRotation = false,
- ScrollPhysics? scrollPhysics,
- Axis scrollDirection = Axis.horizontal,
- Size? customSize,
- bool allowImplicitScrolling = false,
Construct a gallery with dynamic items.
The builder must return a PhotoViewGalleryPageOptions.
Implementation
const PhotoViewGallery.builder({
Key? key,
required this.itemCount,
required this.builder,
this.loadingBuilder,
this.backgroundDecoration,
this.gaplessPlayback = false,
this.reverse = false,
this.pageController,
this.onPageChanged,
this.scaleStateChangedCallback,
this.enableRotation = false,
this.scrollPhysics,
this.scrollDirection = Axis.horizontal,
this.customSize,
this.allowImplicitScrolling = false,
}) : pageOptions = null,
assert(itemCount != null),
assert(builder != null),
super(key: key);