From f8283c8ebef3e0af8bd990c3e86cc9d010ba528e Mon Sep 17 00:00:00 2001 From: wjc <1243177876@qq.com> Date: 星期二, 01 八月 2023 16:37:33 +0800 Subject: [PATCH] 2023年08月01日16:37:16 --- HDL_ON/UI/UI2/FuntionControlView/Aks/AksMusicPage.cs | 267 ++++++++++++++++++----------------------------------- 1 files changed, 92 insertions(+), 175 deletions(-) diff --git a/HDL_ON/UI/UI2/FuntionControlView/Aks/AksMusicPage.cs b/HDL_ON/UI/UI2/FuntionControlView/Aks/AksMusicPage.cs index a13003f..80df87b 100644 --- a/HDL_ON/UI/UI2/FuntionControlView/Aks/AksMusicPage.cs +++ b/HDL_ON/UI/UI2/FuntionControlView/Aks/AksMusicPage.cs @@ -1,17 +1,90 @@ 锘縰sing System; +using System.Collections.Generic; using HDL_ON.UI.Music; using HDL_ON.UI.UI2.FuntionControlView.Aks.CommonView; using Shared; +using static HDL_ON.UI.UI2.FuntionControlView.Aks.AksPage; namespace HDL_ON.UI.UI2.FuntionControlView.Aks { + /// <summary> + /// 鎾斁鍣ㄧ晫闈� + /// </summary> public class AksMusicPage : BaseFramLayout { public AksMusicPage() { } + + public Action<IntType> action; + CornerFramLayout cornerFram; + TypeSingleFramLayout typeSingleFramLayout; + MenuFramLayout menuFram; + TypeMultiFramLayout typeMultiFramLayout; public void Show() + { + //鍒濆鍖朥I + this.InitUI(); + //鍒濆鍖栦簨浠� + this.EventListener(); + //璇诲彇鏁版嵁 + this.ReadData(); + + } + + private void ReadData() + { + + } + + private void EventListener() + { + cornerFram.LoadButtonPage(4, (value) => + { + Console.WriteLine("1"); + }); + + typeSingleFramLayout.SetClickListener((f) => + { + Console.WriteLine("2"); + }); + + menuFram.SetTopClickListener((b) => + { + Console.WriteLine("5"); + }); + menuFram.SetBottomClickListener((b) => + { + Console.WriteLine("6"); + }); + menuFram.SetLeftClickListener((b) => + { + Console.WriteLine("7"); + }); + menuFram.SetRightClickListener((b) => + { + Console.WriteLine("8"); + }); + menuFram.SetOkClickListener((b) => + { + Console.WriteLine("9"); + }); + + typeMultiFramLayout.SetLeftFlClickListener((f) => + { + Console.WriteLine("3"); + }); + + typeMultiFramLayout.SetRightFlClickListener((f) => + { + Console.WriteLine("4"); + action?.Invoke(IntType.Player); + }); + + } + + private void InitUI() { this.BackgroundColor = MusicColor.ViewColor; Button btnTitle = new Button @@ -27,194 +100,38 @@ }; this.AddChidren(btnTitle); - CornerFramLayout cornerFram = new CornerFramLayout(343, 452); + cornerFram = new CornerFramLayout(343, 452); cornerFram.X = Application.GetRealWidth(16); cornerFram.Y = btnTitle.Bottom + Application.GetRealHeight(16); this.AddChidren(cornerFram); cornerFram.SetList(cornerFram.GetTestList(17)); cornerFram.SetMargin(16, 0, 16, 0); - cornerFram.LoadButtonPage(4, (value) => - { - - }); - - FrameLayout payerFramLayout = new FrameLayout(); - payerFramLayout.Width = Application.GetRealWidth(343); - payerFramLayout.Height = Application.GetRealHeight(364); - payerFramLayout.Y = cornerFram.Bottom + Application.GetRealHeight(16); - payerFramLayout.X = Application.GetRealWidth(16); - payerFramLayout.BackgroundColor = MusicColor.WhiteColor; - payerFramLayout.Radius = (uint)Application.GetRealHeight(17); - this.AddChidren(payerFramLayout); - FrameLayout singleFramLayout = new FrameLayout - { - BackgroundColor = MusicColor.ViewColor, - Y = Application.GetRealHeight(24), - Gravity = Gravity.CenterHorizontal, - Width = Application.GetRealWidth(101), - Height = Application.GetRealHeight(40), - Radius = (uint)Application.GetRealHeight(20), - }; - payerFramLayout.AddChidren(singleFramLayout); + CornerFramLayout cornerBottomFram = new CornerFramLayout(343, 364); + cornerBottomFram.X = Application.GetRealWidth(16); + cornerBottomFram.Y = cornerFram.Bottom + Application.GetRealHeight(16); + cornerBottomFram.BackgroundColor = MusicColor.WhiteColor; + cornerBottomFram.Radius = (uint)Application.GetRealHeight(17); + this.AddChidren(cornerBottomFram); - Button btnLeftImage = new Button - { - X = Application.GetRealWidth(16), - Width = Application.GetRealWidth(16), - Height = Application.GetRealWidth(16), - UnSelectedImagePath = "AksIcon/yingku.png", - Gravity = Gravity.CenterVertical, - Name = "btnLeftImage", - }; - singleFramLayout.AddChidren(btnLeftImage); - Button btnName = new Button - { - X = btnLeftImage.Right + Application.GetRealWidth(4), - Width = Application.GetRealWidth(32), - Height = Application.GetRealHeight(23), - TextID = StringId.yingku, - TextSize = TextSize.Text16, - TextColor = MusicColor.TextColor, - TextAlignment = TextAlignment.Center, - Gravity = Gravity.CenterVertical, - IsMoreLines = true, - Name = "btnName", - }; - singleFramLayout.AddChidren(btnName); - Button btnRightImage = new Button - { - X = btnName.Right + Application.GetRealWidth(8), - Width = Application.GetRealWidth(5), - Height = Application.GetRealWidth(8), - UnSelectedImagePath = "AksIcon/yingkunext.png", - Gravity = Gravity.CenterVertical, - Name = "btnRightImage", - }; - singleFramLayout.AddChidren(btnRightImage); + typeSingleFramLayout = new TypeSingleFramLayout(); + typeSingleFramLayout.singleFramLayout.Y = Application.GetRealHeight(24); + typeSingleFramLayout.AddView(cornerBottomFram); + + menuFram = new MenuFramLayout(); + menuFram.Y = typeSingleFramLayout.singleFramLayout.Bottom + Application.GetRealHeight(32); + menuFram.AddView(cornerBottomFram); + + typeMultiFramLayout = new TypeMultiFramLayout(); + typeMultiFramLayout.multiFramLayout.Y = menuFram.Bottom + Application.GetRealHeight(32); + typeMultiFramLayout.AddView(cornerBottomFram); - MenuFramLayout menuFram = new MenuFramLayout - { - Y = singleFramLayout.Bottom + Application.GetRealHeight(32), - Gravity = Gravity.CenterHorizontal, - }; - menuFram.AddView(payerFramLayout); - - - FrameLayout multiFramLayout = new FrameLayout - { - BackgroundColor = MusicColor.ViewColor, - X=Application.GetRealWidth(16), - Y = menuFram.Bottom+Application.GetRealHeight(32), - Width = Application.GetRealWidth(311), - Height = Application.GetRealHeight(40), - Radius = (uint)Application.GetRealHeight(20), - }; - payerFramLayout.AddChidren(multiFramLayout); - - - FrameLayout leftFramLayout = new FrameLayout - { - X = Application.GetRealWidth(16), - Gravity = Gravity.CenterVertical, - Width = Application.GetRealWidth(139), - Height = Application.GetRealHeight(23), - Radius = (uint)Application.GetRealHeight(20), - - }; - multiFramLayout.AddChidren(leftFramLayout); - - Button btnBottonLeftImage = new Button - { - Width = Application.GetRealWidth(16), - Height = Application.GetRealWidth(16), - UnSelectedImagePath = "AksIcon/shixuqi.png", - Gravity = Gravity.CenterVertical, - Name = "btnBottonLeftImage", - }; - leftFramLayout.AddChidren(btnBottonLeftImage); - Button btnBottonName = new Button - { - X = btnBottonLeftImage.Right + Application.GetRealWidth(4), - Width = Application.GetRealWidth(100), - Height = Application.GetRealHeight(23), - TextID = StringId.shixuqi, - TextSize = TextSize.Text16, - TextColor = MusicColor.TextColor, - TextAlignment = TextAlignment.CenterLeft, - Gravity = Gravity.CenterVertical, - IsMoreLines = true, - Name = "btnName", - }; - leftFramLayout.AddChidren(btnBottonName); - - - FrameLayout lineFramLayout = new FrameLayout - { - BackgroundColor = MusicColor.TextColor, - X = leftFramLayout.Right, - Y =Application.GetRealHeight(10), - Width = Application.GetRealWidth(1), - Height = Application.GetRealHeight(20), - }; - multiFramLayout.AddChidren(lineFramLayout); - - - FrameLayout rightFramLayout = new FrameLayout - { - X =lineFramLayout.Right, - Gravity = Gravity.CenterVertical, - Width = Application.GetRealWidth(138), - Height = Application.GetRealHeight(23), - - }; - multiFramLayout.AddChidren(rightFramLayout); - - Button btnBottonRightImage = new Button - { - Width = Application.GetRealWidth(16), - Height = Application.GetRealWidth(16), - UnSelectedImagePath = "AksIcon/xuanze.png", - Gravity = Gravity.CenterRight, - Name = "btnBottonLeftImage", - }; - rightFramLayout.AddChidren(btnBottonRightImage); - - Button btnBottonRightName = new Button - { - X = btnBottonLeftImage.Right + Application.GetRealWidth(4), - Width = Application.GetRealWidth(100), - Height = Application.GetRealHeight(23), - TextID = StringId.bofangqi, - TextSize = TextSize.Text16, - TextColor = MusicColor.TextColor, - TextAlignment = TextAlignment.CenterRight, - Gravity = Gravity.CenterVertical, - IsMoreLines = true, - Name = "btnName", - }; - rightFramLayout.AddChidren(btnBottonRightName); - - - - - - - - - - //PayerFramLayout payerFramLayout = new PayerFramLayout(343, 364); - //payerFramLayout.Y = cornerFram.Bottom + Application.GetRealHeight(16); - //payerFramLayout.X = Application.GetRealWidth(16); - //payerFramLayout.LoadPage(); - //this.AddChidren(payerFramLayout); this.AdjustRealHeight(20); - } - + } } -- Gitblit v1.8.0