mirror of
https://github.com/codewriter-packages/Tri-Inspector.git
synced 2025-01-22 08:18:49 -05:00
Hide add and remove buttons for ShowInInspector arrays
This commit is contained in:
parent
e6138b340b
commit
b286b66551
@ -33,6 +33,10 @@ namespace TriInspector.Elements
|
||||
drawElementCallback = DrawElementCallback,
|
||||
};
|
||||
|
||||
var canResize = property.TryGetSerializedProperty(out _) || !property.FieldType.IsArray;
|
||||
_reorderableListGui.displayAdd &= canResize;
|
||||
_reorderableListGui.displayRemove &= canResize;
|
||||
|
||||
if (!_reorderableListGui.displayAdd && !_reorderableListGui.displayRemove)
|
||||
{
|
||||
_reorderableListGui.footerHeight = 0f;
|
||||
|
Loading…
Reference in New Issue
Block a user