diff --git a/Editor.Samples/Conditionals/Conditionals_ShowIfSample.cs b/Editor.Samples/Conditionals/Conditionals_ShowIfSample.cs index d075a47..d494c49 100644 --- a/Editor.Samples/Conditionals/Conditionals_ShowIfSample.cs +++ b/Editor.Samples/Conditionals/Conditionals_ShowIfSample.cs @@ -1,4 +1,5 @@ -using TriInspector; +using System.Collections.Generic; +using TriInspector; using UnityEngine; public class Conditionals_ShowIfSample : ScriptableObject @@ -11,7 +12,7 @@ public class Conditionals_ShowIfSample : ScriptableObject public Vector3 showWhenMaterialIsNull; [ShowIf(nameof(toggle))] - public Vector3 showWhenToggleIsTrue; + public List showWhenToggleIsTrue; [ShowIf(nameof(toggle), false)] public Vector3 showWhenToggleIsFalse; diff --git a/Editor/Attributes.cs b/Editor/Attributes.cs index 2f27f56..0063ff5 100644 --- a/Editor/Attributes.cs +++ b/Editor/Attributes.cs @@ -50,6 +50,7 @@ namespace TriInspector } public Type ProcessorType { get; } + public bool ApplyOnArrayElement { get; set; } } [AttributeUsage(AttributeTargets.Assembly, AllowMultiple = true)] @@ -61,6 +62,7 @@ namespace TriInspector } public Type ProcessorType { get; } + public bool ApplyOnArrayElement { get; set; } } [AttributeUsage(AttributeTargets.Assembly, AllowMultiple = true)] diff --git a/Editor/Utilities/TriDrawersUtilities.cs b/Editor/Utilities/TriDrawersUtilities.cs index 5b50b26..9663207 100644 --- a/Editor/Utilities/TriDrawersUtilities.cs +++ b/Editor/Utilities/TriDrawersUtilities.cs @@ -247,7 +247,7 @@ namespace TriInspector.Utilities select CreateInstance( processor.ProcessorType, valueType, it => { - // + it.ApplyOnArrayElement = processor.ApplyOnArrayElement; it.RawAttribute = attribute; }); } @@ -262,7 +262,7 @@ namespace TriInspector.Utilities select CreateInstance( processor.ProcessorType, valueType, it => { - // + it.ApplyOnArrayElement = processor.ApplyOnArrayElement; it.RawAttribute = attribute; }); }