using System;
using HDL_ON.UI.Music;
using Shared;
namespace HDL_ON.UI.UI2.FuntionControlView.Aks.CommonView
{
public class NumberFrameLayout
{
public NumberFrameLayout()
{
}
public FrameLayout layout = new FrameLayout
{
Height = Application.GetRealHeight(368),
Width = Application.GetRealWidth(343),
Radius = (uint)Application.GetRealHeight(17),
BackgroundColor = MusicColor.WhiteColor,
};
Button btn1 = new Button
{
Width = Application.GetRealWidth(78),
Height = Application.GetRealHeight(84),
Text = "1",
TextSize = TextSize.Text20,
TextColor = MusicColor.TextColor,
TextAlignment = TextAlignment.Center,
IsBold = true,
};
Button btn2 = new Button
{
Width = Application.GetRealWidth(78),
Height = Application.GetRealHeight(84),
Text = "2",
TextSize = TextSize.Text20,
TextColor = MusicColor.TextColor,
TextAlignment = TextAlignment.Center,
IsBold = true,
};
Button btn3 = new Button
{
Width = Application.GetRealWidth(78),
Height = Application.GetRealHeight(84),
Text = "3",
TextSize = TextSize.Text20,
TextColor = MusicColor.TextColor,
TextAlignment = TextAlignment.Center,
IsBold = true,
};
Button btn4 = new Button
{
Width = Application.GetRealWidth(78),
Height = Application.GetRealHeight(84),
Text = "4",
TextSize = TextSize.Text20,
TextColor = MusicColor.TextColor,
TextAlignment = TextAlignment.Center,
IsBold = true,
};
Button btn5 = new Button
{
Width = Application.GetRealWidth(78),
Height = Application.GetRealHeight(84),
Text = "5",
TextSize = TextSize.Text20,
TextColor = MusicColor.TextColor,
TextAlignment = TextAlignment.Center,
IsBold = true,
};
Button btn6 = new Button
{
Width = Application.GetRealWidth(78),
Height = Application.GetRealHeight(84),
Text = "6",
TextSize = TextSize.Text20,
TextColor = MusicColor.TextColor,
TextAlignment = TextAlignment.Center,
IsBold = true,
};
Button btn7 = new Button
{
Width = Application.GetRealWidth(78),
Height = Application.GetRealHeight(84),
Text = "7",
TextSize = TextSize.Text20,
TextColor = MusicColor.TextColor,
TextAlignment = TextAlignment.Center,
IsBold = true,
};
Button btn8 = new Button
{
Width = Application.GetRealWidth(78),
Height = Application.GetRealHeight(84),
Text = "8",
TextSize = TextSize.Text20,
TextColor = MusicColor.TextColor,
TextAlignment = TextAlignment.Center,
IsBold = true,
};
Button btn9 = new Button
{
Width = Application.GetRealWidth(78),
Height = Application.GetRealHeight(84),
Text = "9",
TextSize = TextSize.Text20,
TextColor = MusicColor.TextColor,
TextAlignment = TextAlignment.Center,
IsBold = true,
};
Button btn0 = new Button
{
Width = Application.GetRealWidth(78),
Height = Application.GetRealHeight(84),
Text = "0",
TextSize = TextSize.Text20,
TextColor = MusicColor.TextColor,
TextAlignment = TextAlignment.Center,
IsBold = true,
};
Button btn = new Button
{
Width = Application.GetRealWidth(78),
Height = Application.GetRealHeight(84),
Text = "-/--",
TextSize = TextSize.Text20,
TextColor = MusicColor.TextColor,
TextAlignment = TextAlignment.Center,
IsBold = true,
};
ButtonFramLayout pdjiaFramLayout = new ButtonFramLayout();
ButtonFramLayout pdjianFramLayout = new ButtonFramLayout();
///
/// 添加布局
///
///
public void AddView(FrameLayout parent)
{
parent.AddChidren(layout);
layout.AddChidren(btn1);
layout.AddChidren(btn2);
layout.AddChidren(btn3);
layout.AddChidren(btn4);
layout.AddChidren(btn5);
layout.AddChidren(btn6);
layout.AddChidren(btn7);
layout.AddChidren(btn8);
layout.AddChidren(btn9);
layout.AddChidren(btn0);
layout.AddChidren(btn);
layout.AddChidren(pdjiaFramLayout);
layout.AddChidren(pdjianFramLayout);
btn1.Y = Application.GetRealHeight(16);
btn1.X = Application.GetRealWidth(16);
btn2.Y = Application.GetRealHeight(16);
btn2.X = btn1.Right;
btn3.Y = Application.GetRealHeight(16);
btn3.X = btn2.Right;
pdjiaFramLayout.AddImageView();
pdjiaFramLayout.AddNameView();
pdjiaFramLayout.Y = Application.GetRealHeight(16);
pdjiaFramLayout.GetImageButton().Height = Application.GetRealHeight(32);
pdjiaFramLayout.GetImageButton().Width = Application.GetRealWidth(32);
pdjiaFramLayout.GetImageButton().UnSelectedImagePath = "AksIcon/pindao1.png";
pdjiaFramLayout.GetNameButton().TextID = StringId.pindaojia;
pdjiaFramLayout.X = btn3.Right;
btn4.Y = btn1.Bottom;
btn4.X = Application.GetRealWidth(16);
btn5.Y = btn2.Bottom;
btn5.X = btn4.Right;
btn6.Y = btn3.Bottom;
btn6.X = btn5.Right;
pdjianFramLayout.AddImageView();
pdjianFramLayout.AddNameView();
pdjianFramLayout.Y = pdjiaFramLayout.Bottom;
pdjianFramLayout.GetImageButton().Height = Application.GetRealHeight(32);
pdjianFramLayout.GetImageButton().Width = Application.GetRealWidth(32);
pdjianFramLayout.GetImageButton().UnSelectedImagePath = "AksIcon/pindao2.png";
pdjianFramLayout.GetNameButton().TextID = StringId.pindaojian;
pdjianFramLayout.X = btn6.Right;
btn7.Y = btn6.Bottom;
btn7.X = Application.GetRealWidth(16);
btn8.Y = btn5.Bottom;
btn8.X = btn7.Right;
btn9.Y = btn6.Bottom;
btn9.X = btn8.Right;
btn.Y = pdjianFramLayout.Bottom;
btn.X = btn9.Right;
btn0.Y = btn8.Bottom;
btn0.X = Application.GetRealWidth(16 + 78);
}
}
}