-
Notifications
You must be signed in to change notification settings - Fork 0
/
ViewModel.cs
38 lines (33 loc) · 1.09 KB
/
ViewModel.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Input;
namespace RadialMenuExample
{
public class RadialContextMenuViewModel
{
public virtual ITextBoxService TextBoxService { get { return null; } }
public ICommand CopyCommand { get; set; }
public ICommand PasteCommand { get; set; }
public ICommand CutCommand { get; set; }
public ICommand SelectAllCommand { get; set; }
public RadialContextMenuViewModel()
{
CopyCommand = ApplicationCommands.Copy;
PasteCommand = ApplicationCommands.Paste;
CutCommand = ApplicationCommands.Cut;
SelectAllCommand = ApplicationCommands.SelectAll;
}
// A ClearSelectionCommand is automatically created from the following methods by POCO:
public bool CanClearSelection()
{
return TextBoxService.CanClearSelection();
}
public void ClearSelection()
{
TextBoxService.ClearSelection();
}
}
}