blob: fb4891a85bc8e7bc64a0e2eba5513fcc229d9eaa (
plain)
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
|
using System;
using System.Windows.Input;
namespace Gestor.Application.ViewModels.Command;
public class RelayCommand : ICommand
{
private Action mAction;
public event EventHandler CanExecuteChanged = delegate
{
};
public RelayCommand(Action action)
{
mAction = action;
}
public bool CanExecute(object parameter)
{
return true;
}
public void Execute(object parameter)
{
mAction();
}
}
|