NGL@0.10.4 Home Manual Reference Source GalleryRepository
import {Animation} from 'ngl/src/animation/animation.js'
public interface | source

Animation

Animation. Base animation class.

Member Summary

Public Members
public get

True when animation has finished

public get

True when animation is paused

Method Summary

Public Methods
public

Pause animation

public

resume(releaseHold: Boolean): undefined

Resume animation

public

then(callback: Function): Promise

Promise-like interface

public

Toggle animation

Public Members

public get done: Boolean source

True when animation has finished

public get paused: Boolean source

True when animation is paused

Public Methods

public pause(hold: Boolean): undefined source

Pause animation

Params:

NameTypeAttributeDescription
hold Boolean
  • optional

put animation on a hold which must be release before it can be resumed

Return:

undefined

public resume(releaseHold: Boolean): undefined source

Resume animation

Params:

NameTypeAttributeDescription
releaseHold Boolean
  • optional

release a hold on the animation

Return:

undefined

public then(callback: Function): Promise source

Promise-like interface

Params:

NameTypeAttributeDescription
callback Function

a callback

Return:

Promise

a promise

public toggle(): undefined source

Toggle animation

Return:

undefined