ux: changes view mode style (#533)

* move changes view mode switch button to right button group
* change the style for ChangeViewModeSwitcher
* remove used code
This commit is contained in:
leo 2024-10-01 23:16:25 +08:00
parent 2d24244ee2
commit 6d1dfad8a1
No known key found for this signature in database
8 changed files with 34 additions and 47 deletions

View file

@ -1,24 +0,0 @@
using Avalonia;
using Avalonia.Controls;
using Avalonia.Data.Converters;
using Avalonia.Media;
namespace SourceGit.Converters
{
public static class ChangeViewModeConverters
{
public static readonly FuncValueConverter<Models.ChangeViewMode, StreamGeometry> ToIcon =
new FuncValueConverter<Models.ChangeViewMode, StreamGeometry>(v =>
{
switch (v)
{
case Models.ChangeViewMode.List:
return Application.Current?.FindResource("Icons.List") as StreamGeometry;
case Models.ChangeViewMode.Grid:
return Application.Current?.FindResource("Icons.Grid") as StreamGeometry;
default:
return Application.Current?.FindResource("Icons.Tree") as StreamGeometry;
}
});
}
}