using System;
|
using System.Collections.Generic;
|
using System.Drawing;
|
|
namespace HStation.Desktop
|
{
|
/// <summary>
|
/// 功能元素
|
/// </summary>
|
public class FuncElement
|
{
|
public FuncElement() { }
|
|
public FuncElement(string name)
|
{
|
this.Id = Guid.NewGuid().ToString();
|
this.Name = name;
|
this.IsGroup = true;
|
}
|
|
public FuncElement(string name, List<FuncElement> elements = null)
|
{
|
|
this.Id = Guid.NewGuid().ToString();
|
this.Name = name;
|
this.IsGroup = true;
|
this.FuncElements = elements;
|
}
|
|
public FuncElement(string name, List<FuncElement> elements = null, Image img = null)
|
{
|
|
this.Id = Guid.NewGuid().ToString();
|
this.Name = name;
|
this.IsGroup = true;
|
this.Image = img;
|
this.FuncElements = elements;
|
}
|
|
public FuncElement(string name, string dllFileName, string controlFullName, Image img = null)
|
{
|
this.Id = Guid.NewGuid().ToString();
|
this.Name = name;
|
this.DllFileName = dllFileName;
|
this.ControlFullName = controlFullName;
|
//this.SurfaceGuid = new WinFrmUI.SurfaceGuid(modular, name);
|
this.Image = img;
|
this.IsGroup = false;
|
}
|
|
|
/// <summary>
|
/// 标识
|
/// </summary>
|
public string Id { get; set; }
|
|
/// <summary>
|
/// 名称
|
/// </summary>
|
public string Name { get; set; }
|
|
/// <summary>
|
/// 图片
|
/// </summary>
|
public Image Image { get; set; }
|
|
/// <summary>
|
/// DLL 文件名称
|
/// </summary>
|
public string DllFileName { get; set; }
|
|
/// <summary>
|
/// 控件全名称
|
/// </summary>
|
public string ControlFullName { get; set; }
|
|
/// <summary>
|
/// 自身标识
|
/// </summary>
|
//public WinFrmUI.SurfaceGuid SurfaceGuid { get; set; }
|
|
/// <summary>
|
/// 展开
|
/// </summary>
|
public bool Expand { get; set; }
|
|
/// <summary>
|
/// 分组
|
/// </summary>
|
public bool IsGroup { get; set; }
|
|
/// <summary>
|
/// 子元素列表
|
/// </summary>
|
public List<FuncElement> FuncElements { get; set; }
|
|
}
|
}
|