| | |
| | | using System.Reflection;
|
| | | using System.Text;
|
| | | using System.Text.RegularExpressions;
|
| | | using TableConfig;
|
| | |
|
| | | using UnityEditor;
|
| | | using UnityEngine;
|
| | | using UnityEngine.UI;
|
| | |
| | |
|
| | | private void OnEnable()
|
| | | {
|
| | | Config.Instance.SyncLoadConfigs();
|
| | | m_IconCfgs = Config.Instance.GetAllValues<IconConfig>();
|
| | | ConfigInitiator.EditorLoad();
|
| | | m_IconCfgs = IconConfig.GetValues();
|
| | | m_DeleteTexture = EditorGUIUtility.FindTexture("TreeEditor.Trash");
|
| | | InitStyle();
|
| | |
|
| | |
| | | var _spriteName = Regex.Replace(_fileInfo.Name, @"\.png", string.Empty, RegexOptions.IgnoreCase);
|
| | | var _index = m_IconCfgs.FindIndex((x) =>
|
| | | {
|
| | | return x.sprite == _spriteName && x.folder == _fileInfo.Directory.Name;
|
| | | return x.sprite.ToLower().Equals(_spriteName.ToLower())
|
| | | && x.folder == _fileInfo.Directory.Name;
|
| | | });
|
| | | if (_index == -1)
|
| | | {
|