HoverButton class
Base widget for any widget that requires input. It provides a builder callback to build the child with the current input state: none, hovering, pressing or focused.
It's used by the following widgets:
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatefulWidget
- HoverButton
Constructors
-
HoverButton({Key? key, required ButtonStateWidgetBuilder builder, ButtonState<
MouseCursor> ? cursor, VoidCallback? onPressed, VoidCallback? onLongPress, FocusNode? focusNode, EdgeInsetsGeometry? margin, String? semanticLabel, VoidCallback? onTapDown, VoidCallback? onTapUp, VoidCallback? onTapCancel, VoidCallback? onLongPressEnd, VoidCallback? onLongPressStart, GestureDragStartCallback? onHorizontalDragStart, GestureDragUpdateCallback? onHorizontalDragUpdate, GestureDragEndCallback? onHorizontalDragEnd, ValueChanged<bool> ? onFocusChange, bool autofocus = false}) -
Creates a hover button.
const
Properties
- autofocus → bool
-
True if this widget will be selected as the initial focus when no other
node in its scope is currently focused.
final
- builder → ButtonStateWidgetBuilder
-
final
-
cursor
→ ButtonState<
MouseCursor> ? -
The cursor of this hover button. If null, MouseCursor.defer is used
final
- focusNode → FocusNode?
-
An optional focus node to use as the focus node for this widget.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- margin → EdgeInsetsGeometry?
-
The margin created around this button. The margin is added
around the Semantics widget, if any.
final
-
onFocusChange
→ ValueChanged<
bool> ? -
final
- onHorizontalDragEnd → GestureDragEndCallback?
-
final
- onHorizontalDragStart → GestureDragStartCallback?
-
final
- onHorizontalDragUpdate → GestureDragUpdateCallback?
-
final
- onLongPress → VoidCallback?
-
final
- onLongPressEnd → VoidCallback?
-
final
- onLongPressStart → VoidCallback?
-
final
- onPressed → VoidCallback?
-
final
- onTapCancel → VoidCallback?
-
final
- onTapDown → VoidCallback?
-
final
- onTapUp → VoidCallback?
-
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- semanticLabel → String?
-
Semantic label for the input.
final
Methods
-
createElement(
) → StatefulElement -
Creates a StatefulElement to manage this widget's location in the tree.
inherited
-
createState(
) → _HoverButtonState -
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