Update editor

This commit is contained in:
2026-02-03 21:49:14 +09:00
parent 9fcf06dbe4
commit 59991f47d5
88 changed files with 1157 additions and 1288 deletions

View File

@@ -0,0 +1,26 @@
using Ghost.Editor.Core.Contracts;
using Ghost.Editor.Models;
using Microsoft.UI.Xaml.Data;
namespace Ghost.Editor.Utilities.Converters;
public partial class ExplorerItemToIconUriConverter : IValueConverter
{
private readonly IPreviewService _previewService = App.GetService<IPreviewService>();
public object Convert(object value, Type targetType, object parameter, string language)
{
if (value is ExplorerItem item)
{
var path = _previewService.GetIconPath(item.FullName, item.IsDirectory, IconSize.Small);
return new Uri(path);
}
throw new NotSupportedException();
}
public object ConvertBack(object value, Type targetType, object parameter, string language)
{
throw new NotImplementedException();
}
}