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 ProgressBarTest2 : TestCaseBase
27 public override string TestName => "ProgressBarTest2";
28 public override string TestDescription => "To test basic operation of ProgressBar";
30 public override void Run(Window window)
32 Conformant conformant = new Conformant(window);
34 Box table = new Box(window)
36 BackgroundColor = Color.White,
38 conformant.SetContent(table);
41 ProgressBar pb1 = new ProgressBar(window)
43 Text = "ProgressBar Test",
44 Style = "process_medium",
52 Label lb1 = new Label(window)
60 Button bt1 = new Button(window)
62 Text = "Increase Value",
69 bt1.Clicked += (s, e) =>
71 Random rand = new Random(DateTime.UtcNow.Millisecond);
72 pb1.Color = new Color(rand.Next(255), rand.Next(255), rand.Next(255));
73 lb1.Text = pb1.Color.ToString();
76 Button bt2 = new Button(window)
85 bt2.Clicked += (s, e) =>
87 var map = new EvasMap(4);
89 map.PopulatePoints(g, 0);
90 map.Zoom(2, 2, g.X, g.Y);
92 pb1.IsMapEnabled = true;