Selector<T> class

@author Evan @since 2020/12/23 @describe:

Constructors

Selector.active({T? normal, T? active})
normal 设置normaldisabled active 设置activeinactive 效果同Selected.disabled, 参数名不同, 重在表达正常状态
const
Selector.all(T value)
value设置给所有状态
const
Selector.disabled({T? disabled, T? inactive})
disabled 设置normaldisabled inactive 设置activeinactive 效果同Selected.active, 参数名不同, 重在表达选中状态
const
Selector.normal({T? normal, T? active})
active 设置active 状态 其余设置normal 状态 使用不考虑 选中不可用状态
const
Selector.only({T? normal, T? active, T? disabled, T? inactive})
不同状态单独设置 未设置状态的图标为null
const

Properties

active → T?
选中状态
final
disabled → T?
不可用状态
final
hashCode int
The hash code for this object.
no setterinherited
inactive → T?
选中不可用状态
final
normal → T?
通常状态
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

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

Static Methods

getSelected<T>(Selector<T>? selected, [bool checked = false, bool disabled = false]) → T?
获取对应状态值