AnimatedGridView constructor
const
AnimatedGridView({
- required List<
Widget> children, - required int crossAxisCount,
- Key? key,
- double mainAxisSpacing = 0.0,
- double crossAxisSpacing = 0.0,
- double childAspectRatio = 1.0,
- double? mainAxisExtent,
- double extendedSpaceBetween = 30,
- int duration = 200,
- Axis scrollDirection = Axis.vertical,
- bool reverse = false,
- ScrollController? controller,
- bool primary = false,
- ScrollPhysics? physics,
- bool shrinkWrap = false,
- EdgeInsetsGeometry? padding,
- double? itemExtent,
- bool addAutomaticKeepAlives = true,
- bool addRepaintBoundaries = true,
- bool addSemanticIndexes = true,
- double? cacheExtent,
- Widget? prototypeItem,
- int? semanticChildCount,
- DragStartBehavior dragStartBehavior = DragStartBehavior.start,
- ScrollViewKeyboardDismissBehavior keyboardDismissBehavior = ScrollViewKeyboardDismissBehavior.manual,
- String? restorationId,
- Clip clipBehavior = Clip.hardEdge,
- ScrollBehavior? scrollBehavior,
- Key? center,
- double anchor = 0.0,
Implementation
const AnimatedGridView({
required this.children,
required this.crossAxisCount,
Key? key,
this.mainAxisSpacing = 0.0,
this.crossAxisSpacing = 0.0,
this.childAspectRatio = 1.0,
this.mainAxisExtent,
this.extendedSpaceBetween = 30,
this.duration = 200,
this.scrollDirection = Axis.vertical,
this.reverse = false,
this.controller,
this.primary = false,
this.physics,
this.shrinkWrap = false,
this.padding,
this.itemExtent,
this.addAutomaticKeepAlives = true,
this.addRepaintBoundaries = true,
this.addSemanticIndexes = true,
this.cacheExtent,
this.prototypeItem,
this.semanticChildCount,
this.dragStartBehavior = DragStartBehavior.start,
this.keyboardDismissBehavior = ScrollViewKeyboardDismissBehavior.manual,
this.restorationId,
this.clipBehavior = Clip.hardEdge,
this.scrollBehavior,
this.center,
this.anchor = 0.0,
}) : assert(crossAxisCount != null && crossAxisCount > 0),
assert(mainAxisSpacing != null && mainAxisSpacing >= 0),
assert(crossAxisSpacing != null && crossAxisSpacing >= 0),
assert(childAspectRatio != null && childAspectRatio > 0),
super(key: key);