animationEvent.d.ts 1.0 KB

123456789101112131415161718192021222324252627282930
  1. /**
  2. * Composed of a frame, and an action function
  3. */
  4. export declare class AnimationEvent {
  5. /** The frame for which the event is triggered **/
  6. frame: number;
  7. /** The event to perform when triggered **/
  8. action: (currentFrame: number) => void;
  9. /** Specifies if the event should be triggered only once**/
  10. onlyOnce?: boolean | undefined;
  11. /**
  12. * Specifies if the animation event is done
  13. */
  14. isDone: boolean;
  15. /**
  16. * Initializes the animation event
  17. * @param frame The frame for which the event is triggered
  18. * @param action The event to perform when triggered
  19. * @param onlyOnce Specifies if the event should be triggered only once
  20. */
  21. constructor(
  22. /** The frame for which the event is triggered **/
  23. frame: number,
  24. /** The event to perform when triggered **/
  25. action: (currentFrame: number) => void,
  26. /** Specifies if the event should be triggered only once**/
  27. onlyOnce?: boolean | undefined);
  28. /** @internal */
  29. _clone(): AnimationEvent;
  30. }