New AI actions panel. Replaced new command bar.

This commit is contained in:
Burak Kaan Köse
2026-04-03 19:50:52 +02:00
parent 27e91316d3
commit 1211e9b28a
21 changed files with 1231 additions and 443 deletions
@@ -1,15 +1,9 @@
using Wino.Core.Domain.Enums;
using Wino.Core.Domain.Interfaces;
using Wino.Core.Domain.Enums;
namespace Wino.Core.Domain.Models.Menus;
public class MailOperationMenuItem : MenuOperationItemBase<MailOperation>, IMenuOperation
public class MailOperationMenuItem : MenuOperationItemBase<MailOperation>
{
/// <summary>
/// Gets or sets whether this menu item should be placed in SecondaryCommands if used in CommandBar.
/// </summary>
public bool IsSecondaryMenuPreferred { get; set; }
protected MailOperationMenuItem(MailOperation operation, bool isEnabled, bool isSecondaryMenuItem = false) : base(operation, isEnabled)
{
IsSecondaryMenuPreferred = isSecondaryMenuItem;
@@ -1,9 +1,16 @@
using System;
using System;
using CommunityToolkit.Mvvm.ComponentModel;
using Wino.Core.Domain.Interfaces;
namespace Wino.Core.Domain.Models.Menus;
public class MenuOperationItemBase<TOperation> where TOperation : Enum
public class MenuOperationItemBase<TOperation> : ObservableObject, IMenuOperation where TOperation : Enum
{
private TOperation _operation;
private string _identifier = string.Empty;
private bool _isEnabled;
private bool _isSecondaryMenuPreferred;
public MenuOperationItemBase(TOperation operation, bool isEnabled)
{
Operation = operation;
@@ -11,7 +18,33 @@ public class MenuOperationItemBase<TOperation> where TOperation : Enum
Identifier = operation.ToString();
}
public TOperation Operation { get; set; }
public string Identifier { get; set; }
public bool IsEnabled { get; set; }
public TOperation Operation
{
get => _operation;
set
{
if (SetProperty(ref _operation, value))
{
Identifier = value.ToString();
}
}
}
public string Identifier
{
get => _identifier;
protected set => SetProperty(ref _identifier, value);
}
public bool IsEnabled
{
get => _isEnabled;
set => SetProperty(ref _isEnabled, value);
}
public bool IsSecondaryMenuPreferred
{
get => _isSecondaryMenuPreferred;
set => SetProperty(ref _isSecondaryMenuPreferred, value);
}
}