sample method

PmlAnimSample sample(
  1. int shapeId
)

sample API.

Implementation

PmlAnimSample sample(int shapeId) {
  if (!presenting) {
    return PmlAnimSample.identity;
  }
  if (_transitioning) {
    if (_previewOnly && _endAfterTransition) {
      return PmlAnimSample.identity;
    }
    if (_transitionReverse) {
      return _sampleAt(shapeId, _slideElapsed);
    }
    final bool hasEntrance = _samplingAnims.any(
      (PmlShapeAnimation a) =>
          a.shapeId == shapeId && a.category == PmlAnimClass.entrance,
    );
    return hasEntrance ? PmlAnimSample.hidden : PmlAnimSample.identity;
  }
  return _sampleAt(shapeId, _slideElapsed);
}