public void AddFolder(string assetsPath) { string absPath = EditorUtils.AssetsPath2ABSPath(assetsPath); //这里会卡住 m_ABConfigInfo.AddFolder(assetsPath, null); m_ABStateInfo.AddFolder(assetsPath, null); m_RootFolder.AddFolder(absPath); }
private void Init() { m_ABConfigInfo = new ABConfigInfo(); m_ABConfigInfo.LoadFromEditorConfig("abConfig.xml"); m_ABConfigInfo.RefreshConfig(); m_ABStateInfo = new ABStateInfo(); //m_ABStateInfo.LoadFromFile("abState.xml"); m_RootFolder = new ABFolderInfo(); var list = m_ABConfigInfo.GetRootFolderList(); if (list != null) { for (int i = 0; i < list.Count; ++i) { m_ABStateInfo.AddFolder(list[i].folderAssetsPath, null); m_RootFolder.AddFolder(EditorUtils.AssetsPath2ABSPath(list[i].folderAssetsPath)); } } }