| | |
| | | /// </summary> |
| | | /// <param name="frame"></param> |
| | | /// <param name="tilte"></param> |
| | | public void LoadTopView() |
| | | public void LoadTopView(uint color = CSS_Color.TopViewColor) |
| | | { |
| | | contentView = new FrameLayout() |
| | | { |
| | | Height = Application.GetRealHeight(64), |
| | | BackgroundColor = CSS_Color.TopViewColor, |
| | | BackgroundColor = color, |
| | | }; |
| | | baseView.AddChidren(contentView); |
| | | |
| | |
| | | |
| | | var btnSetting = new Button() |
| | | { |
| | | X = Application.GetRealWidth(337), |
| | | Y = Application.GetRealHeight(29), |
| | | Width = Application.GetMinRealAverage(28), |
| | | Height = Application.GetMinRealAverage(28), |
| | | UnSelectedImagePath = "FunctionIcon/Light/LightScene/SetLightSceneIcon.png", |
| | | X = Application.GetRealWidth(337-37), |
| | | Y = Application.GetRealHeight(20), |
| | | Width = Application.GetMinRealAverage(28+37), |
| | | Height = Application.GetMinRealAverage(28+19), |
| | | TextID = StringId.CombinedDimming, |
| | | TextSize = CSS_FontSize.TextFontSize, |
| | | TextColor = CSS_Color.MainColor, |
| | | IsMoreLines = true |
| | | //UnSelectedImagePath = "FunctionIcon/Light/LightScene/SetLightSceneIcon.png", |
| | | }; |
| | | |
| | | contentView.AddChidren(btnSetting); |
| | |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 向framelayout添加顶部区域,添加第三方平台 |
| | | /// </summary> |
| | | /// <param name="frame"></param> |
| | | /// <param name="tilte"></param> |
| | | public void LoadTopView_Add3tyIot( Action<string, string> callBack) |
| | | { |
| | | LoadTopView(CSS_Color.MainBackgroundColor); |
| | | |
| | | var btnAddIcon = new Button() |
| | | { |
| | | X = Application.GetRealWidth(337), |
| | | Y = Application.GetRealHeight(29), |
| | | Width = Application.GetMinRealAverage(28), |
| | | Height = Application.GetMinRealAverage(28), |
| | | UnSelectedImagePath = "Public/LinkIotIcon.png", |
| | | }; |
| | | contentView.AddChidren(btnAddIcon); |
| | | |
| | | btnAddIcon.MouseUpEventHandler += (sender, e) => |
| | | { |
| | | var page = new Iot_BrandListPage(); |
| | | MainPage.BasePageView.AddChidren(page); |
| | | page.LoadPage(); |
| | | MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1; |
| | | }; |
| | | } |
| | | |
| | | |
| | | /// <summary> |
| | | /// 向framelayout添加顶部区域,第三方平台 |
| | | /// </summary> |
| | | public void LoadTopView_3tyIot(Action action) |
| | | { |
| | | LoadTopView(CSS_Color.MainBackgroundColor); |
| | | |
| | | var btnAddIcon = new Button() |
| | | { |
| | | X = Application.GetRealWidth(337), |
| | | Y = Application.GetRealHeight(29), |
| | | Width = Application.GetMinRealAverage(28), |
| | | Height = Application.GetMinRealAverage(28), |
| | | UnSelectedImagePath = "Public/Iot_agreement_icon.png", |
| | | }; |
| | | contentView.AddChidren(btnAddIcon); |
| | | |
| | | btnAddIcon.MouseUpEventHandler += (sender, e) => |
| | | { |
| | | action(); |
| | | }; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 楼层管理顶部栏 |
| | | /// </summary> |
| | | public void LoadTopView_FloorTopView(Action<string> callBack, Action action) |