From e46f393e6bfca4a963b00717d3b1250e5b937ef6 Mon Sep 17 00:00:00 2001
From: wjc <1243177876@qq.com>
Date: 星期三, 16 八月 2023 10:56:43 +0800
Subject: [PATCH] 2023年08月16日10:56:22

---
 HDL_ON/UI/UI2/FuntionControlView/Aks/CommonView/CornerFramLayout.cs |   68 +++++++++++++++++++++++++++++++---
 1 files changed, 62 insertions(+), 6 deletions(-)

diff --git a/HDL_ON/UI/UI2/FuntionControlView/Aks/CommonView/CornerFramLayout.cs b/HDL_ON/UI/UI2/FuntionControlView/Aks/CommonView/CornerFramLayout.cs
index a31a476..5279b01 100644
--- a/HDL_ON/UI/UI2/FuntionControlView/Aks/CommonView/CornerFramLayout.cs
+++ b/HDL_ON/UI/UI2/FuntionControlView/Aks/CommonView/CornerFramLayout.cs
@@ -15,6 +15,8 @@
         private int leftMargin;
         private int bottomMargin;
         private int rightMargin;
+        private int mWidth;
+        private int mHeight;
         /// <summary>
         /// 涓�琛屽嚑涓厓绱�
         /// </summary>
@@ -45,6 +47,8 @@
             this.Width = Application.GetRealWidth(width);
             this.Height = Application.GetRealHeight(height);
             this.Radius = (uint)Application.GetRealHeight(radius);
+            this.mWidth = this.Width;
+            this.mHeight = this.Height;
 
 
         }
@@ -78,7 +82,7 @@
         /// </summary>
         /// <param name="mList">鍒楄〃</param>
         /// <param name="mRowNumber">涓�琛屽灏戜釜鍏冪礌</param>
-        /// <param name="defaultIndex">榛樿鍊肩储寮曡寖鍥碵0,mList.count-1],澶т簬鑼冨洿,璇ュ�艰涓烘棤鏁�</param>
+        /// <param name="defaultIndex">榛樿鍊肩储寮曡寖鍥碵0,mList.count-1],鍊艰秴鍑鸿寖鍥磋涓烘棤鏁�</param>
         public void LoadButtonPage(List<KeypadEntity> mList, int mRowNumber, int defaultIndex = -1)
         {
             if (mList == null || mList.Count == 0)
@@ -146,7 +150,7 @@
         /// </summary>
         /// <param name="mList">鍒楄〃</param>
         /// <param name="list"> 鍒楄〃涓储寮�,琛ㄧず鏌愪竴鏉″搴﹀姞瀹�,娌℃湁榛樿(new List<int>)</param>
-        /// <param name="defaultIndex">榛樿鍊肩储寮曡寖鍥碵0,mList.count-1],澶т簬鑼冨洿,璇ュ�艰涓烘棤鏁�</param>
+        /// <param name="defaultIndex">榛樿鍊肩储寮曡寖鍥碵0,mList.count-1],鍊艰秴鍑鸿寖鍥磋涓烘棤鏁�</param>
         public void LoadButtonPage(List<KeypadEntity> mList, List<int> list,int defaultIndex=-1)
         {
             if (mList == null || mList.Count == 0)
@@ -224,7 +228,7 @@
         ///鍔ㄦ�佸姞杞芥暟瀛楁寜閿晫闈�
         /// </summary>
         /// <param name="mList">鍒楄〃</param>
-        /// <param name="defaultIndex">榛樿鍊肩储寮曡寖鍥碵0,mList.count-1],澶т簬鑼冨洿,璇ュ�艰涓烘棤鏁�</param>
+        /// <param name="defaultIndex">榛樿鍊肩储寮曡寖鍥碵0,mList.count-1],鍊艰秴鍑鸿寖鍥磋涓烘棤鏁�</param>
         public void LoadNumberButtonPage(List<KeypadEntity> mList)
         {
             if (mList == null || mList.Count == 0)
@@ -291,7 +295,7 @@
         /// 褰辩墖甯冨眬
         /// </summary>
         /// <param name="mList">鍒楄〃</param>
-        /// <param name="defaultIndex">榛樿鍊肩储寮曡寖鍥碵0,mList.count-1],澶т簬鑼冨洿,璇ュ�艰涓烘棤鏁�</param>
+        /// <param name="defaultIndex">榛樿鍊肩储寮曡寖鍥碵0,mList.count-1],鍊艰秴鍑鸿寖鍥磋涓烘棤鏁�</param>
         public void LoadImagePage(List<MovieLibrary> mList)
         {
             if (mList == null || mList.Count == 0)
@@ -341,7 +345,7 @@
         /// 褰辩墖甯冨眬
         /// </summary>
         /// <param name="mRowNumber">涓�琛屽灏戜釜鍏冪礌</param>
-        /// <param name="defaultIndex">榛樿鍊肩储寮曡寖鍥碵0,mList.count-1],澶т簬鑼冨洿,璇ュ�艰涓烘棤鏁�</param>
+        /// <param name="defaultIndex">榛樿鍊肩储寮曡寖鍥碵0,mList.count-1],鍊艰秴鍑鸿寖鍥磋涓烘棤鏁�</param>
         public void LoadImagePage(List<MovieLibrary> mList, int mRowNumber)
         {
             if (mList == null || mList.Count == 0)
@@ -389,11 +393,63 @@
 
             }
         }
+
+       private int currnetheightValue1 = 0;
+       private int currnetWidthValue1 = 0;
+       private int heightMaxValue1 = ImageFramlayout.heightFrameLayout;
+       private int widthMaxValue1 = ImageFramlayout.widthFrameLayout;
+        //鑾峰彇鐩稿涓�涓含搴﹀��
+       private int widthDimensionValue1 = Application.GetRealWidth(343) - Application.GetRealHeight(ImageFramlayout.widthFrameLayout / 2);
+        /// <summary>
+        /// 鍔犺浇褰辩墖鍒楄〃甯冨眬
+        /// (鐗规畩甯冨眬)
+        /// </summary>
+        /// <param name="mList">鍒楄〃</param>
+        public void LoadImagePage(List<ImageFramlayout> imageFramlayoutList)
+        {
+
+            if (imageFramlayoutList==null||imageFramlayoutList.Count == 0)
+            {
+                return;
+            }
+            //int currnetheightValue = 0;
+            //int currnetWidthValue = 0;
+            //int heightMaxValue = ImageFramlayout.heightFrameLayout;
+            //int widthMaxValue = ImageFramlayout.widthFrameLayout;
+            ////鑾峰彇鐩稿涓�涓含搴﹀��
+            //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 < imageFramlayoutList.Count; i++)
+            {
+                var imageFram = imageFramlayoutList[i];
+                if (imageFram == null)
+                {
+                    continue;
+                }
+                imageFram.AddView(this);
+                imageFram.Y =Application.GetRealHeight(this.topMargin) + Application.GetRealHeight(currnetheightValue1);
+                imageFram.X = Application.GetRealWidth(currnetWidthValue1);
+                currnetWidthValue1 += (widthMaxValue1 + 8);//8鏄殧闂村��
+                if (widthDimensionValue1 < Application.GetRealWidth(currnetWidthValue1))
+                {
+                    currnetheightValue1 += (heightMaxValue1 + 20);//20鏄殧闂村��
+                    currnetWidthValue1 = 0;
+                }
+
+                imageFram.SetClickListener((fl) =>
+                {
+                    if (imageFram.Tag != null && imageFram.Tag is MovieLibrary)
+                    {
+                        selectImageAction?.Invoke((MovieLibrary)imageFram.Tag);
+                    }
+                });
+            }
+        }
         /// <summary>
         /// 姘村钩婊戝姩甯冨眬
         /// </summary>
         /// <param name="mList">鍒楄〃</param>
-        /// <param name="defaultIndex">榛樿鍊肩储寮曡寖鍥碵0,mList.count-1],澶т簬鑼冨洿,璇ュ�艰涓烘棤鏁�</param>
+        /// <param name="defaultIndex">榛樿鍊肩储寮曡寖鍥碵0,mList.count-1],鍊艰秴鍑鸿寖鍥磋涓烘棤鏁�</param>
         public void LoadHorizontalPage(List<FilterCategoryEntity> mList, int defaultIndex = -1)
         {
             if (mList == null || mList.Count == 0)

--
Gitblit v1.8.0