flutter - 颤振中的showDialog在iOS的发布版本中不起作用
问题描述
我正在使用 Flutter 为 iOS 创建一个应用程序。对于该应用程序,我在一个屏幕中使用对话。对于该对话,它在 iOS 的发布版本中显示一个灰色层,但它在模拟器或调试版本中按预期工作。对话上有一个灰色层我已将我的代码添加给面临相同问题的任何人?需要帮忙。
static dynamic customPage(BuildContext context) {
return showDialog(
context: context,
barrierDismissible: false,
builder: (context) {
return CustomDialog(
insetPadding: const EdgeInsets.all(20),
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.all(Radius.circular(8)),
),
child: Container(
child: Stack(
children: [
Positioned(
child: Padding(
padding: const EdgeInsets.all(8.0),
child: Positioned(
right: 0.0,
child: GestureDetector(
onTap: () {
if (Navigator.canPop(context))
Navigator.pop(context, true);
},
child: Container(
color: Colors.transparent,
child: Icon(
Icons.close,
color: Colors.black,
size: 25,
),
),
),
),
),
right: 1.0,
),
Row(
mainAxisAlignment: MainAxisAlignment.center,
children: [
Image.asset(
"images/bind_loader.gif",
height: 90.0,
width: 90.0,
),
],
),
Padding(
padding: const EdgeInsets.only(top: 80.0),
child: Row(
mainAxisAlignment: MainAxisAlignment.center,
children: [
CustomDialougeUtil(),
],
),
),
Padding(
padding: const EdgeInsets.only(
right: 12.0, bottom: 10.0, top: 120),
child: Text(
"Please wait while we are confirming your payment",
style: bindTheme.textTheme.headline3,
textAlign: TextAlign.center,
),
),
],
),
),
);
},
);
}
// this is a Widget that is showDialog
class _CustomDialougeUtilState extends State<CustomDialougeUtil> {
//State full widget that uses normal timer view to display on dialogue
}
解决方案
推荐阅读
- database - 获取 Mongodb 中特定页面的关注者数量
- json - Azure DevOps Pipeline Json 变量替换 - Microsoft.Hosting.Lifetime
- html - Django 和 HTML - 将 div 放置在元素内会使其出现在错误的位置
- regex - 从 Google 表格中的链接中提取带有协议和国家/地区代码的域
- java - Java 9 第三方模块«链接»,如何?,何时?-> java.lang.NoClassDefFoundError
- r - 使用字符串指定回归公式中使用的变量
- javascript - Scriptlet 不在 Gsheet App 脚本中打印 JS 和 CSS 文件
- pine-script - Pine 脚本,尝试将指标从版本 2 迁移到 4 时出现多个错误
- sparql - SPARQL:从可能的关系列表中查找连接两个实体的关系
- java - 带有 GraphQL 服务器的 Spring Boot 未启动