flutter_update_dialog icon indicating copy to clipboard operation
flutter_update_dialog copied to clipboard

取消更新会关闭整个主界面

Open wangjunjx8868 opened this issue 1 year ago • 0 comments

  void customStyle() {
    if (dialog != null && dialog.isShowing()) {
      return;
    }
    dialog = UpdateDialog.showUpdate(context,
        width: 250,
        title: "是否升级到4.1.4版本?",
        updateContent: "新版本大小:2.0M\n1.xxxxxxx\n2.xxxxxxx\n3.xxxxxxx",
        titleTextSize: 14,
        contentTextSize: 12,
        buttonTextSize: 12,
        topImage: Image.asset('assets/bg_update_top.png'),
        extraHeight: 5,
        radius: 8,
        themeColor: Color(0xFFFFAC5D),
        progressBackgroundColor: Color(0x5AFFAC5D),
        isForce: true,
        updateButtonTxt: '升级',
        ignoreButtonTxt: '忽略此版本',
        enableIgnore: true, onIgnore: () {
          ToastUtils.waring("忽略");
          dialog.dismiss();
        },
        onUpdate: onUpdate);
  }

dialog.dismiss(); 这个方法会把我整个app设置成白屏了,然后整个app不可用了,是什么问题

wangjunjx8868 avatar May 12 '23 06:05 wangjunjx8868