wxr
2024-09-22 4e95d87dec43de5f7e8bd6ef579053c1fb44414d
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
using System;
using System.Drawing.Printing;
using HDL_ON.Entity;
using HDL_ON.UI.Music;
using Shared;
 
namespace HDL_ON.UI.Music
{
    public class TopView
    {
        #region 最上面那块控件
        /// <summary>
        /// 最上面块View
        /// </summary>
        public FrameLayout fLayout = new FrameLayout
        {
            Y = Application.GetRealHeight(10),
            BackgroundColor = MusicColor.TopViewColor,
            Height = Application.GetRealHeight(64),
            Width=Application.GetRealWidth(375),
        };
        /// <summary>
        /// 标题Btn
        /// </summary>
        public Button topNameBtn = new Button
        {
            TextSize = TextSize.Text18,
            TextColor = MusicColor.Text18Color,
            Width = Application.GetRealWidth(140),
            Height = Application.GetRealHeight(25),
            Y = Application.GetRealHeight(30),
            X = Application.GetRealWidth(120)
        };
        /// <summary>
        /// 后退Btn
        /// </summary>
        public Button backBtn = new Button
        {
            Width = Application.GetRealWidth(12),
            Height = Application.GetRealWidth(20),
            X = Application.GetRealWidth(16),
            Y = Application.GetRealHeight(32),
            UnSelectedImagePath = "MusicIcon/MusicBack.png",
           
        };
 
        public Button lineBtn = new Button
        {
            Width = Application.GetRealWidth(375),
            Height = 1,
            BackgroundColor = MusicColor.LineColor,
 
        };
        /// <summary>
        /// 设置图标Btn
        /// </summary>
        public Button setBtn = new Button
        {
            Y = Application.GetRealHeight(29),
            X = Application.GetRealWidth(337),
            Width = Application.GetMinRealAverage(28),
            Height = Application.GetMinRealAverage(28),
            UnSelectedImagePath = "MusicIcon/set.png",
            Visible=false,
        };
        /// <summary>
        /// 增加热键大小Btn
        /// </summary>
        public Button clickBackBtn = new Button
        {
            Width = Application.GetRealWidth(16+12+16+50),
            Height = Application.GetRealHeight(64),
        };
        /// <summary>
        /// 设置图标增加热键大小
        /// </summary>
        public Button clickSetBtn = new Button
        {
            X = Application.GetRealWidth(337 - 37),
            Width = Application.GetRealWidth(28 + 37),
            Height = Application.GetRealWidth(28 + 7 + 29),
        };
        /// <summary>
        /// 最上面的那块方法
        /// </summary>
        /// <returns></returns>
        public FrameLayout TopFLayoutView()
        {
            fLayout.AddChidren(topNameBtn);
            fLayout.AddChidren(backBtn);
            lineBtn.Y = fLayout.Height - 1;
            fLayout.AddChidren(lineBtn);
            fLayout.AddChidren(setBtn);
            fLayout.AddChidren(clickBackBtn);
            fLayout.AddChidren(clickSetBtn);
 
            return fLayout;
        }
 
        /// <summary>
        /// 最上面的那块方法
        /// </summary>
        /// <returns></returns>
        public FrameLayout TopFLayoutView2()
        {
            fLayout.AddChidren(topNameBtn);
            fLayout.AddChidren(backBtn);
            lineBtn.Y = fLayout.Height - 1;
            fLayout.AddChidren(lineBtn);
            fLayout.AddChidren(setBtn);
            fLayout.AddChidren(clickBackBtn);
            fLayout.AddChidren(clickSetBtn);
 
 
            var btnSetting = new Button()
            {
                X = Application.GetRealWidth(337),
                Y = Application.GetRealHeight(28),
                Width = Application.GetMinRealAverage(32),
                Height = Application.GetMinRealAverage(32),
                UnSelectedImagePath = "Public/FuncInfoSetIcon.png",
            };
            fLayout.AddChidren(btnSetting);
 
            btnSetting.MouseUpEventHandler = (sender, e) =>
            {
                var infoView = new FunctionBaseInfoSetPage(new Entity.Function() { spk = SPK.LinphoneXiMo }, () => { });
                MainPage.BasePageView.AddChidren(infoView);
                infoView.LoadPage();
                MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1;
            };
 
            return fLayout;
        }
        #endregion
    }
}