Created
December 29, 2018 15:09
-
-
Save kishan2612/b198707c1831d843418f5f9243630452 to your computer and use it in GitHub Desktop.
startanimation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void _startAnimation(AnimationController _controller) { | |
_controller.fling( | |
velocity:isBackpanelVisible(widget._controller) ? -1.0 : 1.0); | |
} | |
bool isBackpanelVisible(AnimationController _controller) { | |
final AnimationStatus status =_controller.status; | |
return status == AnimationStatus.completed || | |
status == AnimationStatus.forward; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment