From f1c3921b08bb22ac6f5db22d620e01d7e8e5c49f Mon Sep 17 00:00:00 2001 From: WJC <wjc@hdlchina.com.cn> Date: 星期一, 30 十二月 2019 13:32:33 +0800 Subject: [PATCH] 2019-12-30-1 --- ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/CompoundControls/TopRightMenuControl.cs | 17 +++++++++++++---- 1 files changed, 13 insertions(+), 4 deletions(-) diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/CompoundControls/TopRightMenuControl.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/CompoundControls/TopRightMenuControl.cs index 0a8b19e..20b11a9 100755 --- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/CompoundControls/TopRightMenuControl.cs +++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/CompoundControls/TopRightMenuControl.cs @@ -39,7 +39,7 @@ /// <summary> /// 鍋氭垚涓�涓瓨鍦ㄤ簬鍙充笂瑙掔殑鑿滃崟鎺т欢 /// </summary> - /// <param name="i_RowCount">涓�鍏辨湁鍑犺</param> + /// <param name="i_RowCount">涓�鍏辨湁鍑犺(涓嶅惈鏍囬)</param> /// <param name="i_width">杩欎釜鑿滃崟鏈夊瀹�</param> /// <param name="titleText">鏍囬鏂囨湰(濡傛灉涓嶄负绌�,鑿滃崟妯″紡鍙樻洿涓烘嫢鏈夋爣棰樼殑妯″紡)</param> public TopRightMenuControl(int i_RowCount, int i_width = 395, string titleText = null) @@ -66,15 +66,20 @@ //鏈�澶ф樉绀�5涓� int rowCount = this.RowCount > 5 ? 5 : this.RowCount; + if (rowCount < 5 && titleText != null) + { + //鑿滃崟+1 + rowCount++; + } //妗屽竷 - var frameTable = new FrameLayoutControl(false); + var frameTable = new FrameLayout(); frameTable.X = Application.GetRealWidth(662 - (RowWidth - 395)); frameTable.Y = Application.GetRealHeight(158 + 15 + 1); frameTable.Width = Application.GetRealWidth(RowWidth); frameTable.Height = Application.GetRealHeight(RowHeight * rowCount); frameTable.BackgroundColor = UserCenterColor.Current.White; frameTable.BorderColor = UserCenterColor.Current.Transparent; - frameTable.RadiusEx = 6; + frameTable.Radius = 6; this.AddChidren(frameTable); if (titleText != null) @@ -89,10 +94,14 @@ //鍒楄〃鎺т欢 this.listView = new VerticalListControl(); listView.Height = frameTable.Height; - if (rowCount == 5 && titleText != null) + if (rowCount == 5) { //杩炲甫鏍囬,鍙兘鏄剧ず5琛� listView.Height = frameTable.Height - Application.GetRealHeight(RowHeight); + } + if (titleText != null) + { + //鎷ユ湁鏍囬 listView.Y = Application.GetRealHeight(RowHeight); } listView.Radius = frameTable.Radius; -- Gitblit v1.8.0