Flutter:如何创建全屏遮罩视图
Flutter:How to create a full screen mask view
现在我正在使用 showModalBottomSheet,
当我点击半透明 bottomsheet 时,它会弹出这个视图,但我想要的是它不响应用户的点击并仍然停留在那里,我该怎么做?
如何创建全屏蒙版视图?
如果用户点击 - 半透明区域 - ModalBottomSheet
不会关闭使用 - WillPopScope
showModalBottomSheet(
context: context,
builder: (context) {
return WillPopScope( // add this
onWillPop: () async => false,
child: Container()); // your code continues
});
现在我正在使用 showModalBottomSheet,
当我点击半透明 bottomsheet 时,它会弹出这个视图,但我想要的是它不响应用户的点击并仍然停留在那里,我该怎么做?
如何创建全屏蒙版视图?
如果用户点击 - 半透明区域 - ModalBottomSheet
不会关闭使用 - WillPopScope
showModalBottomSheet(
context: context,
builder: (context) {
return WillPopScope( // add this
onWillPop: () async => false,
child: Container()); // your code continues
});