Merge branch 'WJC' into wxr7
| | |
| | | switch (device.spk) |
| | | { |
| | | //开关灯光 light.Switch |
| | | case SPK.AirSwitch: |
| | | case SPK.LightDimming: |
| | | case SPK.LightRGB: |
| | | case SPK.LightRGBW: |
| | |
| | | //区别不同设备,显示不同设备状态 |
| | | switch (device.spk) |
| | | { |
| | | //开关灯光 light.Switch |
| | | //开关灯光 |
| | | case SPK.AirSwitch: |
| | | case SPK.LightDimming: |
| | | case SPK.LightRGB: |
| | | case SPK.LightRGBW: |
| | |
| | | //区别不同设备,显示不同设备状态 |
| | | switch (device.spk) |
| | | { |
| | | case SPK.AirSwitch: |
| | | case SPK.LightSwitch: |
| | | {//开关灯 |
| | | |
| | |
| | | switch (device.spk) |
| | | { |
| | | //开关灯光 |
| | | case SPK.AirSwitch: |
| | | case SPK.LightSwitch: |
| | | { |
| | | foreach (var dic in dicList) |
| | |
| | | //区别不同设备,显示不同设备状态 |
| | | switch (device.spk) |
| | | { |
| | | case SPK.AirSwitch: |
| | | case SPK.LightSwitch: |
| | | {//开关灯 |
| | | |
| | |
| | | string strPath = ""; |
| | | switch (functionType) |
| | | { |
| | | |
| | | case SPK.AirSwitch: |
| | | { |
| | | strPath = "FunctionIcon/Icon/electricalbreaker.png"; |
| | | } |
| | | break; |
| | | case SPK.LightSwitch: |
| | | case SPK.LightRGB: |
| | | case SPK.LightRGBW: |
| | |
| | | || device.spk == SPK.LightDimming |
| | | || device.spk == SPK.LightCCT |
| | | || device.spk == SPK.LightRGB |
| | | || device.spk == SPK.LightRGBW); |
| | | || device.spk == SPK.LightRGBW |
| | | || device.spk == SPK.AirSwitch); |
| | | if (lightjosn != null) |
| | | { |
| | | deviceStrTypeList.Add(Language.StringByID(StringId.Lights)); |
| | |
| | | functionTypeList.Add(SPK.LightDimming); |
| | | functionTypeList.Add(SPK.LightRGB); |
| | | functionTypeList.Add(SPK.LightRGBW); |
| | | functionTypeList.Add(SPK.LightCCT); |
| | | functionTypeList.Add(SPK.LightCCT); |
| | | functionTypeList.Add(SPK.AirSwitch); |
| | | } |
| | | else if (deviceType == Language.StringByID(StringId.Curtain)) |
| | | { |
| | |
| | | deviceTypeList.Add(SPK.SensorPm25); |
| | | deviceTypeList.Add(SPK.SensorTVOC); |
| | | deviceTypeList.Add(SPK.SensorHcho); |
| | | deviceTypeList.Add(SPK.AirSwitch); |
| | | |
| | | } |
| | | break; |
| | |
| | | deviceTypeList.Add(SPK.AcStandard); deviceTypeList.Add(SPK.HvacAC); |
| | | deviceTypeList.Add(SPK.FloorHeatStandard); deviceTypeList.Add(SPK.HvacFloorHeat); |
| | | deviceTypeList.Add(SPK.AirFreshStandard); deviceTypeList.Add(SPK.HvacAirFresh); |
| | | deviceTypeList.Add(SPK.AirSwitch); |
| | | } |
| | | break; |
| | | } |
| | |
| | | #region 编辑设备状态 |
| | | switch (device.spk) |
| | | { |
| | | //开关灯光 light.Switch |
| | | //开关灯光 |
| | | case SPK.AirSwitch: |
| | | case SPK.LightSwitch: |
| | | { |
| | | #region 界面 |
| | | ///开关 |
| | | LogicView.FunTypeView lightSwitchView = new LogicView.FunTypeView(); |
| | | lightSwitchView.btnText.TextID = StringId.switchLogic; |
| | | fLayout.AddChidren(lightSwitchView.FLayoutView()); |
| | | #endregion |
| | | #region 点击事件 |
| | | ///开关点击事件 |
| | | lightSwitchView.btnClick.MouseUpEventHandler += (sender, e) => |
| | | { |
| | | SwitchViewMethod(device, lightSwitchView.btnState, 2); |
| | | }; |
| | | if (edit) |
| | | { |
| | | //显示编辑之前的设备状态 |
| | | GetEditState(device, index, lightSwitchView.btnState, null, null, null); |
| | | } |
| | | #endregion |
| | | } |
| | | break; |
| | | //灯光开关 亮度 |
| | | case SPK.LightDimming: |
| | | case SPK.LightRGB: |
| | | case SPK.LightRGBW: |
| | |
| | | { |
| | | //显示编辑之前的设备状态 |
| | | GetEditState(device, index, lightSwitchView.btnState, brightnessView.btnState, null, null); |
| | | } |
| | | #endregion |
| | | } |
| | | break; |
| | | case SPK.LightSwitch: |
| | | { |
| | | #region 界面 |
| | | ///开关 |
| | | LogicView.FunTypeView lightSwitchView = new LogicView.FunTypeView(); |
| | | lightSwitchView.btnText.TextID = StringId.switchLogic; |
| | | fLayout.AddChidren(lightSwitchView.FLayoutView()); |
| | | #endregion |
| | | #region 点击事件 |
| | | ///开关点击事件 |
| | | lightSwitchView.btnClick.MouseUpEventHandler += (sender, e) => |
| | | { |
| | | SwitchViewMethod(device, lightSwitchView.btnState, 2); |
| | | }; |
| | | if (edit) |
| | | { |
| | | //显示编辑之前的设备状态 |
| | | GetEditState(device, index, lightSwitchView.btnState, null, null, null); |
| | | } |
| | | #endregion |
| | | } |