| | |
| | | /// <summary>
|
| | | /// 未分配界面的设备选择控件
|
| | | /// </summary>
|
| | | /// <param name="i_ChidrenYaxis">子控件Y轴偏移量(真实值,有些界面需要这种特殊操作)</param>
|
| | | public DeviceRowCommon(int i_ChidrenYaxis = 0) : base(i_ChidrenYaxis)
|
| | | public DeviceRowCommon()
|
| | | {
|
| | | this.SetCornerWithSameRadius(Application.GetRealHeight(58), HDLUtils.RectCornerTopLeft);
|
| | | this.Width = Application.GetRealWidth(1022);
|
| | |
| | | //设备名字
|
| | | this.btnDeviceName = new NormalViewControl(600, 60, true);
|
| | | btnDeviceName.X = Application.GetRealWidth(181);
|
| | | btnDeviceName.Y = Application.GetRealHeight(16) + this.chidrenYaxis;
|
| | | //当指定实际坐标时,这里需要的偏移量为2倍
|
| | | btnDeviceName.Y = Application.GetRealHeight(16) + this.chidrenYaxis * 2;
|
| | | btnDeviceName.Text = Common.LocalDevice.Current.GetDeviceEpointName(i_device);
|
| | | btnDeviceName.SelectedTextColor = Common.ZigbeeColor.Current.GXCTextSelectedColor;
|
| | | this.frameTable.AddChidren(btnDeviceName, ChidrenBindMode.BindEventOnly);
|
| | |
| | | //状态
|
| | | this.btnStatu = new NormalViewControl(600, 50, true);
|
| | | btnStatu.X = Application.GetRealWidth(181);
|
| | | btnStatu.Y = Application.GetRealHeight(70) + this.chidrenYaxis;
|
| | | //当指定实际坐标时,这里需要的偏移量为2倍
|
| | | btnStatu.Y = Application.GetRealHeight(70) + this.chidrenYaxis * 2;
|
| | | btnStatu.TextSize = 10;
|
| | | btnStatu.TextColor = UserCenterColor.Current.TextGrayColor1;
|
| | | this.frameTable.AddChidren(btnStatu, ChidrenBindMode.BindEventOnly);
|
| | |
| | | //如果这个函数被重写的话,则代表这个设备有开关功能
|
| | | this.isHadOpenSwitch = false;
|
| | | //默认用在线状态来判断
|
| | | return i_device.IsOnline == 1;
|
| | | return Common.LocalDevice.Current.CheckDeviceIsOnline(i_device);
|
| | | }
|
| | |
|
| | |
|