ZMWSLI0-SL2021-GR11/cw1/clock/Library/PackageCache/com.unity.test-framework@1.1.22/UnityEditor.TestRunner/TestRunnerWindowSettings.cs

27 lines
637 B
C#
Raw Permalink Normal View History

2021-04-10 17:27:42 +02:00
namespace UnityEditor.TestTools.TestRunner
{
internal class TestRunnerWindowSettings
{
public bool verticalSplit;
private readonly string m_PrefsKey;
public TestRunnerWindowSettings(string prefsKey)
{
m_PrefsKey = prefsKey;
verticalSplit = EditorPrefs.GetBool(m_PrefsKey + ".verticalSplit", true);
}
public void ToggleVerticalSplit()
{
verticalSplit = !verticalSplit;
Save();
}
private void Save()
{
EditorPrefs.SetBool(m_PrefsKey + ".verticalSplit", verticalSplit);
}
}
}