namespace Yw.WinFrmUI
|
{
|
public partial class SetHydroMarkDlg : DevExpress.XtraBars.Ribbon.RibbonForm
|
{
|
public SetHydroMarkDlg()
|
{
|
InitializeComponent();
|
this.IconOptions.Icon = Yw.WinFrmUI.GlobalParas.AppIcon;
|
this.layoutControl1.SetupLayoutControl();
|
this.generalOkAndCancelCtrl1.OkEvent += GeneralOkAndCancelCtrl1_OkEvent;
|
}
|
|
/// <summary>
|
/// 重载数据事件
|
/// </summary>
|
public event Action<List<HydroMarkSetViewModel>> ReloadDataEvent;
|
|
//所有设置列表
|
private List<HydroMarkSetViewModel> _allSetList = null;
|
|
/// <summary>
|
/// 绑定数据
|
/// </summary>
|
public void SetBindingData(List<HydroMarkSetViewModel> allSetList)
|
{
|
_allSetList = allSetList;
|
this.setHydroMarkCtrl1.SetBindingData(allSetList);
|
}
|
|
//确定
|
private void GeneralOkAndCancelCtrl1_OkEvent()
|
{
|
_allSetList = this.setHydroMarkCtrl1.GetSetList();
|
this.ReloadDataEvent?.Invoke(_allSetList);
|
this.DialogResult = DialogResult.OK;
|
this.Close();
|
}
|
|
|
}
|
}
|