| | |
| | | |
| | | AddBodyView(); |
| | | |
| | | RefreshBodyView(); |
| | | RefreshBodyView(Config.Instance.Home.CurrentFloorId); |
| | | } |
| | | |
| | | |
| | |
| | | var floors = new SelectFloor(); |
| | | AddChidren(floors); |
| | | floors.Init(580, 184, Direction.Right); |
| | | floors.FloorAction += (floorName) => |
| | | floors.FloorAction += (floorId) => |
| | | { |
| | | floorBtn.Text = floorName; |
| | | RefreshBodyView(); |
| | | floorBtn.Text = Config.Instance.Home.GetFloorNameById(floorId); |
| | | RefreshBodyView(floorId); |
| | | }; |
| | | } |
| | | /// <summary> |
| | |
| | | /// <summary> |
| | | /// RefreshBodyView |
| | | /// </summary> |
| | | private void RefreshBodyView() |
| | | private void RefreshBodyView(string floorId) |
| | | { |
| | | AddRoomView(); |
| | | AddRoomView(floorId); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// AddRoomView |
| | | /// </summary> |
| | | private void AddRoomView() |
| | | private void AddRoomView(string floorId) |
| | | { |
| | | var roomFL = new HorizontalScrolViewLayout() |
| | | { |
| | |
| | | bodyFrameLayout.AddChidren(functionSceneBodyView); |
| | | |
| | | Button curBtn = new Button(); |
| | | foreach (var room in Common.Room.CurrentRoom.GetRoomsByCurrentFloorIdAppendLoveRoom()) |
| | | foreach (var room in Common.Room.CurrentRoom.GetRoomsByFloorIdAppendLoveRoom(floorId)) |
| | | { |
| | | var row = new FrameLayout() |
| | | { |
| | |
| | | }; |
| | | functionSceneBodyView.AddChidren(deviceListScrolView); |
| | | tempFunctionTypeBtn = new FunctionButton(); |
| | | tempFunctionTypeBtn.Init("",""); |
| | | |
| | | EventHandler<MouseEventArgs> ShowSameTypeFunction = (object typeSender, MouseEventArgs mouseEventArgs) => |
| | | { |
| | |
| | | Height = Application.GetRealHeight(530), |
| | | }; |
| | | dialog.AddChidren(selectFL); |
| | | selectFL.Animate = Animate.DownToUp; |
| | | |
| | | var titleBG = new FrameLayout |
| | | { |
| | |
| | | Height = Application.GetRealHeight(752), |
| | | }; |
| | | dialog.AddChidren(selectFL); |
| | | selectFL.Animate = Animate.DownToUp; |
| | | |
| | | var titleBG = new FrameLayout |
| | | { |
| | |
| | | |
| | | if (sceneTarget.TaskList.Count > 0) |
| | | { |
| | | if (sceneTarget.TaskList[0].Data1 == 0) |
| | | if (sceneTarget.TaskList[0].Data1 == 1) |
| | | { |
| | | open.IsSelected = false; |
| | | shut.IsSelected = true; |
| | |
| | | { |
| | | open.IsSelected = true; |
| | | shut.IsSelected = false; |
| | | open.SetProgress(sceneTarget.TaskList[0].Data1); |
| | | open.SetProgress(sceneTarget.TaskList[0].Data2); |
| | | } |
| | | } |
| | | |
| | |
| | | if (shut.IsSelected) |
| | | { |
| | | //关 |
| | | data1 = 0; |
| | | data1 = 1; |
| | | data2 = 0; |
| | | } |
| | | else |
| | | { |
| | | //百分比 |
| | | data1 = open.SeekBar.Progress; |
| | | data2 = 0; |
| | | data1 = 5; |
| | | data2 = open.SeekBar.Progress; |
| | | } |
| | | |
| | | var taskInfo = new ZigBee.Device.Scene.TaskListInfo |
| | |
| | | Height = Application.GetRealHeight(752), |
| | | }; |
| | | dialog.AddChidren(selectFL); |
| | | selectFL.Animate = Animate.DownToUp; |
| | | |
| | | var titleBG = new FrameLayout |
| | | { |
| | |
| | | Height = Application.GetRealHeight(1106), |
| | | }; |
| | | dialog.AddChidren(selectFL); |
| | | selectFL.Animate = Animate.DownToUp; |
| | | |
| | | var titleBG = new FrameLayout |
| | | { |
| | |
| | | } |
| | | if (tasklist.Data1 == 4 || tasklist.Data1 == 5) |
| | | { |
| | | tempId = open.temperatureList.IndexOf(tasklist.Data2); |
| | | tempId = open.temperatureList.IndexOf(tasklist.Data2/100); |
| | | } |
| | | } |
| | | |
| | |
| | | { |
| | | TaskType = taskType, |
| | | Data1 = 4, |
| | | Data2 = open.temperatureList[tempId] |
| | | Data2 = open.temperatureList[tempId]*100 |
| | | }; |
| | | taskList.Add(taskInfo3); |
| | | |
| | |
| | | { |
| | | TaskType = taskType, |
| | | Data1 = 5, |
| | | Data2 = open.temperatureList[tempId] |
| | | Data2 = open.temperatureList[tempId]*100 |
| | | }; |
| | | taskList.Add(taskInfo3); |
| | | } |