From e379994f2754481fa5c9ac4affbd64908b0918bd Mon Sep 17 00:00:00 2001
From: WJC <wjc@hdlchina.com.cn>
Date: 星期一, 09 十二月 2019 15:01:48 +0800
Subject: [PATCH] 2019-12-09-3
---
ZigbeeApp/Shared/Phone/Device/CommonForm/CompleteButton.cs | 38 +++++++++++++++++++++++++++-----------
1 files changed, 27 insertions(+), 11 deletions(-)
diff --git a/ZigbeeApp/Shared/Phone/Device/CommonForm/CompleteButton.cs b/ZigbeeApp/Shared/Phone/Device/CommonForm/CompleteButton.cs
old mode 100644
new mode 100755
index fd894fd..1745281
--- a/ZigbeeApp/Shared/Phone/Device/CommonForm/CompleteButton.cs
+++ b/ZigbeeApp/Shared/Phone/Device/CommonForm/CompleteButton.cs
@@ -6,28 +6,44 @@
/// Complete button.
/// <para>榛樿鏂囧瓧锛� 瀹屾垚 </para>
/// <para>鐧借壊瀛椾綋</para>
- /// <para>钃濊壊鑳屾櫙</para>
+ /// <para>榛戣壊鑳屾櫙</para>
/// <para>鏂囧瓧灞呬腑</para>
/// <para>榛樿瀛楀彿澶у皬</para>
/// </summary>
public class CompleteButton:Button
{
- private readonly int Button_Height = 110;
- private readonly int Button_Width = 750;
- private readonly int Button_Y = CommonPage.AppRealHeight - 300;
/// <summary>
- /// Initializes a new instance of the <see cref="T:Shared.Phone.Device.CommonForm.CompleteButton"/> class.
+ /// CompleteButton
/// </summary>
- public CompleteButton()
+ /// <param name="y"></param>
+ /// <param name="width"></param>
+ /// <param name="height"></param>
+ public CompleteButton(int y, int width, int height)
{
+ this.Y = Application.GetRealHeight(y);
+ this.Width = Application.GetRealWidth(width);
+ this.Height = Application.GetRealHeight(height);
TextID = R.MyInternationalizationString.Complete;
- BackgroundColor = ZigbeeColor.Current.GXCButtonBlueColor;
+ BackgroundColor = ZigbeeColor.Current.GXCButtonBlackSelectedColor;
TextColor = ZigbeeColor.Current.GXCTextWhiteColor;
- Height = Application.GetRealHeight(Button_Height);
- Width = Application.GetRealWidth(Button_Width);
Gravity = Gravity.CenterHorizontal;
- Radius = (uint)Application.GetRealHeight(Button_Height/2);
- Y = Application.GetRealHeight(Button_Y);
+ Radius = (uint)Application.GetRealHeight(height / 2);
+ }
+ /// <summary>
+ /// SetTitle
+ /// </summary>
+ /// <param name="title"></param>
+ public void SetTitle(string title)
+ {
+ Text = title;
+ }
+ /// <summary>
+ /// SetTitle
+ /// </summary>
+ /// <param name="title"></param>
+ public void SetTitle(int title)
+ {
+ SetTitle(Language.StringByID(title));
}
}
}
--
Gitblit v1.8.0