Skip to content

Commit 715def5

Browse files
committed
Fix prefab overrides not shown for some properties
1 parent 3a06c2e commit 715def5

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

Editor/Elements/TriPropertyElement.cs

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,8 +58,18 @@ public override void OnGUI(Rect position)
5858
EditorGUI.showMixedValue = _property.IsValueMixed;
5959
var overrideCtx = TriPropertyOverrideContext.BeginProperty();
6060

61+
if (_property.TryGetSerializedProperty(out var serializedProperty))
62+
{
63+
EditorGUI.BeginProperty(position, null, serializedProperty);
64+
}
65+
6166
base.OnGUI(position);
6267

68+
if (_property.TryGetSerializedProperty(out _))
69+
{
70+
EditorGUI.EndProperty();
71+
}
72+
6373
overrideCtx.EndProperty();
6474
EditorGUI.showMixedValue = oldShowMixedValue;
6575
GUI.enabled = oldEnabled;

0 commit comments

Comments
 (0)