using System;
using System.Windows.Input;
namespace FastReport.Preview
{
public partial class WpfPreviewControl
{
///
/// Represents a preview command.
///
public class PreviewCommand : ICommand
{
private Action action;
///
public event EventHandler CanExecuteChanged;
///
public bool CanExecute(object parameter) => true;
///
public void Execute(object parameter) => action();
internal PreviewCommand(Action action)
{
this.action = action;
}
}
}
}