黄学彪
2020-07-06 4c330a0f78ad8215112ebdbcb5ff0f2729914b49
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
using System;
using Shared.Common;
using Shared.R;
namespace Shared.Phone.Device.Logic.LogicView
{
    public class Addview
    {
        public FrameLayout frameLayout = new FrameLayout
        {
            Height = Application.GetRealHeight(160),
            BackgroundColor=ZigbeeColor.Current.LogicBlankBackgroundColor,
        };
        public Button lineBtn = new Button
        {
            //Y = Application.GetRealHeight(155),
            Width = Application.GetRealWidth(1080-58-58),
            Height =1,
            X = Application.GetRealWidth(58),
            BackgroundColor = ZigbeeColor.Current.LogicRowLayoutLineColor,
        };
        public Button titleBtn = new Button
        {
            Y = Application.GetRealHeight(30 + 35),
            X = Application.GetRealWidth(58),
            Text = Language.StringByID(MyInternationalizationString.ifcondition),
            TextAlignment = TextAlignment.CenterLeft,
            TextColor = ZigbeeColor.Current.LogicTextBlackColor,
            Width = Application.GetRealWidth(300),
            Height = Application.GetRealHeight(60),
            TextSize = 15,
            Gravity = Gravity.CenterVertical,
        };
 
        public Button iconBtn = new Button
        {
 
            Width = Application.GetMinRealAverage(58),
            Height = Application.GetMinRealAverage(58),
            UnSelectedImagePath = "ZigeeLogic/add.png",
            X = Application.GetRealWidth(1080 - 58-58),
            Y = Application.GetRealHeight(30 + 36),
            Visible=false,
        };
 
        public Button switchBtn = new Button
        {
            Width = Application.GetMinRealAverage(104),
            Height = Application.GetMinRealAverage(63),
            UnSelectedImagePath = "ZigeeLogic/logicclose.png",
            SelectedImagePath = "ZigeeLogic/logicopen.png",
            X = Application.GetRealWidth(1080 - 58 - 104),
            Y = Application.GetRealHeight(30 + 33),
            Visible = false,
        };
        /// <summary>
        /// 加大点击热键
        /// </summary>
        public Button clickBtn = new Button
        {
 
            Width = Application.GetRealWidth(58 +58+40),
            Height = Application.GetRealHeight(160),
            X = Application.GetRealWidth(1080 - 58 - 58-40),
        };
 
        public FrameLayout AddDeviceView()
        {
            lineBtn.Y = frameLayout.Height - 1;
            frameLayout.AddChidren(lineBtn);
            frameLayout.AddChidren(titleBtn);
            frameLayout.AddChidren(iconBtn);
            frameLayout.AddChidren(switchBtn);
            frameLayout.AddChidren(clickBtn);
            return frameLayout;
        }
 
    }
}