Skip to content

Instantly share code, notes, and snippets.


Afonsocraposo/main.dart Secret

Last active Aug 14, 2019
What would you like to do?
// runs when the displayed tab changes
_handleTabChange() {
// if a button was tapped, change the current index
if (_buttonTap) _setCurrentIndex(_controller.index);
// this resets the button tap
if ((_controller.index == _prevControllerIndex) ||
(_controller.index == _aniValue.round())) _buttonTap = false;
// save the previous controller index
_prevControllerIndex = _controller.index;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment