7 Column和ListView混合使用
2021-12-31 本文已影响0人
Jean_Lina
方式1: ListView设置shrinkWrap设置true
Expanded(
child: ListView.builder(
itemCount: choiceList.length,
itemBuilder: (cxt, index) {
return _buildListTitleWidget1(
choiceList[index], choiceList[index], index, context);
}),
);
方式2: ListView包括Expand
Expanded(
child: ListView.builder(
itemCount: choiceList.length,
itemBuilder: (cxt, index) {
return _buildListTitleWidget1(
choiceList[index], choiceList[index], index, context);
}),
)