public static void EndToggleGroup(bool value, bool space = false) { if (value) { HS_GUITool.EndGroup(space); } EditorGUILayout.EndToggleGroup(); }
public static bool BeginToogleGroup(string text, bool value, int indent = 0) { if (value) { GUI.backgroundColor = Color.green; } else { GUI.backgroundColor = Color.red; } value = EditorGUILayout.BeginToggleGroup(text, value); GUI.backgroundColor = Color.white; if (value) { HS_GUITool.BeginGroup(indent); } return(value); }