UnityEditor.DeleteWindowLayout.OnGUI C# (CSharp) Method

OnGUI() private method

private OnGUI ( ) : void
return void
        private void OnGUI()
        {
            if (this.m_Paths == null)
            {
                this.InitializePaths();
            }
            this.m_ScrollPos = EditorGUILayout.BeginScrollView(this.m_ScrollPos, new GUILayoutOption[0]);
            foreach (string str in this.m_Paths)
            {
                string fileNameWithoutExtension = Path.GetFileNameWithoutExtension(str);
                if (fileNameWithoutExtension.Length > 15)
                {
                    fileNameWithoutExtension = fileNameWithoutExtension.Substring(0, 15) + "...";
                }
                if (GUILayout.Button(fileNameWithoutExtension, new GUILayoutOption[0]))
                {
                    if (Toolbar.lastLoadedLayoutName == fileNameWithoutExtension)
                    {
                        Toolbar.lastLoadedLayoutName = null;
                    }
                    File.Delete(str);
                    InternalEditorUtility.ReloadWindowLayoutMenu();
                    this.InitializePaths();
                }
            }
            EditorGUILayout.EndScrollView();
        }
    }