| | |
| | | }; |
| | | //获取自动化列表 |
| | | GetLogicList(); |
| | | // for (int i = Logic.LogicList.Count-1; i >= 0; i--)降序排列 |
| | | for (int i = 0; i < Logic.LogicList.Count; i++) |
| | | for (int i = Logic.LogicList.Count-1; i >= 0; i--)//降序排列 |
| | | //for (int i = 0; i < Logic.LogicList.Count; i++) |
| | | { |
| | | var currLogic = Logic.LogicList[i]; |
| | | ///上下间隔12像素 |
| | |
| | | addLogic.Show(); |
| | | MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1; |
| | | }; |
| | | //开关图标的点击事件 |
| | | logicView.btnSwitchIcon.MouseUpEventHandler += (sender1, e1) => |
| | | { |
| | | logicView.btnSwitchIcon.IsSelected = !logicView.btnSwitchIcon.IsSelected; |
| | |
| | | { |
| | | logicView.btnSwitchIcon.IsSelected = true; |
| | | currLogic.enable = "true"; |
| | | |
| | | |
| | | } |
| | | else |
| | | { |
| | | logicView.btnSwitchIcon.IsSelected = false; |
| | | currLogic.enable = "false"; |
| | | } |
| | | Send.switchLogic(currLogic); |
| | | //Send.switchLogic(currLogic); |
| | | new System.Threading.Thread(() => |
| | | { |
| | | try |
| | | { |
| | | //逻辑使能的命令 |
| | | Send.switchLogic(currLogic); |
| | | |
| | | } |
| | | catch { } |
| | | |
| | | }) |
| | | { IsBackground = true }.Start(); |
| | | }; |
| | | GetSelectIcon(logicView.frameLayout, currLogic); |
| | | //if (i==0)降序排列 |
| | | if (Logic.LogicList.Count - 1 == i) |
| | | if (i==0)//降序排列 |
| | | //if (Logic.LogicList.Count - 1 == i) |
| | | { |
| | | ///最后一个距离最底部12,界面显示效果作用; |
| | | vv.AddChidren(new FrameLayout { Height = Application.GetRealHeight(12) }); |
| | |
| | | automationPage.AddChidren(btnTipNot); |
| | | Button btnTipNotText = new Button() |
| | | { |
| | | Y = btnTipNot.Bottom, |
| | | Height = Application.GetRealWidth(100), |
| | | TextID = StringId.ContentIsEmpty, |
| | | Y = btnTipNot.Bottom + Application.GetRealHeight(16), |
| | | Height = Application.GetRealHeight(20), |
| | | TextID = StringId.logicnull, |
| | | TextAlignment = TextAlignment.Center, |
| | | TextColor = CSS.CSS_Color.TextualColor, |
| | | TextSize = CSS.CSS_FontSize.PromptFontSize_FirstLevel, |
| | | TextSize = LogicView.TextSize.text14, |
| | | TextColor = CSS.CSS_Color.textConfirmColor, |
| | | }; |
| | | automationPage.AddChidren(btnTipNotText); |
| | | } |
| | |
| | | return weekTextName.TrimEnd(','); |
| | | } |
| | | |
| | | |
| | | /// <summary> |
| | | /// 获取每月的字符串 |
| | | /// </summary> |
| | |
| | | /// <summary> |
| | | /// 获取逻辑列表 |
| | | /// </summary> |
| | | private static void GetLogicList() |
| | | public static void GetLogicList() |
| | | { |
| | | |
| | | if (Logic.LogicList.Count != 0) |
| | | { |
| | | //自动化列表为0才去获取自动化列表; |