wjc
2023-08-18 c1cb2d8c6034a2ee7aa8a5710bba15b14f76cebc
HDL_ON/UI/UI2/FuntionControlView/Aks/CommonView/ButtonFramLayout.cs
@@ -40,7 +40,6 @@
            TextAlignment = TextAlignment.Center,
            Gravity = Gravity.CenterHorizontal,
            Padding = new Padding(0, 20, 0, 20),
            IsMoreLines = true,
            Name = "btnName",
@@ -103,6 +102,7 @@
        /// </summary>
        public void AddLeftLine()
        {
            btnLeftLine.Height = this.Height;
            this.AddChidren(btnLeftLine);
        }
        /// <summary>
@@ -110,6 +110,8 @@
        /// </summary>
        public void AddRightLine()
        {
            btnRightLine.Height = this.Height;
            btnRightLine.X = this.Width - Application.GetRealWidth(1);
            this.AddChidren(btnRightLine);
        }
@@ -118,6 +120,7 @@
        /// </summary>
        public void AddTopLine()
        {
            btnTopLine.Width = this.Width;
            this.AddChidren(btnTopLine);
        }
        /// <summary>
@@ -125,6 +128,8 @@
        /// </summary>
        public void AddBottomLine()
        {
            btnBottomLine.Y = this.Height - Application.GetRealHeight(1);
            btnBottomLine.Width = this.Width;
            this.AddChidren(btnBottomLine);
        }
@@ -146,9 +151,13 @@
            EventHandler<MouseEventArgs> UpClick = (sender, e) =>
            {
                this.BackgroundColor = 0x00000000;
                //弹起来还原背景颜色
            };
            this.Tag = "Cancel";
            btnImage.Tag = this.Tag;
            btnName.Tag = this.Tag;
            this.MouseUpEventHandler += UpClick;
            btnImage.MouseUpEventHandler += UpClick;
            btnName.MouseUpEventHandler += UpClick;
@@ -165,10 +174,12 @@
            EventHandler<MouseEventArgs> DownClick = (sender, e) =>
            {
                //按下去改变背景颜色
                this.BackgroundColor = 0xff454635;
                this.BackgroundColor = 0xFFEFEFEF;
                action?.Invoke(this, btnImage, btnName);
            };
            this.MouseDownEventHandler += DownClick;
            btnImage.MouseDownEventHandler += DownClick;
            btnName.MouseDownEventHandler += DownClick;