using System; using System.Windows.Input; namespace Elwig.Helpers { public class ActionCommand(Action action) : ICommand { public event EventHandler? CanExecuteChanged; private readonly Action Action = action; public void Execute(object? parameter) { Action(); } public bool CanExecute(object? parameter) { return true; } } }