You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
569 B
17 lines
569 B
1 year ago
|
using AvaloniaEdit;
|
||
|
using CommunityToolkit.Mvvm.Input;
|
||
|
|
||
|
namespace StabilityMatrix.Avalonia.Controls;
|
||
|
|
||
|
public static class EditorCommands
|
||
|
{
|
||
|
public static RelayCommand<TextEditor> CopyCommand { get; } =
|
||
|
new(editor => editor?.Copy(), editor => editor?.CanCopy ?? false);
|
||
|
|
||
|
public static RelayCommand<TextEditor> CutCommand { get; } =
|
||
|
new(editor => editor?.Cut(), editor => editor?.CanCut ?? false);
|
||
|
|
||
|
public static RelayCommand<TextEditor> PasteCommand { get; } =
|
||
|
new(editor => editor?.Paste(), editor => editor?.CanPaste ?? false);
|
||
|
}
|