module-navigation-tool/Editor/Toolbar/Settings/ToolbarSettings.cs

29 lines
1,008 B
C#

using UnityEditor;
namespace Module.NavigationTool.Editor.Toolbar
{
internal static class ToolbarSettings
{
private const string PREF_IS_UI_ENABLED = "ToolbarSettings_IsUiEnabled";
private const string PREF_IS_UI_LAYER_ENABLED = "ToolbarSettings_IsUiLayerEnabled";
private const string PREF_IS_SCENE_ENABLED = "ToolbarSettings_IsSceneEnabled";
public static bool IsUiEnabled
{
get => EditorPrefs.GetBool(PREF_IS_UI_ENABLED, true);
set => EditorPrefs.SetBool(PREF_IS_UI_ENABLED, value);
}
public static bool IsUiLayerEnabled
{
get => EditorPrefs.GetBool(PREF_IS_UI_LAYER_ENABLED, true);
set => EditorPrefs.SetBool(PREF_IS_UI_LAYER_ENABLED, value);
}
public static bool IsSceneEnabled
{
get => EditorPrefs.GetBool(PREF_IS_SCENE_ENABLED, true);
set => EditorPrefs.SetBool(PREF_IS_SCENE_ENABLED, value);
}
}
}