CupertinoPicker( backgroundColor: Colors.white, //选择器背景色 itemExtent: 30, //item的高度 onSelectedItemChanged: (index) { //选中item的位置索引 print("index = $index}"); }, children: <Widget>[ //所有的选择项 Text('Apple'), Text('Banana'), Text('Orange'), ], )
CupertinoPicker( backgroundColor: Colors.white, //选择器背景色 itemExtent: 30, //item的高度 onSelectedItemChanged: (index) { //选中item的位置索引 print("index = $index}"); }, children: <Widget>[ //所有的选择项 Text('Apple'), Text('Banana'), Text('Orange'), ], )
本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。