defaultBuildYearHead function
Widget
defaultBuildYearHead(
- BuildContext context,
- int year, {
- VoidCallback? onLast,
- VoidCallback? onNext,
默认构建年视图头部
Implementation
Widget defaultBuildYearHead(BuildContext context, int year,
{VoidCallback? onLast, VoidCallback? onNext}) {
return Container(
padding: EdgeInsets.all(10),
alignment: Alignment.center,
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: <Widget>[
onLast == null
? Container()
: IconButton(icon: Icon(Icons.chevron_left), onPressed: onLast),
Text("$year", style: TextStyle(fontSize: 20)),
onNext == null
? Container()
: IconButton(icon: Icon(Icons.chevron_right), onPressed: onNext),
],
),
);
}