Tool: Fixed issue with missing icons for scene (single/additive) toggle button in Unity 6000.0b
This commit is contained in:
parent
06420f1ad4
commit
1c6f548770
4 changed files with 28 additions and 3 deletions
|
|
@ -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;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -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");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue