Pull down IPathedResourceManager. Reconstruct resource browser.

This commit is contained in:
2023-11-10 14:57:52 +08:00
parent bd834cff4a
commit ddf738ee27
11 changed files with 147 additions and 111 deletions

View File

@@ -1,11 +1,10 @@
using System;
using System.Collections.Generic;
namespace Cryville.Crtr.Browsing {
public interface IResourceManager<T> {
string[] CurrentDirectory { get; }
int ChangeDirectory(string[] dir);
int OpenDirectory(int id);
int ReturnToDirectory(int id);
int ItemCount { get; }
ResourceItemMeta GetItemMeta(int id);
T GetItemDetail(int id);
string GetItemPath(int id);
@@ -13,5 +12,13 @@ namespace Cryville.Crtr.Browsing {
bool ImportItemFrom(string path);
string[] GetSupportedFormats();
IReadOnlyDictionary<string, string> GetPresetPaths();
event Action ItemChanged;
}
public interface IPathedResourceManager<T> : IResourceManager<T> {
string[] CurrentDirectory { get; }
void ChangeDirectory(string[] dir);
void OpenDirectory(int id);
void ReturnToDirectory(int id);
}
}