ProsteDialog class

Inheritance

Constructors

ProsteDialog({Key? key, EdgeInsets insetPadding = const EdgeInsets.symmetric(horizontal: 40.0, vertical: 24.0), double dialogRadius = 5, DialogTipType type = DialogTipType.success, Widget? title, required Widget content, EdgeInsets titlePadding = const EdgeInsets.only(top: 15, left: 15, right: 15), EdgeInsets contentPadding = const EdgeInsets.all(10), Text confirmButtonText = const Text('Confirm'), Text cancelButtonText = const Text('Cancel'), bool showConfirmButton = true, bool showCancelButton = true, double buttonRadius = 5, Color? confirmButtonColor, Color? cancelButtonColor, void onConfirm()?, void onCancel()?, Duration? duration, Color? backgroundColor = Colors.white, double? elevation = 0, Color? shadowColor, bool btnsInARow = true, EdgeInsets? btnPadding, EdgeInsets? confirmButtonMargin})

Properties

backgroundColor Color?
dialog背景色
final
btnPadding EdgeInsets?
按钮的padding
final
btnsInARow bool
按钮是否放在同一行
final
buttonRadius double
按钮边框圆角
final
cancelButtonColor Color?
取消按钮背景色
final
cancelButtonText Text
取消按钮文字
final
confirmButtonColor Color?
确认按钮背景色
final
confirmButtonMargin EdgeInsets?
不是同一行是确认按钮的margin
final
confirmButtonText Text
确认按钮文字
final
content Widget
描述文字
final
contentPadding EdgeInsets
描述的间距
final
dialogRadius double
对话框的圆角
final
duration Duration?
显示时间
final
elevation double?
内容框的elevation属性
final
hashCode int
The hash code for this object.
no setterinherited
insetPadding EdgeInsets
dialog与屏幕之间的间距
final
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
onCancel → (void Function()?)
取消按钮点击事件
final
onConfirm → (void Function()?)
确认按钮点击事件
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
shadowColor Color?
阴影颜色
final
showCancelButton bool
是否展示取消按钮
final
showConfirmButton bool
是否展示确认按钮
final
title Widget?
标题组件
final
titlePadding EdgeInsets
标题的padding
final
type DialogTipType
显示的提示图片
final

Methods

createElement() StatefulElement
Creates a StatefulElement to manage this widget's location in the tree.
inherited
createState() → _ProsteDialogState
Creates the mutable state for this widget at a given location in the tree.
override
debugDescribeChildren() List<DiagnosticsNode>
Returns a list of DiagnosticsNode objects describing this node's children.
inherited
debugFillProperties(DiagnosticPropertiesBuilder properties) → void
Add additional properties associated with the node.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toDiagnosticsNode({String? name, DiagnosticsTreeStyle? style}) DiagnosticsNode
Returns a debug representation of the object that is used by debugging tools and by DiagnosticsNode.toStringDeep.
inherited
toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) String
A string representation of this object.
inherited
toStringDeep({String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug}) String
Returns a string representation of this node and its descendants.
inherited
toStringShallow({String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) String
Returns a one-line detailed description of the object.
inherited
toStringShort() String
A short, textual description of this widget.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited