public void OnGUI()
        {
            GUILayout.Label($"Create {typeof(T).Name}:");

            GUILayout.Space(25);
            GUILayout.Label("Name:");

            GUI.SetNextControlName("namefield");
            _AssetName = EditorGUILayout.TextField(_AssetName, GUILayout.ExpandWidth(true));

            if (GUILayout.Button("Create Asset") || KeyPressed(KeyCode.Return))
            {
                _ShowFileExistsMessage = AssetUtil.Exists(_FolderPath, _AssetName);
                if (!_ShowFileExistsMessage)
                {
                    CreateAndClose();
                }
            }

            if (KeyPressed(KeyCode.Escape))
            {
                Close();
            }

            if (_ShowFileExistsMessage && IsLayoutOrRepaint())
            {
                EditorGUILayout.LabelField(ERR_FILE_EXISTS, _RichTextStyle);
            }

            if (_SelectField)
            {
                EditorGUI.FocusTextInControl("namefield");
                _SelectField = false;
            }
        }
 private void CreateAndClose()
 {
     OnCreated?.Invoke(AssetUtil.Create <T>(_FolderPath, _AssetName));
     Close();
 }