RaptorSuiteRegistry
Registers Suite panels from any editor assembly, including Assembly-CSharp-Editor.
| Namespace | Assembly | Kind | Stability |
|---|---|---|---|
Raptor.EditorTools | Raptor.Editor | class | preview, since 0.1.0 |
public static class RaptorSuiteRegistryProperties
Diagnostics
public static IReadOnlyList<string> Diagnostics { get; }The reasons registrations were refused, one per line.
Panels
public static IReadOnlyList<RaptorSuitePanelDescriptor> Panels { get; }Every registered panel.
Methods
Register
public static bool Register(RaptorSuitePanelDescriptor descriptor)Adds a panel. Throws on a null descriptor. Registering the same descriptor again returns true. A different descriptor with an id that is already taken is refused, and the existing panel is kept.
| Parameter | Type | Description |
|---|---|---|
descriptor | RaptorSuitePanelDescriptor | The panel. |
Returns: False when refused. The reason is added to Diagnostics.
Call from an [InitializeOnLoad] static constructor on the main thread.
Unregister
public static bool Unregister(string id, RaptorSuitePanelDescriptor descriptor)Removes a panel. The panel is removed only when descriptor is the one registered under id.
| Parameter | Type | Description |
|---|---|---|
id | string | The panel's stable id. |
descriptor | RaptorSuitePanelDescriptor | The registered descriptor. |
Returns: True when it was removed.
Events
Changed
public static event Action Changed;Raised when a panel is added or removed.
Related types
- RaptorSuitePanelDescriptor: Immutable registration data for a Suite panel.