mirror of
https://github.com/codewriter-packages/Tri-Inspector.git
synced 2025-01-22 08:18:49 -05:00
Fix groups layout is not rebuilt on value change for serialized types
This commit is contained in:
parent
1a5b5a7468
commit
6981492ea7
@ -12,6 +12,11 @@ namespace TriInspector.Elements
|
|||||||
|
|
||||||
private Dictionary<string, TriPropertyCollectionBaseElement> _groups;
|
private Dictionary<string, TriPropertyCollectionBaseElement> _groups;
|
||||||
|
|
||||||
|
internal void ClearGroups()
|
||||||
|
{
|
||||||
|
_declarations.Clear();
|
||||||
|
}
|
||||||
|
|
||||||
[PublicAPI]
|
[PublicAPI]
|
||||||
public void DeclareGroups([CanBeNull] Type type)
|
public void DeclareGroups([CanBeNull] Type type)
|
||||||
{
|
{
|
||||||
|
@ -28,8 +28,6 @@ namespace TriInspector.Elements
|
|||||||
_props = props;
|
_props = props;
|
||||||
_showReferencePicker = !property.TryGetAttribute(out HideReferencePickerAttribute _);
|
_showReferencePicker = !property.TryGetAttribute(out HideReferencePickerAttribute _);
|
||||||
_skipReferencePickerExtraLine = !_showReferencePicker && _props.inline;
|
_skipReferencePickerExtraLine = !_showReferencePicker && _props.inline;
|
||||||
|
|
||||||
DeclareGroups(property.ValueType);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public override bool Update()
|
public override bool Update()
|
||||||
@ -132,6 +130,9 @@ namespace TriInspector.Elements
|
|||||||
|
|
||||||
RemoveAllChildren();
|
RemoveAllChildren();
|
||||||
|
|
||||||
|
ClearGroups();
|
||||||
|
DeclareGroups(_property.ValueType);
|
||||||
|
|
||||||
foreach (var childProperty in _property.ChildrenProperties)
|
foreach (var childProperty in _property.ChildrenProperties)
|
||||||
{
|
{
|
||||||
AddProperty(childProperty);
|
AddProperty(childProperty);
|
||||||
|
Loading…
Reference in New Issue
Block a user