Hosanna UI API v1.30.2-next
    Preparing search index...

    Class ViewAnimator

    Convenience animator for a single view. Extends ViewJsonAnimator to animate a single ISGNGroup instance.

    Hierarchy (View Summary)

    Index

    Constructors

    Properties

    frameTimer: ISGROTimespan

    Tracks the elapsed time for frame rate limiting during animations. Used to ensure consistent timing between animation frames.

    id: string = ...

    Unique identifier for this animator instance.

    options: Required<AnimationOptions>

    Animation options (duration, repeat, reverse, etc).

    state: AnimState = AnimState.Stopped

    Methods

    • Called on each animation tick to update the animation state.

      Parameters

      • delta: number

        Time elapsed since the last tick, in milliseconds.

      Returns void

    • Animates the single view to new target values.

      Parameters

      • values: JsonData

        Target values for the animation.

      • duration: number

        Duration of the animation in milliseconds.

      • options: Partial<AnimationOptions> = ...

        Additional animation options.

      Returns void

    • Pauses the animation (unregisters tickable, keeps state).

      Returns void

    • Resumes the animation from the current state. If not started, starts with resume=true.

      Returns void

    • Starts the animation.

      Parameters

      • resume: boolean = false

        If true, resumes from the current state; otherwise, restarts.

      • useCurrentState: boolean = false

        If true, uses the current view state as the start values.

      Returns void

    • Stops the animation and cleans up resources.

      Returns void