public static string ObjectFieldOpenFolderPanel(string label, string buttonText, string defaultPath) { if (!EditorLayout.ObjectFieldButton(label, buttonText)) { return((string)null); } string str = defaultPath ?? "Assets/"; if (!Directory.Exists(str)) { str = "Assets/"; } return(EditorUtility.OpenFolderPanel(label, str, string.Empty).Replace(Directory.GetCurrentDirectory() + "/", string.Empty)); }
public static bool Foldout(bool foldout, string content, int leftMargin = 11) { return(EditorLayout.Foldout(foldout, content, EditorStyles.foldout, leftMargin)); }
public static bool MiniButtonRight(string c) { return(EditorLayout.miniButton(c, EditorStyles.miniButtonRight)); }