advanceTime method
This method is called by the Juggler with the time
past since the last
call.
Returns true as long as this Animatable is not completed; false if it is completed.
Implementation
@override
bool advanceTime(num time) {
_time += time;
if (_started == false) {
if (_time > _delay) {
_started = true;
if (_onStart != null) _onStart!();
} else {
return true;
}
}
if (_animatables.isNotEmpty) {
if (_animatables[0].advanceTime(time) == false) {
_animatables.removeAt(0);
}
}
if (_animatables.isEmpty) {
_completed = true;
if (_onComplete != null) _onComplete!();
return false;
} else {
return true;
}
}