| | |
| | | <Properties StartupConfiguration="{28EDE1FF-20EF-476B-8AF8-24A3EEB69F45}|Default"> |
| | | <MonoDevelop.Ide.ItemProperties.GateWay.Droid PreferredExecutionTarget="Android.5c86e4357d63" /> |
| | | <MonoDevelop.Ide.ItemProperties.ShardLib PreferredExecutionTarget="Android.Android_Accelerated_Oreo" /> |
| | | <MonoDevelop.Ide.Workbench ActiveDocument="Shared/Phone/Device/Logic/LogicCommunalPage.cs"> |
| | | <MonoDevelop.Ide.Workbench ActiveDocument="Shared/Phone/Device/Logic/CurrentDeviceState.cs"> |
| | | <Files> |
| | | <File FileName="Shared/Phone/Device/Logic/IgnoreTime.cs" Line="141" Column="14" /> |
| | | <File FileName="Shared/Phone/Device/Logic/Illumination.cs" Line="170" Column="14" /> |
| | | <File FileName="Shared/Common/ZigbeeColor.cs" Line="348" Column="61" /> |
| | | <File FileName="GateWay.Droid/Assets/Language.ini" Line="606" Column="14" /> |
| | | <File FileName="Shared/Phone/Device/Logic/CurrentDeviceState.cs" Line="428" Column="38" /> |
| | | <File FileName="Shared/Phone/Device/Logic/LogicCommunalPage.cs" Line="434" Column="61" /> |
| | | <File FileName="Shared/R.cs" Line="896" Column="52" /> |
| | | <File FileName="Shared/Phone/Device/Logic/Illumination.cs" Line="40" Column="48" /> |
| | | <File FileName="GateWay.Droid/Assets/Language.ini" Line="615" Column="11" /> |
| | | <File FileName="Shared/Phone/Device/Logic/CurrentDeviceState.cs" Line="1278" Column="39" /> |
| | | <File FileName="Shared/Phone/Device/Logic/LogicCommunalPage.cs" Line="1255" Column="56" /> |
| | | <File FileName="Shared/Phone/Device/Logic/RoomAndDeviceView.cs" /> |
| | | <File FileName="Shared/Phone/Device/Logic/TemplatePage.cs" /> |
| | | <File FileName="Shared/Phone/Device/Logic/LogicIfon.cs" Line="55" Column="42" /> |
| | | <File FileName="Shared/Phone/Device/Logic/Send.cs" Line="270" Column="19" /> |
| | | <File FileName="Shared/Phone/Device/Logic/Nightlight.cs" Line="1" Column="1" /> |
| | | </Files> |
| | | <Pads> |
| | | <Pad Id="ProjectPad"> |
| | |
| | | <Node name="GateWay" expanded="True"> |
| | | <Node name="GateWay.Droid" expanded="True"> |
| | | <Node name="Assets" expanded="True"> |
| | | <Node name="Phone" expanded="True"> |
| | | <Node name="ZigeeLogic" expanded="True" /> |
| | | </Node> |
| | | <Node name="Phone" expanded="True" /> |
| | | </Node> |
| | | </Node> |
| | | <Node name="Home.IOS" expanded="True"> |
| | |
| | | <Node name="Logic" expanded="True"> |
| | | <Node name="DoorLockLogic" expanded="True" /> |
| | | <Node name="LogicView" expanded="True" /> |
| | | <Node name="LogicCommunalPage.cs" selected="True" /> |
| | | <Node name="CurrentDeviceState.cs" selected="True" /> |
| | | </Node> |
| | | </Node> |
| | | <Node name="UserCenter" expanded="True"> |
| | |
| | | /// 选中该设备功能作为条件或者目标的视图方法 |
| | | /// </summary> |
| | | /// <param name="common">Common.</param> |
| | | public static void CurrentDeviceView(FrameLayout flMain, CommonDevice common, bool edit, string str) |
| | | public static void CurrentDeviceView(FrameLayout flMain, CommonDevice common, bool edit, string str,int intValue) |
| | | { |
| | | #region -------界面布局部分 |
| | | //不让当前界面滑动 |
| | |
| | | { |
| | | if (_if[0]== "condition") |
| | | { |
| | | foreach (var deviceinfo in Common.Logic.CurrentLogic.Conditions) |
| | | var deviceinfo = Common.Logic.CurrentLogic.Conditions[intValue]; |
| | | if (deviceinfo["Type"] == "1") |
| | | { |
| | | if (deviceinfo["Type"] == "1") |
| | | if (common.DeviceAddr == deviceinfo["MacAddr"] && common.DeviceEpoint.ToString() == deviceinfo["Epoint"]) |
| | | { |
| | | if (common.DeviceAddr == deviceinfo["MacAddr"] && common.DeviceEpoint.ToString() == deviceinfo["Epoint"]) |
| | | { |
| | | devices = deviceinfo; |
| | | break; |
| | | devices = deviceinfo; |
| | | |
| | | } |
| | | } |
| | | } |
| | | //foreach (var deviceinfo in Common.Logic.CurrentLogic.Conditions) |
| | | //{ |
| | | // if (deviceinfo["Type"] == "1") |
| | | // { |
| | | // if (common.DeviceAddr == deviceinfo["MacAddr"] && common.DeviceEpoint.ToString() == deviceinfo["Epoint"]) |
| | | // { |
| | | // devices = deviceinfo; |
| | | // break; |
| | | // } |
| | | // } |
| | | //} |
| | | } |
| | | else |
| | | { |
| | | foreach (var deviceinfo in Common.Logic.CurrentLogic.Actions) |
| | | var deviceinfo = Common.Logic.CurrentLogic.Actions[intValue]; |
| | | if (deviceinfo["LinkType"].ToString() == "0") |
| | | { |
| | | if (deviceinfo["LinkType"].ToString() == "0") |
| | | { |
| | | |
| | | if (deviceinfo["DeviceAddr"].ToString() == common.DeviceAddr && deviceinfo["Epoint"].ToString() == common.DeviceEpoint.ToString()) |
| | | { |
| | | TaskList = deviceinfo["TaskList"] as List<Dictionary<string, string>>; |
| | | break; |
| | | } |
| | | if (deviceinfo["DeviceAddr"].ToString() == common.DeviceAddr && deviceinfo["Epoint"].ToString() == common.DeviceEpoint.ToString()) |
| | | { |
| | | TaskList = deviceinfo["TaskList"] as List<Dictionary<string, string>>; |
| | | } |
| | | } |
| | | //foreach (var deviceinfo in Common.Logic.CurrentLogic.Actions) |
| | | //{ |
| | | // if (deviceinfo["LinkType"].ToString() == "0") |
| | | // { |
| | | // if (deviceinfo["DeviceAddr"].ToString() == common.DeviceAddr && deviceinfo["Epoint"].ToString() == common.DeviceEpoint.ToString()) |
| | | // { |
| | | // TaskList = deviceinfo["TaskList"] as List<Dictionary<string, string>>; |
| | | // break; |
| | | // } |
| | | // } |
| | | //} |
| | | } |
| | | } |
| | | #endregion |
| | |
| | | Send.dictionary(deviceConditionsInfo, "AttriButeData2", "0"); |
| | | |
| | | int timeValue = 0; |
| | | int progressValue = 0; |
| | | ///点击确认事件 |
| | | openView.clickviewBtn.MouseUpEventHandler += (sender, e) => |
| | | { |
| | |
| | | var illumination = new Illumination(); |
| | | UserView.HomePage.Instance.AddChidren(illumination); |
| | | UserView.HomePage.Instance.PageIndex += 1; |
| | | illumination.Show(common, takebackView.titleBtn.Text, progressValue, true); |
| | | illumination.Show(common, takebackView.titleBtn.Text, int.Parse(devices["AttriButeData1"]), true); |
| | | } |
| | | else |
| | | { |
| | |
| | | var illumination = new Illumination(); |
| | | UserView.HomePage.Instance.AddChidren(illumination); |
| | | UserView.HomePage.Instance.PageIndex += 1; |
| | | illumination.Show(common,takebackView.titleBtn.Text, progressValue, false); |
| | | illumination.Show(common,takebackView.titleBtn.Text, 0, false); |
| | | |
| | | }; |
| | | } |
| | |
| | | |
| | | |
| | | } |
| | | else if (devices["AttriButeId"] == "0") |
| | | { |
| | | progressValue = int.Parse(devices["AttriButeData1"]); |
| | | } |
| | | |
| | | } |
| | | |
| | | } |
| | |
| | | actiondevice.selecetddevicestateBtn.Text = state; |
| | | |
| | | ///编辑 |
| | | actiondevice.edit.Tag = i.ToString(); |
| | | actiondevice.edit.MouseUpEventHandler += (sender, e) => |
| | | { |
| | | switch (linkType) |
| | |
| | | { |
| | | var flMain = new FrameLayout { BackgroundColor = ZigbeeColor.Current.LogicViewBackgroundColor }; |
| | | this.AddChidren(flMain); |
| | | CurrentDeviceState.CurrentDeviceView(flMain, deviceinof, true, "action_lockaction"); |
| | | CurrentDeviceState.CurrentDeviceView(flMain, deviceinof, true, "action_lockaction",int.Parse(actiondevice.edit.Tag.ToString())); |
| | | } |
| | | else |
| | | { |
| | |
| | | Y = Application.GetRealHeight(259 - 184), |
| | | Height = Application.GetRealHeight(50), |
| | | Width = Application.GetRealWidth(300), |
| | | Text =Language.StringByID(MyInternationalizationString.illuminanceValue)+"0lux", |
| | | Text =Language.StringByID(MyInternationalizationString.illuminanceValue)+ progresValue+"lux", |
| | | //TextID = MyInternationalizationString.Save, |
| | | TextColor = ZigbeeColor.Current.LogicBtnCancelColor, |
| | | TextSize = 12, |
| | |
| | | selecteddevice.selecetddevicestateBtn.Text = state; |
| | | } |
| | | ///编辑 |
| | | selecteddevice.edit.Tag = i.ToString(); |
| | | selecteddevice.edit.MouseUpEventHandler += (sender, e) => |
| | | { |
| | | switch (Type) |
| | |
| | | { |
| | | var flMain = new FrameLayout { BackgroundColor = ZigbeeColor.Current.LogicViewBackgroundColor }; |
| | | this.AddChidren(flMain); |
| | | CurrentDeviceState.CurrentDeviceView(flMain, deviceinof, true, "condition_logic"); |
| | | CurrentDeviceState.CurrentDeviceView(flMain, deviceinof, true, "condition_logic",int.Parse(selecteddevice.edit.Tag.ToString())); |
| | | } |
| | | else |
| | | { |
| | |
| | | actiondevice.selecetddevicestateBtn.Text = state; |
| | | } |
| | | ///编辑 |
| | | actiondevice.edit.Tag = i.ToString(); |
| | | actiondevice.edit.MouseUpEventHandler += (sender, e) => |
| | | { |
| | | switch (linkType) |
| | |
| | | { |
| | | var flMain = new FrameLayout { BackgroundColor = ZigbeeColor.Current.LogicViewBackgroundColor }; |
| | | this.AddChidren(flMain); |
| | | CurrentDeviceState.CurrentDeviceView(flMain, deviceinof, true, "action_logic"); |
| | | CurrentDeviceState.CurrentDeviceView(flMain, deviceinof, true, "action_logic",int.Parse(actiondevice.edit.Tag.ToString())); |
| | | } |
| | | else |
| | | { |
| | |
| | | } |
| | | |
| | | } |
| | | else if (common.Type == DeviceType.IASZone) { |
| | | else if (common.Type == DeviceType.IASZone) |
| | | { |
| | | var iASZonedevice = common as IASZone; |
| | | if (iASZonedevice.IasDeviceType == 541) |
| | | {//球形移动传感器 |
| | |
| | | Common.Logic.CurrentLogic.Conditions.Insert(i, objecttype); |
| | | return; |
| | | } |
| | | continue; |
| | | } |
| | | |
| | | Common.Logic.CurrentLogic.Conditions.RemoveAt(i); |
| | | Common.Logic.CurrentLogic.Conditions.Insert(i, objecttype); |
| | | return; |
| | | |
| | | } |
| | | else |
| | | { |
| | |
| | | /// <summary> |
| | | /// 添加安防输出的方法 |
| | | /// </summary> |
| | | /// <param name="objecttype">Objecttype.</param> |
| | | /// <param name="o">O.</param> |
| | | /// <param name="actionsInfo">actionsInfo.</param> |
| | | public static void AddSecurityactions(Dictionary<string, object> actionsInfo) |
| | | { |
| | | for (int i = 0; i < Common.Logic.CurrentLogic.Actions.Count; i++) |
| | |
| | | /// <summary> |
| | | /// 添加自动化输出的方法 |
| | | /// </summary> |
| | | /// <param name="objecttype">Objecttype.</param> |
| | | /// <param name="o">O.</param> |
| | | /// <param name="actionsInfo">Objecttype.</param> |
| | | /// <param name="logic">logic</param> |
| | | public static void AddLogicactions(Common.Logic logic, Dictionary<string, object> actionsInfo) |
| | | { |
| | | |
| | |
| | | devicename.IsSelected = true; |
| | | var flMain = new FrameLayout { BackgroundColor = ZigbeeColor.Current.LogicViewBackgroundColor }; |
| | | this.AddChidren(flMain); |
| | | CurrentDeviceState.CurrentDeviceView(flMain, common, false, IfType); |
| | | CurrentDeviceState.CurrentDeviceView(flMain, common, false, IfType,0); |
| | | }; |
| | | deviceFramelayout.MouseUpEventHandler += devicclick; |
| | | bjFramelayout.MouseUpEventHandler += devicclick; |
old mode 100755
new mode 100644
| | |
| | | } |
| | | break; |
| | | } |
| | | |
| | | |
| | | ///编辑 |
| | | selecteddevice.edit.Tag = i.ToString(); |
| | | selecteddevice.edit.MouseUpEventHandler += (sender, e) => |
| | | { |
| | | var deviceinof = Method.GetCommonDevice(conditions["MacAddr"], conditions["Epoint"]); |
| | | var flMain = new FrameLayout { BackgroundColor = ZigbeeColor.Current.LogicViewBackgroundColor }; |
| | | this.AddChidren(flMain); |
| | | CurrentDeviceState.CurrentDeviceView(flMain, deviceinof, true, "condition_mould"); |
| | | CurrentDeviceState.CurrentDeviceView(flMain, deviceinof, true, "condition_mould", int.Parse(selecteddevice.edit.Tag.ToString())); |
| | | |
| | | }; |
| | | ///删除控件 |
| | |
| | | break; |
| | | } |
| | | ///编辑 |
| | | |
| | | actiondevice.edit.Tag = i; |
| | | actiondevice.edit.MouseUpEventHandler += (sender, e) => { |
| | | var flMain = new FrameLayout { BackgroundColor = ZigbeeColor.Current.LogicViewBackgroundColor }; |
| | | this.AddChidren(flMain); |
| | | var deviceinof = Method.GetCommonDevice(actions["DeviceAddr"].ToString(), actions["Epoint"].ToString()); |
| | | CurrentDeviceState.CurrentDeviceView(flMain, deviceinof, true, "action_mould"); |
| | | CurrentDeviceState.CurrentDeviceView(flMain, deviceinof, true, "action_mould",int.Parse(actiondevice.edit.Tag.ToString())); |
| | | }; |
| | | ///删除控件 |
| | | actiondevice.del.MouseUpEventHandler += (sender, e) => |