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
using System;
using System.Collections.Generic;
using System.Text;
 
namespace Shared.Phone.UserCenter
{
    /// <summary>
    /// 做成一个位于右边的开关控件,规格:180 X 120
    /// </summary>
    public class SwichControl : ButtonCommon
    {
        /// <summary>
        /// 做成一个位于Rowlayout右边的开关控件(上下居中),规格:180 X 120
        /// </summary>
        public SwichControl()
        {
            this.Width = Application.GetMinRealAverage(180);
            this.Height = Application.GetMinRealAverage(120);
            this.X = Application.GetRealWidth(850);
            this.UnSelectedImagePath = "Item/Switch.png";
            this.SelectedImagePath = "Item/SwitchSelected.png";
            this.Gravity = Gravity.CenterVertical;
        }
    }
}