2 * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
4 * Licensed under the Apache License, Version 2.0 (the License);
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an AS IS BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
18 using System.Collections.Generic;
21 using System.Threading.Tasks;
23 namespace ElmSharp.Test
25 class RadioTest1 : TestCaseBase
27 public override string TestName => "RadioTest1";
28 public override string TestDescription => "To test basic operation of Radio";
32 public override void Run(Window window)
34 Conformant conformant = new Conformant(window);
36 Box box = new Box(window);
37 conformant.SetContent(box);
40 Radio rd1 = new Radio(window)
43 Text = "<span color=#ffffff>Value #1</span>",
49 Radio rd2 = new Radio(window)
52 Text = "<span color=#ffffff>Value #2</span>",
58 Radio rd3 = new Radio(window)
61 Text = "<span color=#ffffff>Value #3</span>",
70 rd1.ValueChanged += OnRadioValueChanged;
71 rd2.ValueChanged += OnRadioValueChanged;
72 rd3.ValueChanged += OnRadioValueChanged;
74 _lb1 = new Label(window)
93 void OnRadioValueChanged(object sender, EventArgs e)
95 _lb1.Text = string.Format("Value Changed: {0}", ((Radio)sender).GroupValue);
96 _lb1.EdjeObject["elm.text"].TextStyle = "DEFAULT='color=#ffffff'";