UIGridView constructor
UIGridView({
- Key? key,
- SliverGridDelegate? gridDelegate,
- ScrollPhysics? physics,
- Axis? scrollDirection,
- EdgeInsets? edgeInsets,
- int? crossAxisCount,
- double? mainAxisSpacing,
- double? crossAxisSpacing,
- double? aspectRatio,
- UIListViewDidScrollClosure? didScrollClosure,
- List<
UICellModel> ? rows, - RefreshController? refreshController,
- VoidCallback? onRefresh,
- VoidCallback? onLoading,
Implementation
UIGridView({
Key? key,
SliverGridDelegate? gridDelegate,
ScrollPhysics? physics,
Axis? scrollDirection,
EdgeInsets? edgeInsets,
int? crossAxisCount,
double? mainAxisSpacing,
double? crossAxisSpacing,
double? aspectRatio,
UIListViewDidScrollClosure? didScrollClosure,
List<UICellModel>? rows,
RefreshController? refreshController,
VoidCallback? onRefresh,
VoidCallback? onLoading,
}) : super(key: key) {
// ignore: prefer_initializing_formals
this.gridDelegate = gridDelegate;
// ignore: prefer_initializing_formals
this.physics = physics;
this.scrollDirection = scrollDirection ?? Axis.vertical;
this.edgeInsets = edgeInsets ?? const EdgeInsets.all(0);
this.crossAxisCount = crossAxisCount ?? 1;
this.mainAxisSpacing = mainAxisSpacing ?? 5;
this.crossAxisSpacing = crossAxisSpacing ?? 5;
this.aspectRatio = aspectRatio ?? 1;
this.rows = rows ?? [];
// ignore: prefer_initializing_formals
this.refreshController = refreshController;
// ignore: prefer_initializing_formals
this.onRefresh = onRefresh;
// ignore: prefer_initializing_formals
this.onLoading = onLoading;
}