ratio property
double
get
ratio
The current ratio of the full size of the Slidable that is already dragged.
This is between -1 and 1. Between -1 (inclusive) and 0(exclusive), the action pane is ActionPaneType.end. Between 0 (exclusive) and 1 (inclusive), the action pane is ActionPaneType.start.
Implementation
double get ratio => _animationController.value * direction.value;
set
ratio
(double value)
Implementation
set ratio(double value) {
final newRatio = actionPaneConfigurator?.normalizeRatio(value) ?? value;
if (_acceptRatio(newRatio) && newRatio != ratio) {
direction.value = newRatio.sign.toInt();
_animationController.value = newRatio.abs();
}
}