HDL Home App 第二版本 旧平台金堂用 正在使用
黄学彪
2019-10-28 8b4d79ca03495e522a1953e04ca17527f33c853a
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
using System;
using Shared.Common;
using ZigBee.Device;
 
namespace Shared.Phone.UserCenter.DeviceBind
{
    public class BindCommonLayout : FrameLayout
    {
        public BindCommonLayout()
        {
 
        }
        #region ◆ 变量申明__________________________
        public FrameLayout topFrameLayout = new FrameLayout { Height = Application.GetRealHeight(184), BackgroundColor = ZigbeeColor.Current.XMTopFrameLayout };
        public FrameLayout midFrameLayout = new FrameLayout { Height = Application.GetRealHeight(1921 - 184), BackgroundColor = ZigbeeColor.Current.XMMidFrameLayout };
        public FrameLayout bottomRadiusFrameLayout = new FrameLayout()
        {
            Height = Application.GetRealHeight(100),
            Y = Application.GetRealHeight(930),
            Radius = 17,
            BackgroundColor = ZigbeeColor.Current.XMWhite,
        };
        public FrameLayout titleFrameLayout = new FrameLayout
        {
            Y = Application.GetRealHeight(92),
            Height = Application.GetRealHeight(69),
        };
        public Button btnTitle = new Button
        {
            TextAlignment = TextAlignment.CenterLeft,
            TextColor = Shared.Common.ZigbeeColor.Current.XMTopTitleText,
            X = Application.GetRealWidth(161),
            Width = Application.GetRealWidth(1080 - 161),
            Height = Application.GetRealWidth(69),
            TextSize = 17,
        };
        public FrameLayout btnBackFrameLayout = new FrameLayout
        {
            X = Application.GetRealWidth(58),
            Height = Application.GetRealHeight(58),
            Width = Application.GetRealWidth(58),
        };
 
        public Button btnBack = new Button
        {
            Height = Application.GetRealHeight(51),
            Width = Application.GetRealWidth(30),
            UnSelectedImagePath = "DoorLock/Left.png",
        };
 
        public Button btnTitleLine = new Button
        {
            Y = Application.GetRealHeight(181),
            Height = 1,
            BackgroundColor = Shared.Common.ZigbeeColor.Current.XMTitleLine,
        };
        #endregion
 
        /// <summary>
        /// 门锁顶部布局
        /// </summary>
        /// <param name="frameLayout"></param>
        public void TopFrameLayout(FrameLayout frameLayout, string titleText)
        {
            this.AddChidren(topFrameLayout);
            topFrameLayout.AddChidren(titleFrameLayout);
            topFrameLayout.AddChidren(btnTitleLine);
            titleFrameLayout.AddChidren(btnTitle);
            btnTitle.Text = titleText;
            titleFrameLayout.AddChidren(btnBackFrameLayout);
            btnBackFrameLayout.AddChidren(btnBack);
        }
        /// <summary>
        /// 门锁中部布局
        /// </summary>
        /// <param name="frameLayout"></param>
        public void MidFrameLayout(FrameLayout frameLayout)
        {
            //midFrameLayout.BackgroundColor = Shared.Common.ZigbeeColor.Current.GXCBackgroundColor;
            midFrameLayout.Y = topFrameLayout.Bottom;
            this.AddChidren(midFrameLayout);
        }
 
        /// <summary>
        /// 门锁底部布局
        /// </summary>
        /// <param name="frameLayout"></param>
        public void BottomFrameLayout(FrameLayout frameLayout)
        {
            var bottomFrameLayout1 = new FrameLayout()
            {
                Height = Application.GetRealHeight(806 - 50),
                Y = Application.GetRealHeight(930 + 48),
                BackgroundColor = ZigbeeColor.Current.XMWhite,
            };
            this.midFrameLayout.AddChidren(bottomFrameLayout1);
        }
    }
}