Class AdditionalPropertiesState<TState, TTarget>
Used in editor drawer part to store the state of additional properties areas.
Inherited Members
Namespace: UnityEditor.Rendering
Assembly: Unity.RenderPipelines.Core.Editor.dll
Syntax
public class AdditionalPropertiesState<TState, TTarget> : AdditionalPropertiesStateBase<TState> where TState : struct, IConvertible
Type Parameters
Name | Description |
---|---|
TState | An enum to use to describe the state. |
TTarget | A type given to automatically compute the key. |
Constructors
AdditionalPropertiesState(TState, string, string)
Constructor will create the key to store in the EditorPref the state given generic type passed.
Declaration
public AdditionalPropertiesState(TState defaultValue, string prefix = "CoreRP", string stateId = "UI_AP_State")
Parameters
Type | Name | Description |
---|---|---|
TState | defaultValue | If key did not exist, it will be created with this value for initialization. |
string | prefix | [Optional] Prefix scope of the key (Default is CoreRP) |
string | stateId | [Optional] Postfix used to differentiate between different keys (Default is UI_AP_State) |
Fields
m_State
Declaration
protected EditorPrefBoolFlags<TState> m_State
Field Value
Type | Description |
---|---|
EditorPrefBoolFlags<TState> |
Methods
GetAdditionalPropertiesState(TState)
Accessor to the expended state of this specific mask.
Declaration
public override bool GetAdditionalPropertiesState(TState mask)
Parameters
Type | Name | Description |
---|---|---|
TState | mask | The filtering mask |
Returns
Type | Description |
---|---|
bool | True: All flagged area are expended |
Overrides
HideAll()
Utility to set all states to false
Declaration
public override void HideAll()
Overrides
SetAdditionalPropertiesStateValue(TState, bool)
Setter to the expended state without resetting animation.
Declaration
protected override void SetAdditionalPropertiesStateValue(TState mask, bool value)
Parameters
Type | Name | Description |
---|---|---|
TState | mask | The filtering mask. |
bool | value | True to show the additional properties. |
Overrides
ShowAll()
Utility to set all states to true
Declaration
public override void ShowAll()