From 675df74cdd4103ffdcbfa0a6ccfc105fd61af15a Mon Sep 17 00:00:00 2001
From: JLChen <551775569@qq.com>
Date: 星期五, 29 十月 2021 15:44:18 +0800
Subject: [PATCH] 2021-10-29 1.更新乐橙 AndroidSDK
---
HDL_ON/UI/UI0-Stan/Controls/BottomControls/BottomItemEditorControl.cs | 35 ++++++++++++++++++++++-------------
1 files changed, 22 insertions(+), 13 deletions(-)
diff --git a/HDL_ON/UI/UI0-Stan/Controls/BottomControls/BottomItemEditorControl.cs b/HDL_ON/UI/UI0-Stan/Controls/BottomControls/BottomItemEditorControl.cs
old mode 100755
new mode 100644
index fae40c6..6374aaf
--- a/HDL_ON/UI/UI0-Stan/Controls/BottomControls/BottomItemEditorControl.cs
+++ b/HDL_ON/UI/UI0-Stan/Controls/BottomControls/BottomItemEditorControl.cs
@@ -7,7 +7,7 @@
namespace HDL_ON.Stan
{
/// <summary>
- /// 搴曢儴椤圭洰缂栬緫鎺т欢
+ /// 搴曢儴椤圭洰缂栬緫鎺т欢(涓嶉渶瑕佸姞鍏ョ埗鎺т欢,AddRowMenu娣诲姞鑿滃崟)
/// </summary>
public class BottomItemEditorControl : BottomDialogCommon
{
@@ -18,6 +18,10 @@
/// </summary>
public Action<int> FinishEvent = null;
/// <summary>
+ /// 鐐瑰嚮纭鏃�,鏄惁鍏抽棴鐣岄潰(褰撹缃负false鏃�,鍙兘鎵嬪姩鍏抽棴)
+ /// </summary>
+ public bool CloseByConfirm = true;
+ /// <summary>
/// 鍒楄〃鎺т欢
/// </summary>
private VerticalListControl listView = null;
@@ -27,7 +31,7 @@
#region 鈻� 鍒濆鍖朹____________________________
/// <summary>
- /// 鏈夋爣棰樼殑寮圭獥鍨嬭彍鍗曠紪杈戞帶浠�
+ /// 鏈夋爣棰樼殑寮圭獥鍨嬭彍鍗曠紪杈戞帶浠�(涓嶉渶瑕佸姞鍏ョ埗鎺т欢,AddRowMenu娣诲姞鑿滃崟)
/// </summary>
/// <param name="i_RowCount">鑿滃崟琛屾暟(涓嶅惈鏍囬)</param>
/// <param name="i_title">鏍囬</param>
@@ -53,17 +57,18 @@
//鍙栨秷
base.btnCancel.ButtonClickEvent += (sender, e) =>
{
- base.Close();
this.FinishEvent?.Invoke(0);
- this.FinishEvent = null;
+ this.Close();
};
//纭
base.btnConfirm.ButtonClickEvent += (sender, e) =>
{
- base.Close();
this.FinishEvent?.Invoke(1);
- this.FinishEvent = null;
+ if (this.CloseByConfirm == true)
+ {
+ this.Close();
+ }
};
//鍒楄〃鎺т欢
@@ -82,8 +87,9 @@
/// </summary>
/// <param name="i_textView">宸﹁竟鏄剧ず鐨勬枃瀛�</param>
/// <param name="i_textValue">鍙宠竟鏄剧ず鐨勫��(</param>
- /// <param name="clickEvent">鍗曞嚮鑿滃崟鎵ц鐨勪簨浠�(鍙傛暟涓哄彸杈规樉绀哄�肩殑閭d釜鎺т欢)</param>
- public void AddRowMenu(string i_textView, string i_textValue, Action<NormalViewControl> clickEvent)
+ /// <param name="clickEvent">鍗曞嚮鑿滃崟鎵ц鐨勪簨浠�(鍙傛暟1:宸﹁竟鏍囬鎺т欢,鍙傛暟2:鍙宠竟鏄剧ず鍊肩殑閭d釜鎺т欢)</param>
+ /// <param name="addRightArrow">鏄惁娣诲姞鍙崇澶�</param>
+ public void AddRowMenu(string i_textView, string i_textValue, Action<NormalViewControl, NormalViewControl> clickEvent, bool addRightArrow = true)
{
//鍏堝垵濮嬪寲鎺т欢
this.InitControl();
@@ -101,21 +107,24 @@
//琛�
var rowContr = new FrameRowControl();
rowContr.LeftOffset = Application.GetRealWidth(20) - HdlControlResourse.XXLeft;
- rowContr.RightOffset = - rowContr.LeftOffset;
+ rowContr.RightOffset = -rowContr.LeftOffset;
rowContr.Width = this.listView.Width;
rowContr.Height = this.RowHeight;
this.listView.AddChidren(rowContr);
//鏄剧ず鏂囨湰
- var btnView = rowContr.AddLeftCaption(i_textView, 150);
+ var btnView = rowContr.AddLeftCaption(i_textView, 300);
btnView.Width = btnView.GetRealWidthByText();
btnView.TextColor = CSS_Color.FirstLevelTitleColor;
//娣诲姞鍙崇澶�
- rowContr.AddRightArrow();
+ if (addRightArrow == true)
+ {
+ rowContr.AddRightArrow();
+ }
//娣诲姞鍙宠竟鐨勬枃鏈�
- var btnValue = rowContr.AddMostRightView(i_textValue, 150);
+ var btnValue = rowContr.AddMostRightView(i_textValue, 200);
rowContr.ButtonClickEvent += (sender, e) =>
{
- clickEvent?.Invoke(btnValue);
+ clickEvent?.Invoke(btnView, btnValue);
};
}
--
Gitblit v1.8.0