File tree Expand file tree Collapse file tree
Assets/Editor Toolbox/Editor Expand file tree Collapse file tree Original file line number Diff line number Diff line change 22using System . Collections . Generic ;
33
44// NOTE: Needed for EntityId
5- #if UNITY_6000_5_OR_NEWER
5+ #if UNITY_6000_4_OR_NEWER
66using UnityEngine ;
77#endif
88
@@ -13,7 +13,7 @@ namespace Toolbox.Editor
1313
1414 public static class ToolboxEditorHandler
1515 {
16- #if UNITY_6000_5_OR_NEWER
16+ #if UNITY_6000_4_OR_NEWER
1717 private static EntityId lastCachedEditorId ;
1818#else
1919 private static int lastCachedEditorId ;
@@ -24,15 +24,15 @@ public static class ToolboxEditorHandler
2424 private static void OnBeginEditor ( Editor editor )
2525 {
2626 //NOTE: it means that last Editor was null or disposed, anyway we probably want to reload drawers-related cache
27- #if UNITY_6000_5_OR_NEWER
27+ #if UNITY_6000_4_OR_NEWER
2828 var lastId = lastCachedEditor . GetEntityId ( ) ;
2929#else
3030 var lastId = lastCachedEditor . GetInstanceID ( ) ;
3131#endif
3232 if ( lastCachedEditor == null || lastCachedEditorId != lastId )
3333 {
3434 lastCachedEditor = editor ;
35- #if UNITY_6000_5_OR_NEWER
35+ #if UNITY_6000_4_OR_NEWER
3636 lastCachedEditorId = editor . GetEntityId ( ) ;
3737#else
3838 lastCachedEditorId = editor . GetInstanceID ( ) ;
Original file line number Diff line number Diff line change @@ -26,7 +26,7 @@ internal enum LabelType
2626
2727 static ToolboxEditorHierarchy ( )
2828 {
29- #if UNITY_6000_5_OR_NEWER
29+ #if UNITY_6000_4_OR_NEWER
3030 EditorApplication . hierarchyWindowItemByEntityIdOnGUI -= OnItemCallback ;
3131 EditorApplication . hierarchyWindowItemByEntityIdOnGUI += OnItemCallback ;
3232#else
@@ -43,7 +43,7 @@ static ToolboxEditorHierarchy()
4343 /// <summary>
4444 /// Tries to display item label in the Hierarchy Window.
4545 /// </summary>
46- #if UNITY_6000_5_OR_NEWER
46+ #if UNITY_6000_4_OR_NEWER
4747 private static void OnItemCallback ( EntityId instanceId , Rect rect )
4848#else
4949 private static void OnItemCallback ( int instanceId , Rect rect )
You can’t perform that action at this time.
0 commit comments