27 lines
815 B
C#
27 lines
815 B
C#
![]() |
using Prism.Commands;
|
|||
|
using System;
|
|||
|
using System.Collections.Generic;
|
|||
|
using System.Linq;
|
|||
|
using System.Text;
|
|||
|
using System.Threading.Tasks;
|
|||
|
|
|||
|
namespace SWS.CAD.Models.NoEntity
|
|||
|
{
|
|||
|
public class ContextOperationModel
|
|||
|
{
|
|||
|
public string Header { get; set; }
|
|||
|
public string IconGlyph { get; set; }
|
|||
|
/// <summary>
|
|||
|
/// 大概率会直接在xaml里绑定command。如Setter Property="Command" Value="{Binding Command}"。
|
|||
|
/// 带了一个object参数,可以xaml里再绑定一个CommandParameter进去。
|
|||
|
/// </summary>
|
|||
|
public DelegateCommand<object> Command { get; set; }
|
|||
|
|
|||
|
public ContextOperationModel(string header, DelegateCommand<object> delegateCommand)
|
|||
|
{
|
|||
|
Header = header;
|
|||
|
Command = delegateCommand;
|
|||
|
}
|
|||
|
}
|
|||
|
}
|