Skip to content

Commit 456461e

Browse files
authored
[UUM-133526] Material Editor - fix warning from GUILayout (#659)
* Add missing End GUILayout calls * Add changelog entry * Use ExitGUI() to leave the IMGUI scope early
1 parent ea9c73b commit 456461e

2 files changed

Lines changed: 3 additions & 0 deletions

File tree

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
1010
### Fixed
1111

1212
- [UUM-133861] Fixed "Look rotation viewing vector is zero" log being spammed when holding shift while using a create tool such as Create Sprite.
13+
- [UUM-133526] Material Editor: fixed a warning (`GUI Error: Invalid GUILayout state in MaterialEditor view.`) that was thrown when deleting an extra material slot.
1314
- Fixed warnings related to obsolete API calls with Unity 6.4 and onwards.
1415

1516
## [6.0.9] - 2026-01-30

Editor/EditorCore/MaterialEditor.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -361,6 +361,8 @@ void OnGUI()
361361
System.Array.Copy(materials, 0, temp, 0, materials.Length - 1);
362362
materials = temp;
363363
SaveUserMaterials(materials);
364+
365+
GUIUtility.ExitGUI();
364366
return;
365367
}
366368
GUI.backgroundColor = Color.white;

0 commit comments

Comments
 (0)