mac
2024-07-25 3f6685c77beeb12baf840733fb890860f4c26e7c
HDL_ON/UI/UI2/FuntionControlView/Aks/CommonView/CornerFramLayout.cs
@@ -4,6 +4,7 @@
using System.Collections.Generic;
using HDL_ON.UI.UI2.FuntionControlView.Aks.Entity;
namespace HDL_ON.UI.UI2.FuntionControlView.Aks.CommonView
{
    /// <summary>
@@ -128,17 +129,18 @@
                //不支持按键点击背景颜色
                if (!keypad.isClicked)
                {
                    buttonFram.Enable = false;
                    buttonFram.GetImageButton().Enable = false;
                    buttonFram.GetNameButton().Enable = false;
                    buttonFram.BackgroundColor = AksCommonMethod.unBackgroundColor;
                    buttonFram.GetImageButton().Alpha = 0.5f;
                    buttonFram.GetNameButton().TextColor =unBackgroundColor;
                    buttonFram.SetClick(false);
                }
                buttonFram.SetClickListener((fl, btnIcon, btnName) =>
                {
                    if (buttonFram.Tag != null && buttonFram.Tag is KeypadEntity)
                    if (buttonFram.Tag == null)
                    {
                        selectKeyAction?.Invoke((KeypadEntity)buttonFram.Tag);
                        return;
                    }
                    selectKeyAction?.Invoke((KeypadEntity)buttonFram.Tag);
                });
                //if (defaultIndex != -1 && defaultIndex == i)
@@ -216,17 +218,18 @@
                //不支持按键点击背景颜色
                if (!keypad.isClicked)
                {
                    buttonFram.Enable = false;
                    buttonFram.GetImageButton().Enable = false;
                    buttonFram.GetNameButton().Enable = false;
                    buttonFram.BackgroundColor = AksCommonMethod.unBackgroundColor;
                    buttonFram.GetImageButton().Alpha = 0.5f;
                    buttonFram.GetNameButton().TextColor = unBackgroundColor;
                    buttonFram.SetClick(false);
                }
                buttonFram.SetClickListener((fl, btnIcon, btnName) =>
                {
                    if (buttonFram.Tag != null&& buttonFram.Tag is KeypadEntity)
                    if (buttonFram.Tag == null)
                    {
                        selectKeyAction?.Invoke((KeypadEntity)buttonFram.Tag);
                        return;
                    }
                    selectKeyAction?.Invoke((KeypadEntity)buttonFram.Tag);
                });
                //if (defaultIndex != -1 && defaultIndex == i)
@@ -252,12 +255,12 @@
            }
            int currnetheightValue = 0;
            int currnetWidthValue = 0;
            int heightMaxValue = 84;
            int heightMaxValue = 84 - 6;
            int widthMaxValue = 78;
            //获取相对一个纬度值
            int heightDimensionValue = this.Height - Application.GetRealHeight(this.topMargin) - Application.GetRealHeight(this.bottomMargin) - Application.GetRealHeight(heightMaxValue / 2);
            int widthDimensionValue = this.Width - Application.GetRealWidth(this.leftMargin) - Application.GetRealWidth(this.rightMargin) - Application.GetRealHeight(widthMaxValue / 2);
            for (int i = 0; i <mList.Count; i++)
            for (int i = 0; i < mList.Count; i++)
            {
                var keypad = mList[i];
                Button button = new Button
@@ -288,21 +291,19 @@
                //不支持按键点击背景颜色
                if (!keypad.isClicked)
                {
                    button.Enable = false;
                    button.BackgroundColor = AksCommonMethod.unBackgroundColor;
                    button.TextColor =unBackgroundColor;
                }
                button.MouseDownEventHandler += (sen, e) =>
                button.MouseUpEventHandler += (sen, e) =>
                {
                    if (button.Tag == null || ((KeypadEntity)button.Tag).keypad == "none")
                    if (button.Tag == null || ((KeypadEntity)button.Tag).keypad == "none"|| !((KeypadEntity)button.Tag).isClicked)
                    {
                        return;
                    }
                    button.IsSelected = true;
                    selectKeyAction?.Invoke((KeypadEntity)button.Tag);
                };
                button.MouseUpEventHandler += (sen, e) =>
                {
                    button.IsSelected = false;
                    SetButtonIsSelected(button);
                };
                //if (defaultIndex != -1 && defaultIndex == i)