| | |
| | | /// 做成一个显示设备回路+房间的RowLayout
|
| | | /// </summary>
|
| | | /// <param name="i_device">设备对象</param>
|
| | | /// <param name="autoSelect">当点击此控件时,是否自动设置选择状态</param>
|
| | | /// <param name="i_ChidrenYaxis">子控件Y轴偏移量(真实值,有些界面需要这种特殊操作)</param>
|
| | | public DeviceSelectControl(CommonDevice i_device, int i_ChidrenYaxis = 0) : base(i_ChidrenYaxis)
|
| | | public DeviceSelectControl(CommonDevice i_device, bool autoSelect, int i_ChidrenYaxis = 0) : base(i_ChidrenYaxis)
|
| | | {
|
| | | this.MainKeys = Common.LocalDevice.Current.GetDeviceMainKeys(i_device);
|
| | | this.ButtonClickEvent += (sender, e) =>
|
| | | if (autoSelect == true)
|
| | | {
|
| | | this.IsSelected = Statu == StatuMode.SELECT ? false : true;
|
| | | };
|
| | | this.ButtonClickEvent += (sender, e) =>
|
| | | {
|
| | | this.IsSelected = Statu == StatuMode.SELECT ? false : true;
|
| | | };
|
| | | }
|
| | | }
|
| | |
|
| | | /// <summary>
|
| | |
| | |
|
| | | btnSelect = this.AddMostRightEmptyIcon(58, 58);
|
| | | btnSelect.Visible = false;
|
| | | btnSelect.UnSelectedImagePath = "Item/Tick.png";
|
| | | btnSelect.UnSelectedImagePath = "Item/ItemSelected.png";
|
| | | }
|
| | |
|
| | | #endregion
|