| | |
| | | //更新界面状态 |
| | | switch (localFunction.spk) |
| | | { |
| | | case SPK.AcstParent: |
| | | AcstParentPage.UpdateAcstParentInfo(localFunction); |
| | | break; |
| | | case SPK.AcstSub: |
| | | AcstParentPage.UpdateAcstSubInfo(localFunction); |
| | | AcstSubPage.UpdateStatus(localFunction); |
| | | break; |
| | | case SPK.AirSwitch: |
| | | AirSwitchPage.UpdataState(localFunction); |
| | | if(localFunction.GetAttribute(FunctionAttributeKey.Power)!=null)//如果是带电量的空开也要更新能源界面 |
| | |
| | | RGBPage.UpdataStates(localFunction); |
| | | break; |
| | | case SPK.LightRGBW: |
| | | localFunction.lastState = Language.StringByID(StringId.Brightness) + " : " + localFunction.GetAttrState(FunctionAttributeKey.Brightness) + "%"; |
| | | RGBWPage.UpdataStates(localFunction); |
| | | break; |
| | | case SPK.LightCCT: |
| | | localFunction.lastState = Language.StringByID(StringId.Brightness) + " : " + localFunction.GetAttrState(FunctionAttributeKey.Brightness) + "%"; |
| | |
| | | RollingShutterPage.UpdataState(localFunction); |
| | | break; |
| | | case SPK.CurtainShades: |
| | | localFunction.lastState = Language.StringByID(StringId.Open) + localFunction.GetAttrState(FunctionAttributeKey.Percent) + "%"; |
| | | VenetianBlindsPage.UpdataState(localFunction); |
| | | break; |
| | | case SPK.AcStandard: |
| | | case SPK.HvacAC: |
| | |
| | | //wjc |
| | | break; |
| | | case SPK.Inverter: |
| | | MainPage.Log("逆变器数据更新"); |
| | | var status = new Dictionary<string, object> { ["method"] = "status", ["data"] = temp.objects }; |
| | | Inverter.Ins.H5Page.CallJS($"nativeToJs(\'{Newtonsoft.Json.JsonConvert.SerializeObject(status)}\')"); |
| | | MainPage.Log("逆变器数据更新1"); |
| | | Application.RunOnMainThread(() => |
| | | { |
| | | Inverter.Ins.H5Page.CallJS($"nativeToJs(\'{Newtonsoft.Json.JsonConvert.SerializeObject(status)}\')"); |
| | | }); |
| | | MainPage.Log("逆变器数据更新2"); |
| | | break; |
| | | } |
| | | |