Back to API Reference
Class

AnimationHandler

abstract

One Animator-driven diff unit on a UniTextAnimationBridge. A Unity Animator writes serialized fields directly, bypassing the property setters that normally raise UniTextDirty; a handler caches a baseline of the values it watches and, after each apply, re-issues the invalidation those setters would have.

Remarks

Add handlers to the bridge's inspector list. Built-ins cover the component's own fields (UniTextFieldsAnimationHandler, UniTextWorldFieldsAnimationHandler); author your own by subclassing this for any other component-level diff. The bridge binds every handler on enable. Diffing runs once per OnDidApplyAnimationProperties — keep it allocation-free in steady state.

Derived Types(2)

Types that inherit from AnimationHandler.

protected UniTextBase Host{ get }

The component this handler diffs against, or before Bind.

protected abstract void OnBind()

Snapshots the watched values as the comparison baseline and caches any per-bind metadata.

protected virtual void OnUnbind()

Drops any live binding held beyond Host. Default: nothing.

protected abstract void OnDiff()

Diffs watched values, refreshes their baselines, and raises the matching granular invalidation.

See Also