SlidableData class
The data used by a Slidable.
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- ProxyWidget
- InheritedWidget
- SlidableData
Constructors
-
SlidableData({Key? key, required SlideActionType? actionType, required SlidableRenderingMode renderingMode, required double totalActionsExtent, required double dismissThreshold, required bool dismissible, required SlideActionDelegate? actionDelegate, required Animation<
double> overallMoveAnimation, required Animation<double> ? actionsMoveAnimation, required Animation<double> ? dismissAnimation, required Slidable slidable, required double actionExtentRatio, required Axis direction, required Widget child}) -
Creates a SlidableData.
const
Properties
- actionCount → int
-
The number of actions.
no setter
- actionDelegate → SlideActionDelegate?
-
The current actions that have to be shown.
final
- actionExtentRatio → double
-
Relative ratio between one slide action and the extent of the child.
final
- actionPaneHeightFactor → double?
-
If the direction is vertical, returns the totalActionsExtent
otherwise null.
no setter
- actionPaneWidthFactor → double?
-
If the direction is horizontal, returns the totalActionsExtent
otherwise null.
no setter
- actionSign → double
-
If the actionType is SlideActionType.primary returns 1, -1 otherwise.
no setter
-
actionsMoveAnimation
→ Animation<
double> ? -
Animation for the actions.
final
- actionType → SlideActionType?
-
The type of slide action that is currently been showed by the Slidable.
final
- alignment → Alignment
-
The alignment of the actions.
no setter
- child → Widget
-
The widget below this widget in the tree.
finalinherited
- direction → Axis
-
The direction in which this widget can be slid.
final
- directionIsXAxis → bool
-
Indicates wheter the direction is horizontal.
no setter
-
dismissAnimation
→ Animation<
double> ? -
Dismiss animation.
final
- dismissible → bool
-
Indicates whether the Slidable can be dismissed.
final
- dismissThreshold → double
-
The offset threshold the item has to be dragged in order to be considered
dismissed.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
-
overallMoveAnimation
→ Animation<
double> -
Animation for the whole movement.
final
- renderingMode → SlidableRenderingMode
-
The rendering mode in which the Slidable is.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- showActions → bool
-
Indicates whether the primary actions are currently shown.
no setter
- slidable → Slidable
-
The slidable.
final
- totalActionsExtent → double
-
The total extent of all the actions
final
Methods
-
buildActions(
BuildContext context) → List< Widget> - Builds the slide actions using the active SlideActionDelegate's builder.
-
createElement(
) → InheritedElement -
Inflates this configuration to a concrete instance.
inherited
-
createFractionallyAlignedSizedBox(
{required Widget child, double? extentFactor, double? positionFactor}) → FractionallyAlignedSizedBox - Creates a FractionallyAlignedSizedBox related to the current direction and showed actions.
-
createOffset(
double value) → Offset - Gets the the given offset related to the current direction.
-
createPositioned(
{required Widget child, double? extent, double? position}) → Positioned - Creates a positioned related to the current direction and showed actions.
-
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
-
getMaxExtent(
BoxConstraints constraints) → double - Gets the maximum extent in the current direction.
-
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
-
updateShouldNotify(
covariant SlidableData oldWidget) → bool -
Whether the framework should notify widgets that inherit from this widget.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
of(
BuildContext context) → SlidableData? - The data from the closest instance of this class that encloses the given context.