SelectionMenu class

Inheritance
Available Extensions

Constructors

SelectionMenu({required WidgetBuilder selectorBuilder, required DropDownButtonBuilder? buttonBuilder, DropDownPopCreated? onCreated, DropDownPopShow? onShow, DropDownPopDismiss? onDismiss, bool enableOnHover = false, double? popWidth, bool popCenter = false, double? elevation, Color? shadowColor, String? barrierLabel, Color? barrierColor, bool barrierDismissible = true, Duration transitionDuration = const Duration(milliseconds: 200), GestureTapCallback? onDoubleTap, GestureLongPressCallback? onLongPress, GestureTapDownCallback? onTapDown, GestureTapUpCallback? onTapUp, GestureTapCancelCallback? onTapCancel, ValueChanged<bool>? onHighlightChanged, ValueChanged<bool>? onHover, MouseCursor? mouseCursor, Color? focusColor, Color? hoverColor, Color? highlightColor, MaterialStateProperty<Color?>? overlayColor, Color? splashColor, InteractiveInkFeatureFactory? splashFactory, double? radius, BorderRadius? borderRadius, ShapeBorder? customBorder, bool? enableFeedback = true, bool excludeFromSemantics = false, FocusNode? focusNode, bool canRequestFocus = true, ValueChanged<bool>? onFocusChange, bool autofocus = false, Key? key})
const

Properties

autofocus bool
final
barrierColor Color?
final
barrierDismissible bool
是否允许点击其他区域消失
final
barrierLabel String?
final
borderRadius BorderRadius?
final
buttonBuilder DropDownButtonBuilder?
下拉框构建器
final
canRequestFocus bool
final
customBorder ShapeBorder?
final
elevation double?
阴影
final
enableFeedback bool?
final
enableOnHover bool
是否开启鼠标悬浮
final
excludeFromSemantics bool
final
focusColor Color?
final
focusNode FocusNode?
final
hashCode int
The hash code for this object.
no setterinherited
highlightColor Color?
final
hoverColor Color?
final
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
mouseCursor MouseCursor?
final
onCreated DropDownPopCreated?
下拉框创建
final
onDismiss DropDownPopDismiss?
下拉框消失
final
onDoubleTap GestureTapCallback?
final
onFocusChange ValueChanged<bool>?
final
onHighlightChanged ValueChanged<bool>?
final
onHover ValueChanged<bool>?
final
onLongPress GestureLongPressCallback?
final
onShow DropDownPopShow?
下拉框显示
final
onTapCancel GestureTapCancelCallback?
final
onTapDown GestureTapDownCallback?
final
onTapUp GestureTapUpCallback?
final
overlayColor MaterialStateProperty<Color?>?
final
popCenter bool
是否是居中模式 默认左对齐
final
popWidth double?
下拉框宽度 弹窗部分
final
radius double?
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
selectorBuilder WidgetBuilder
下拉框样式构件 弹出部分
final
shadowColor Color?
阴影颜色
final
splashColor Color?
final
splashFactory InteractiveInkFeatureFactory?
final
transitionDuration Duration
动画时间
final

Methods

createElement() StatefulElement
Creates a StatefulElement to manage this widget's location in the tree.
inherited
createState() State<SelectionMenu>
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