1
mirror of https://github.com/sampletext32/ParkanPlayground.git synced 2025-12-12 01:31:20 +04:00

Material parsing and viewing

This commit is contained in:
bird_egop
2025-12-04 03:50:29 +03:00
parent 3b1fd5ef97
commit 75b1548f55
18 changed files with 1694 additions and 63 deletions

View File

@@ -0,0 +1,26 @@
using MaterialLib;
namespace NResUI.Models;
public class MaterialViewModel
{
public MaterialFile? MaterialFile { get; private set; }
public string? FilePath { get; private set; }
public string? Error { get; private set; }
public bool HasFile => MaterialFile != null;
public void SetParseResult(MaterialFile materialFile, string filePath)
{
MaterialFile = materialFile;
FilePath = filePath;
Error = null;
}
public void SetError(string error)
{
MaterialFile = null;
FilePath = null;
Error = error;
}
}