2 using Tizen.NUI.BaseComponents;
3 using Tizen.NUI.Components;
5 namespace Tizen.NUI.Samples
7 public class ControlSample : IExample
10 private Control control;
12 public void Activate()
14 Window window = NUIApplication.GetDefaultWindow();
19 BackgroundColor = new Color(0.8f, 0.8f, 0.8f, 0.6f),
20 ParentOrigin = ParentOrigin.Center,
21 PivotPoint = PivotPoint.Center,
22 PositionUsesPivotPoint = true,
26 control = new Control()
28 Size = new Size(100, 100),
29 BackgroundColor = Color.Blue,
30 ParentOrigin = ParentOrigin.Center,
31 PivotPoint = PivotPoint.Center,
32 PositionUsesPivotPoint = true,
33 BoxShadow = new Shadow(0, new Color(0.2f, 0.2f, 0.2f, 0.3f), new Vector2(5, 5)),
35 CornerRadiusPolicy = VisualTransformPolicyType.Relative,
40 var animation = new Animation(2000);
41 animation.AnimateTo(control, "SizeWidth", 200, 0, 1000);
42 animation.AnimateTo(control, "SizeWidth", 100, 1000, 2000);
43 animation.Looping = true;
47 public void Deactivate()
51 NUIApplication.GetDefaultWindow().Remove(root);