setProgress method
Implementation
bool setProgress(double value) {
var frameRate = this.frameRate ?? FrameRate.composition;
var roundedProgress =
composition.roundProgress(value, frameRate: frameRate);
if (roundedProgress != _progress) {
_isDirty = false;
var previousProgress = _progress;
_progress = roundedProgress;
_compositionLayer.setProgress(roundedProgress);
if (!_isDirty && frameRate != FrameRate.max && previousProgress != null) {
var alias = _progressAliases[previousProgress] ?? previousProgress;
_progressAliases[roundedProgress] = alias;
}
return _isDirty;
} else {
return false;
}
}