diff --git a/CHANGELOG.md b/CHANGELOG.md index dbbea49..4f0764b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,11 @@ All notable changes to this project will be documented in this file. +## [1.9.3] - 2024-03-23 + +### Fixed +- Fixed issue with missing icons for scene (single/additive) toggle button in Unity 6000.0b + ## [1.9.2] - 2023-09-18 ### Changed diff --git a/Editor/Toolbar/Tools/ToolScenePicker.cs b/Editor/Toolbar/Tools/ToolScenePicker.cs index 88235cb..ae78142 100644 --- a/Editor/Toolbar/Tools/ToolScenePicker.cs +++ b/Editor/Toolbar/Tools/ToolScenePicker.cs @@ -61,12 +61,16 @@ namespace Module.NavigationTool.Editor.Toolbar if (tempIsAdditive) { +#if !UNITY_6000_0_OR_NEWER GUI.Label(rect, styles.iconSceneAdditive, styles.labelCenter); +#endif GUI.Label(rect, Styles.LABEL_SCENE_ADDITIVE, styles.labelCenter); } else { +#if !UNITY_6000_0_OR_NEWER GUI.Label(rect, styles.iconSceneSingle, styles.labelCenter); +#endif GUI.Label(rect, Styles.LABEL_SCENE_SINGLE, styles.labelCenter); } @@ -211,8 +215,15 @@ namespace Module.NavigationTool.Editor.Toolbar private static class Styles { +#if UNITY_6000_0_OR_NEWER + public static readonly GUIContent LABEL_SCENE_ADDITIVE = new GUIContent("A", "Additive scene loading (toogle to Single)"); + public static readonly GUIContent LABEL_SCENE_SINGLE = new GUIContent("S", "Single scene loading (toggle to Additive)"); +#else public static readonly GUIContent LABEL_SCENE_ADDITIVE = new GUIContent(string.Empty, "Additive scene loading (toogle to Single)"); public static readonly GUIContent LABEL_SCENE_SINGLE = new GUIContent(string.Empty, "Single scene loading (toggle to Additive)"); +#endif + + public static readonly GUIContent LABEL_SCENE_CREATE = new GUIContent(string.Empty, "Create a new scene"); public const float BUTTON_WIDTH = 24.0f; } diff --git a/Editor/Toolbar/Utilities/Styles.cs b/Editor/Toolbar/Utilities/Styles.cs index d6a48d8..6f49d69 100644 --- a/Editor/Toolbar/Utilities/Styles.cs +++ b/Editor/Toolbar/Utilities/Styles.cs @@ -15,8 +15,10 @@ namespace Module.NavigationTool.Editor.Toolbar public GUIStyle centeredMiniLabel; public GUIContent iconPlusSmall; +#if !UNITY_6000_0_OR_NEWER public GUIContent iconSceneAdditive; public GUIContent iconSceneSingle; +#endif public GUIContent iconDisconnect; public GUIContent iconProject; public GUIContent iconSettings; @@ -62,14 +64,20 @@ namespace Module.NavigationTool.Editor.Toolbar if (EditorGUIUtility.isProSkin) { iconPlusSmall = EditorGUIUtility.IconContent("d_CreateAddNew"); + +#if !UNITY_6000_0_OR_NEWER iconSceneAdditive = EditorGUIUtility.IconContent("d_winbtn_win_restore_h"); iconSceneSingle = EditorGUIUtility.IconContent("d_winbtn_win_max_h"); +#endif } else { iconPlusSmall = EditorGUIUtility.IconContent("CreateAddNew"); + +#if !UNITY_6000_0_OR_NEWER iconSceneAdditive = EditorGUIUtility.IconContent("winbtn_win_restore_h"); iconSceneSingle = EditorGUIUtility.IconContent("winbtn_win_max_h"); +#endif } iconDisconnect = EditorGUIUtility.IconContent("d_CacheServerDisconnected"); diff --git a/package.json b/package.json index 3de848f..39259a9 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "com.module.navigationtool", - "version": "1.9.2", + "version": "1.9.3", "displayName": "Module.NavigationTool", "description": "Support for navigation tools, like favorites, history and toolbars", "unity": "2019.2", @@ -18,5 +18,6 @@ "name": "Anders Ejlersen", "email": "anders@ejlersen.info", "url": "https://www.ejlersen.info" - } -} \ No newline at end of file + }, + "_fingerprint": "06420f1ad404ea844ae5d2f3a0a3f841703632f5" +}