Class AnimationHubClipEditorRegistry
The Animation Hub's clip-editor integration seam: routes "Edit Curves" row actions to a registered
IAnimationClipEditor (the in-hub keyframe editor of a later phase) when one is registered
and willing to handle the clip, and otherwise falls back to Unity's own Animation window — selecting the
model so the window binds to it and pinging the clip so it is easy to find in the window's own clip
dropdown. At most one editor is registered at a time; a second Register(IAnimationClipEditor) call simply
replaces the first, the same "last one wins" simplification the hub's own
AnimationHubAuthoringPromptState applies to its single open prompt.
Inherited Members
Namespace: Serenity.Editor.AnimationHub.Integration
Assembly: Serenity.AnimationHub.Editor.dll
Syntax
public static class AnimationHubClipEditorRegistry
Methods
OpenEditor(string, string, string)
Opens the given clip for editing: the registered editor if one can handle it, otherwise Unity's Animation window.
Declaration
public static AnimationHubClipEditorRegistry.Result OpenEditor(string clipAssetPath, string clipSubAssetName, string modelAssetPath)
Parameters
| Type | Name | Description |
|---|---|---|
| string | clipAssetPath | Project-relative path of the clip's asset, or the asset it is embedded in. |
| string | clipSubAssetName | The clip's sub-asset name when embedded, or empty for a standalone .anim. |
| string | modelAssetPath | Project-relative path of the model the clip belongs to, or empty when none. |
Returns
| Type | Description |
|---|---|
| AnimationHubClipEditorRegistry.Result |
Register(IAnimationClipEditor)
Registers the clip editor that OpenEditor(string, string, string) tries first. Registering null is a no-op; registering a second editor replaces the first.
Declaration
public static void Register(IAnimationClipEditor editor)
Parameters
| Type | Name | Description |
|---|---|---|
| IAnimationClipEditor | editor |
Unregister(IAnimationClipEditor)
Clears the registered editor, but only if it is still the one passed in — a stale unregister from an editor that already lost the slot to a later Register(IAnimationClipEditor) call is a no-op rather than clobbering the newer registration.
Declaration
public static void Unregister(IAnimationClipEditor editor)
Parameters
| Type | Name | Description |
|---|---|---|
| IAnimationClipEditor | editor |