From 7167334c0e89dd84827d59e726123d14776e3a09 Mon Sep 17 00:00:00 2001 From: 陈嘉乐 <cjl@hdlchina.com.cn> Date: 星期二, 16 六月 2020 11:14:13 +0800 Subject: [PATCH] 2020-06-16-1 --- HDL_ON/UI/UI2/UserPage.cs | 83 +++++++++++++++++++++++++---------------- 1 files changed, 50 insertions(+), 33 deletions(-) diff --git a/HDL_ON/UI/UI2/UserPage.cs b/HDL_ON/UI/UI2/UserPage.cs index 0d09bf7..ecaf192 100644 --- a/HDL_ON/UI/UI2/UserPage.cs +++ b/HDL_ON/UI/UI2/UserPage.cs @@ -1,4 +1,5 @@ 锘縰sing System; +using HDL_ON.Entity; using Shared; namespace HDL_ON.UI @@ -94,24 +95,44 @@ public void LoadPage() { - bodyView = this; - ContextView = new FrameLayout() + try { - Height = Application.GetRealHeight(618+25), - BackgroundColor = CSS.CSS_Color.BackgroundColor - }; - bodyView.AddChidren(ContextView); + bodyView = this; + bodyView.BackgroundColor = CSS.CSS_Color.MainBackgroundColor; + ContextView = new FrameLayout() + { + Height = Application.GetRealHeight(618 + 20), + BackgroundColor = CSS.CSS_Color.BackgroundColor, + }; + bodyView.AddChidren(ContextView); - navigationView = new FrameLayout() + navigationView = new FrameLayout() + { + Y = Application.GetRealHeight(607), + Height = Application.GetMinRealAverage(60), + }; + bodyView.AddChidren(navigationView); + if (MainPage.Increase) + { + //ContextView.Height = Application.GetRealHeight(618 + 20); + navigationView.Y = Application.GetRealHeight(597 + 5); + navigationView.Height = Application.GetRealHeight(70 - 5); + } + InitBottomView(); + + LoadEventList(); + + var homePage = new HomePage(); + ContextView.AddChidren(homePage); + homePage.LoadPage(); + + //鍒锋柊鍔熻兘鐘舵�� + DB_ResidenceData.residenceData.RefreshResidenceFunctionStatus(); + } + catch (Exception ex) { - Y = Application.GetRealHeight(607), - Height = Application.GetRealHeight(60), - }; - bodyView.AddChidren(navigationView); - - InitBottomView(); - - LoadEventList(); + MainPage.Log($"UserPage error {ex.Message}"); + } } /// <summary> @@ -122,9 +143,9 @@ navigationSelectionView = new FrameLayout() { X = Application.GetRealWidth(0 - 94 * 3), - Y = Application.GetRealHeight(4), + Y = Application.GetMinRealAverage(4), Width = Application.GetRealWidth(94 * 7), - Height = Application.GetRealHeight(38), + Height = Application.GetMinRealAverage(38), BackgroundImagePath = "Navigation/UserPageNavbg.png", }; navigationView.AddChidren(navigationSelectionView); @@ -132,22 +153,20 @@ btnNavigationSelectionIcon = new Button() { Gravity = Gravity.CenterHorizontal, - Y = Application.GetRealHeight(6), + Y = Application.GetMinRealAverage(6), Width = Application.GetMinRealAverage(22), Height = Application.GetMinRealAverage(22), UnSelectedImagePath = "Navigation/CollectionIconOn.png", }; navigationSelectionView.AddChidren(btnNavigationSelectionIcon); - NavigationSubView = new FrameLayout() { - Y = Application.GetRealHeight(11), + Y = Application.GetMinRealAverage(11), Height = Application.GetRealHeight(49), - //BackgroundColor = CSS.CSS_Color.MainBackgroundColor, + //BackgroundColor=0xFF00F0F0 }; navigationView.AddChidren(NavigationSubView); - #region 鏀惰棌鍖哄煙 collectionView = new FrameLayout() { @@ -160,7 +179,7 @@ Width = Application.GetMinRealAverage(22), Height = Application.GetMinRealAverage(22), UnSelectedImagePath = "Navigation/CollectionIcon.png", - SelectedImagePath = "0Common/transparent.png", + SelectedImagePath = "Public/transparent.png", IsSelected = true, }; collectionView.AddChidren(btnCollectionIcon); @@ -172,7 +191,7 @@ SelectedTextColor = CSS.CSS_Color.MainColor, TextColor =CSS.CSS_Color.FirstLevelTitleColor, TextSize = CSS.CSS_FontSize.PromptFontSize_SecondaryLevel, - TextID = InternationalizationString.Collection, + TextID = StringId.Collection, TextAlignment = TextAlignment.Center, }; collectionView.AddChidren(btnCollectionText); @@ -192,7 +211,7 @@ Width = Application.GetMinRealAverage(22), Height = Application.GetMinRealAverage(22), UnSelectedImagePath = "Navigation/ClassificationIcon.png", - SelectedImagePath = "0Common/transparent.png", + SelectedImagePath = "Public/transparent.png", }; classificationView.AddChidren(btnClassificationIcon); btnClassificationText = new Button() @@ -203,7 +222,7 @@ SelectedTextColor = CSS.CSS_Color.MainColor, TextColor = CSS.CSS_Color.FirstLevelTitleColor, TextSize = CSS.CSS_FontSize.PromptFontSize_SecondaryLevel, - TextID = InternationalizationString.Classification, + TextID = StringId.Classification, TextAlignment = TextAlignment.Center, }; classificationView.AddChidren(btnClassificationText); @@ -223,7 +242,7 @@ Width = Application.GetMinRealAverage(22), Height = Application.GetMinRealAverage(22), UnSelectedImagePath = "Navigation/IntellectualizationIcon.png", - SelectedImagePath = "0Common/transparent.png", + SelectedImagePath = "Public/transparent.png", }; intellectualizationView.AddChidren(btnIntellectualizationIcon); btnIntellectualizationText = new Button() @@ -234,7 +253,7 @@ TextColor = CSS.CSS_Color.FirstLevelTitleColor, SelectedTextColor = CSS.CSS_Color.MainColor, TextSize = CSS.CSS_FontSize.PromptFontSize_SecondaryLevel, - TextID = InternationalizationString.Intellectualization, + TextID = StringId.Intellectualization, TextAlignment = TextAlignment.Center, }; intellectualizationView.AddChidren(btnIntellectualizationText); @@ -255,7 +274,7 @@ Width = Application.GetMinRealAverage(22), Height = Application.GetMinRealAverage(22), UnSelectedImagePath = "Navigation/PersonalCenterIcon.png", - SelectedImagePath = "0Common/transparent.png", + SelectedImagePath = "Public/transparent.png", }; personalCenterView.AddChidren(btnPersonalCenterIcon); @@ -267,13 +286,11 @@ TextColor = CSS.CSS_Color.FirstLevelTitleColor, SelectedTextColor = CSS.CSS_Color.MainColor, TextSize = CSS.CSS_FontSize.PromptFontSize_SecondaryLevel, - TextID = InternationalizationString.Personal, + TextID = StringId.Personal, TextAlignment = TextAlignment.Center, }; personalCenterView.AddChidren(btnPersonalCenterText); #endregion - - var homePage = new HomePage(); ContextView.AddChidren(homePage); @@ -424,7 +441,7 @@ { IsBackground = true }.Start(); #endregion ContextView.RemoveAll(); - var classificaitionView = new UI.ClassificationPage(); + var classificaitionView = new ClassificationPage(); ContextView.AddChidren(classificaitionView); classificaitionView.LoadPage(); -- Gitblit v1.8.0