DALi C# binding - Adding Animation constructor to accept duration in milli seconds 21/93421/3
authorRavi Nanjundappa <nravi.n@samsung.com>
Tue, 25 Oct 2016 14:26:32 +0000 (19:56 +0530)
committerRavi Nanjundappa <nravi.n@samsung.com>
Tue, 25 Oct 2016 14:28:40 +0000 (19:58 +0530)
Inserted the code for Animation constructor which accept integer value for duration in milli seconds.
Now, _animation = new Animation(10000); will create Animation object with duration of 1000 ms (1s).
We can still use _animation = new Animation(1.0f); to create the same.
We can also use _animation.DurationMillSecs = 10000; // 10 ms

Change-Id: Ie194280a9043f395d967f12b8835c66ae22c627f
Signed-off-by: Ravi Nanjundappa <nravi.n@samsung.com>
plugins/dali-swig/SWIG/events/animation-event.i

index 4690317..0581d4e 100644 (file)
@@ -185,6 +185,19 @@ using System.Runtime.InteropServices;
     }
   }
 
+  public int DurationMilliSecs
+  {
+    set
+    {
+      SetDuration(value/1000);
+    }
+    get
+    {
+      int ret = (int) GetDuration() * 1000;
+      return ret;
+    }
+  }
+
   public AlphaFunction DefaultAlphaFunction
   {
     set