| | |
| | | Y = Application.GetRealHeight(466), |
| | | Width = Application.GetMinRealAverage(32), |
| | | Height = Application.GetMinRealAverage(32), |
| | | //UnSelectedImagePath = "Public/PowerClose.png", |
| | | UnSelectedImagePath = "Public/PowerOpen.png", |
| | | UnSelectedImagePath = "FunctionIcon/Light/LightScene/gp_all_on.png", |
| | | }; |
| | | controlView.AddChidren(btnOn); |
| | | var btnOnText = new Button() |
| | | { |
| | | X = Application.GetRealWidth(100-9), |
| | | Y = Application.GetRealHeight(500), |
| | | Width = Application.GetMinRealAverage(50), |
| | | Height = Application.GetMinRealAverage(32), |
| | | TextColor = CSS_Color.TextualColor, |
| | | TextSize = CSS_FontSize.TextFontSize, |
| | | TextAlignment = TextAlignment.Center, |
| | | TextID = StringId.Open, |
| | | }; |
| | | controlView.AddChidren(btnOnText); |
| | | |
| | | |
| | | var btnOff = new Button() |
| | | { |
| | |
| | | Y = Application.GetRealHeight(466), |
| | | Width = Application.GetMinRealAverage(32), |
| | | Height = Application.GetMinRealAverage(32), |
| | | UnSelectedImagePath = "Public/PowerClose.png", |
| | | //UnSelectedImagePath = "Public/PowerOpen.png", |
| | | UnSelectedImagePath = "FunctionIcon/Light/LightScene/gp_all_off.png", |
| | | }; |
| | | controlView.AddChidren(btnOff); |
| | | var btnOffText = new Button() |
| | | { |
| | | X = Application.GetRealWidth(180 - 9), |
| | | Y = Application.GetRealHeight(500), |
| | | Width = Application.GetMinRealAverage(50), |
| | | Height = Application.GetMinRealAverage(32), |
| | | TextColor = CSS_Color.TextualColor, |
| | | TextSize = CSS_FontSize.TextFontSize, |
| | | TextAlignment = TextAlignment.Center, |
| | | TextID = StringId.Close, |
| | | }; |
| | | controlView.AddChidren(btnOffText); |
| | | |
| | | |
| | | |
| | | btnOn.MouseUpEventHandler = (sender, e) => |
| | | { |
| | | var d = new Dictionary<string, string>(); |
| | |
| | | d.Add(FunctionAttributeKey.OnOff, "off"); |
| | | function.Control(d); |
| | | }; |
| | | btnOnText.MouseUpEventHandler = (sender, e) => |
| | | { |
| | | var d = new Dictionary<string, string>(); |
| | | d.Add(FunctionAttributeKey.OnOff, "on"); |
| | | function.Control(d); |
| | | }; |
| | | |
| | | btnOffText.MouseUpEventHandler = (sender, e) => |
| | | { |
| | | var d = new Dictionary<string, string>(); |
| | | d.Add(FunctionAttributeKey.OnOff, "off"); |
| | | function.Control(d); |
| | | }; |
| | | |
| | | |
| | | if (hadRGB) |