Skip to content

Commit

Permalink
process #191
Browse files Browse the repository at this point in the history
  • Loading branch information
xdd666t committed May 27, 2024
1 parent 2ed9b0e commit 2e5506d
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 1 deletion.
9 changes: 9 additions & 0 deletions example/lib/demo/issue191_toast.dart
Original file line number Diff line number Diff line change
Expand Up @@ -27,5 +27,14 @@ class MyApp extends StatelessWidget {
await Future.delayed(const Duration(seconds: 1));
await SmartDialog.dismiss(status: SmartStatus.loading);
SmartDialog.showToast('test toast');
// SmartDialog.show(
// builder: (_) {
// return Container(
// color: Colors.white,
// padding: const EdgeInsets.all(30),
// child: const Text('test dialog'),
// );
// },
// );
}
}
3 changes: 3 additions & 0 deletions lib/src/custom/main_dialog.dart
Original file line number Diff line number Diff line change
Expand Up @@ -233,6 +233,9 @@ class MainDialog {
);

DialogProxy.instance.smartOverlayController.dismiss();

// safety await
await Future.delayed(const Duration(milliseconds: 20));
}

Widget getWidget() => Offstage(offstage: !visible, child: _widget);
Expand Down
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ description:
An elegant Flutter Dialog solution,
Easily implement Toast, Loading and custom Dialog,
Make the use of the dialog easier!
version: 4.9.7+5
version: 4.9.7+6
homepage: https://github.com/fluttercandies/flutter_smart_dialog
# flutter pub publish --server=https://pub.dartlang.org
# flutter build web --release --base-href="/flutter_smart_dialog/web/"
Expand Down

0 comments on commit 2e5506d

Please sign in to comment.