dialogBox function
void
dialogBox({
- String? title,
- Option? button01,
- Option? button02,
- VoidCallback? press01,
- VoidCallback? press02,
- bool? switchButtons,
- bool? barrierDismissible,
- Color? barrierColor,
- String? barrierLabel,
- bool? useSafeArea,
- RouteSettings? routeSettings,
- Offset? anchorPoint,
A high-level function Displays a String passing specific one to two button options and their corresponding function calls.
Implementation
void dialogBox({
String? title,
Option? button01,
Option? button02,
VoidCallback? press01,
VoidCallback? press02,
bool? switchButtons,
bool? barrierDismissible,
Color? barrierColor,
String? barrierLabel,
bool? useSafeArea,
bool? useRootNavigator,
RouteSettings? routeSettings,
Offset? anchorPoint,
}) {
showDialog<bool>(
context: App.context!,
builder: (BuildContext context) {
return _DialogWindow(
title: title,
button01: button01,
button02: button02,
press01: press01,
press02: press02,
switchButtons: switchButtons,
).show();
},
barrierDismissible: barrierDismissible ?? false,
barrierColor: barrierColor ?? Colors.black54,
barrierLabel: barrierLabel,
useSafeArea: useSafeArea ?? true,
useRootNavigator: useRootNavigator ?? true,
routeSettings: routeSettings,
anchorPoint: anchorPoint,
);
}