dali 1.2.28 version upgrade
[platform/core/csapi/nui.git] / Tizen.NUI / src / public / Animation.cs
1 // Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved\r
2 // PROPRIETARY/CONFIDENTIAL \r
3 // This software is the confidential and proprietary\r
4 // information of SAMSUNG ELECTRONICS ("Confidential Information"). You shall\r
5 // not disclose such Confidential Information and shall use it only in\r
6 // accordance with the terms of the license agreement you entered into with\r
7 // SAMSUNG ELECTRONICS. SAMSUNG make no representations or warranties about the\r
8 // suitability of the software, either express or implied, including but not\r
9 // limited to the implied warranties of merchantability, fitness for a\r
10 // particular purpose, or non-infringement. SAMSUNG shall not be liable for any\r
11 // damages suffered by licensee as a result of using, modifying or distributing\r
12 // this software or its derivatives.\r
13 \r
14 // Copyright (c) 2017 Samsung Electronics Co., Ltd.\r
15 //\r
16 // Licensed under the Apache License, Version 2.0 (the "License");\r
17 // you may not use this file except in compliance with the License.\r
18 // You may obtain a copy of the License at\r
19 //\r
20 // http://www.apache.org/licenses/LICENSE-2.0\r
21 //
22 // Unless required by applicable law or agreed to in writing, software\r
23 // distributed under the License is distributed on an "AS IS" BASIS,\r
24 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
25 // See the License for the specific language governing permissions and\r
26 // limitations under the License.\r
27 //
28
29 // This File has been auto-generated by SWIG and then modified using DALi Ruby Scripts\r
30 // Some have been manually changed\r
31 \r
32 namespace Tizen.NUI\r
33 {\r
34 \r
35     using System;\r
36     using System.Runtime.InteropServices;\r
37 \r
38     public class Animation : BaseHandle\r
39     {\r
40         private global::System.Runtime.InteropServices.HandleRef swigCPtr;\r
41 \r
42         internal Animation(global::System.IntPtr cPtr, bool cMemoryOwn) : base(NDalicPINVOKE.Animation_SWIGUpcast(cPtr), cMemoryOwn)\r
43         {\r
44             swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);\r
45         }\r
46 \r
47         internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Animation obj)\r
48         {\r
49             return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;\r
50         }\r
51 \r
52         ~Animation()\r
53         {\r
54             DisposeQueue.Instance.Add(this);\r
55         }\r
56 \r
57         public override void Dispose()\r
58         {\r
59             if (!Stage.IsInstalled())\r
60             {\r
61                 DisposeQueue.Instance.Add(this);\r
62                 return;\r
63             }\r
64 \r
65             lock (this)\r
66             {\r
67                 if (swigCPtr.Handle != global::System.IntPtr.Zero)\r
68                 {\r
69                     if (swigCMemOwn)\r
70                     {\r
71                         swigCMemOwn = false;\r
72                         NDalicPINVOKE.delete_Animation(swigCPtr);\r
73                     }\r
74                     swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);\r
75                 }\r
76                 global::System.GC.SuppressFinalize(this);\r
77                 base.Dispose();\r
78             }\r
79         }\r
80 \r
81 \r
82 \r
83         private AnimationFinishedEventCallbackType _animationFinishedEventCallback;\r
84         [UnmanagedFunctionPointer(CallingConvention.StdCall)]\r
85         private delegate void AnimationFinishedEventCallbackType(IntPtr data);\r
86         private event EventHandler _animationFinishedEventHandler;\r
87 \r
88         /**\r
89         * @brief Create an initialized Animation.\r
90         *\r
91         * The animation will not loop.\r
92         * The default end action is "Bake".\r
93         * The default Alpha function is linear.\r
94         * @since 1.0.0\r
95         * @param [in] durationmSeconds The duration in milli seconds (int).\r
96         * @return A handle to a newly allocated Dali resource.\r
97         * @pre DurationmSeconds must be greater than zero.\r
98         */\r
99         public Animation(int durationMilliSeconds) : this(NDalicPINVOKE.Animation_New((float)durationMilliSeconds / 1000.0f), true)\r
100         {\r
101             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
102         }\r
103 \r
104         /**\r
105         * @brief Event for Finished signal which can be used to subscribe/unsubscribe the event handler\r
106         * Finished signal is emitted when an Animation's animations have finished.\r
107         */\r
108         public event EventHandler Finished\r
109         {\r
110             add\r
111             {\r
112                 if (_animationFinishedEventHandler == null)\r
113                 {\r
114                     _animationFinishedEventCallback = OnFinished;\r
115                     FinishedSignal().Connect(_animationFinishedEventCallback);\r
116                 }\r
117 \r
118                 _animationFinishedEventHandler += value;\r
119             }\r
120             remove\r
121             {\r
122                 if (_animationFinishedEventHandler != null)\r
123                 {\r
124                     FinishedSignal().Disconnect(_animationFinishedEventCallback);\r
125                 }\r
126 \r
127                 _animationFinishedEventHandler -= value;\r
128             }\r
129         }\r
130         private void OnFinished(IntPtr data)\r
131         {\r
132             if (_animationFinishedEventHandler != null)\r
133             {\r
134                 //here we send all data to user event handlers\r
135                 _animationFinishedEventHandler(this, null);\r
136             }\r
137         }\r
138 \r
139 \r
140         public static Animation GetAnimationFromPtr(global::System.IntPtr cPtr)\r
141         {\r
142             Animation ret = new Animation(cPtr, false);\r
143             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
144             return ret;\r
145         }\r
146 \r
147         private float MilliSecondsToSeconds(int millisec)\r
148         {\r
149             return (float)millisec / 1000.0f;\r
150         }\r
151 \r
152         private int SecondsToMilliSeconds(float sec)\r
153         {\r
154             return (int)(sec * 1000);\r
155         }\r
156 \r
157         public int Duration\r
158         {\r
159             set\r
160             {\r
161                 SetDuration(MilliSecondsToSeconds(value));\r
162             }\r
163             get\r
164             {\r
165                 return SecondsToMilliSeconds(GetDuration());\r
166             }\r
167         }\r
168 \r
169         public AlphaFunction DefaultAlphaFunction\r
170         {\r
171             set\r
172             {\r
173                 SetDefaultAlphaFunction(value);\r
174             }\r
175             get\r
176             {\r
177                 AlphaFunction ret = GetDefaultAlphaFunction();\r
178                 return ret;\r
179             }\r
180         }\r
181 \r
182         public States State\r
183         {\r
184             get\r
185             {\r
186                 return GetState();\r
187             }\r
188         }\r
189 \r
190         public int LoopCount\r
191         {\r
192             set\r
193             {\r
194                 SetLoopCount(value);\r
195             }\r
196             get\r
197             {\r
198                 int ret = GetLoopCount();\r
199                 return ret;\r
200             }\r
201         }\r
202 \r
203         public bool Looping\r
204         {\r
205             set\r
206             {\r
207                 SetLooping(value);\r
208             }\r
209             get\r
210             {\r
211                 bool ret = IsLooping();\r
212                 return ret;\r
213             }\r
214         }\r
215 \r
216         public EndActions EndAction\r
217         {\r
218             set\r
219             {\r
220                 SetEndAction(value);\r
221             }\r
222             get\r
223             {\r
224                 return GetEndAction();\r
225             }\r
226         }\r
227 \r
228         public void Stop(EndActions action = EndActions.Cancel)\r
229         {\r
230             SetEndAction(action);\r
231             NDalicPINVOKE.Animation_Stop(swigCPtr);\r
232             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
233         }\r
234 \r
235         public int CurrentLoop\r
236         {\r
237             get\r
238             {\r
239                 return GetCurrentLoop();\r
240             }\r
241         }\r
242 \r
243         public EndActions DisconnectAction\r
244         {\r
245             set\r
246             {\r
247                 NDalicPINVOKE.Animation_SetDisconnectAction(swigCPtr, (int)value);\r
248                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
249             }\r
250             get\r
251             {\r
252                 Animation.EndActions ret = (Animation.EndActions)NDalicPINVOKE.Animation_GetDisconnectAction(swigCPtr);\r
253                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
254                 return ret;\r
255             }\r
256         }\r
257 \r
258         public float CurrentProgress\r
259         {\r
260             set\r
261             {\r
262                 NDalicPINVOKE.Animation_SetCurrentProgress(swigCPtr, value);\r
263                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
264             }\r
265             get\r
266             {\r
267                 float ret = NDalicPINVOKE.Animation_GetCurrentProgress(swigCPtr);\r
268                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
269                 return ret;\r
270             }\r
271         }\r
272 \r
273         public float SpeedFactor\r
274         {\r
275             set\r
276             {\r
277                 NDalicPINVOKE.Animation_SetSpeedFactor(swigCPtr, value);\r
278                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
279             }\r
280             get\r
281             {\r
282                 float ret = NDalicPINVOKE.Animation_GetSpeedFactor(swigCPtr);\r
283                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
284                 return ret;\r
285             }\r
286         }\r
287 \r
288         public Vector2 PlayRange\r
289         {\r
290             set\r
291             {\r
292                 NDalicPINVOKE.Animation_SetPlayRange(swigCPtr, Vector2.getCPtr(value));\r
293                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
294             }\r
295             get\r
296             {\r
297                 Vector2 ret = new Vector2(NDalicPINVOKE.Animation_GetPlayRange(swigCPtr), true);\r
298                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
299                 return ret;\r
300             }\r
301         }\r
302 \r
303 \r
304         public void AnimateBy(Actor target, string property, object relativeValue, AlphaFunction alphaFunction = null)\r
305         {\r
306             string _str1 = property.Substring(0, 1);\r
307             string _str2 = property.Substring(1);\r
308             string _str = _str1.ToLower() + _str2;\r
309 \r
310             Property _prop = new Property(target, _str);\r
311             if (_prop.propertyIndex == Property.INVALID_INDEX)\r
312             {\r
313                 throw new System.Exception("second argument string property is invalid parameter!");\r
314             }\r
315 \r
316             dynamic obj = (object)relativeValue;\r
317 \r
318             if (alphaFunction != null)\r
319             {\r
320                 AnimateBy(_prop, new PropertyValue(obj), alphaFunction);\r
321             }\r
322             else\r
323             {\r
324                 AnimateBy(_prop, new PropertyValue(obj));\r
325             }\r
326         }\r
327 \r
328         public void AnimateBy(Actor target, string property, object relativeValue, int startTime, int endTime, AlphaFunction alphaFunction = null)\r
329         {\r
330             string _str1 = property.Substring(0, 1);\r
331             string _str2 = property.Substring(1);\r
332             string _str = _str1.ToLower() + _str2;\r
333 \r
334             Property _prop = new Property(target, _str);\r
335             if (_prop.propertyIndex == Property.INVALID_INDEX)\r
336             {\r
337                 throw new System.Exception("second argument string property is invalid parameter!");\r
338             }\r
339 \r
340             dynamic obj = (object)relativeValue;\r
341 \r
342             if (alphaFunction != null)\r
343             {\r
344                 Tizen.NUI.TimePeriod time = new Tizen.NUI.TimePeriod(MilliSecondsToSeconds(startTime), MilliSecondsToSeconds(endTime - startTime));\r
345                 AnimateBy(_prop, new PropertyValue(obj), alphaFunction, time);\r
346             }\r
347             else\r
348             {\r
349                 Tizen.NUI.TimePeriod time = new Tizen.NUI.TimePeriod(MilliSecondsToSeconds(startTime), MilliSecondsToSeconds(endTime - startTime));\r
350                 AnimateBy(_prop, new PropertyValue(obj), time);\r
351             }\r
352         }\r
353 \r
354         public void AnimateTo(Actor target, string property, object destinationValue, AlphaFunction alphaFunction = null)\r
355         {\r
356             string _str1 = property.Substring(0, 1);\r
357             string _str2 = property.Substring(1);\r
358             string _str = _str1.ToLower() + _str2;\r
359 \r
360             Property _prop = new Property(target, _str);\r
361             if (_prop.propertyIndex == Property.INVALID_INDEX)\r
362             {\r
363                 throw new System.Exception("second argument string property is invalid parameter!");\r
364             }\r
365 \r
366             dynamic obj = (object)destinationValue;\r
367 \r
368             if (alphaFunction != null)\r
369             {\r
370                 AnimateTo(_prop, new PropertyValue(obj), alphaFunction);\r
371             }\r
372             else\r
373             {\r
374                 AnimateTo(_prop, new PropertyValue(obj));\r
375             }\r
376         }\r
377 \r
378         public void AnimateTo(Actor target, string property, object destinationValue, int startTime, int endTime, AlphaFunction alphaFunction = null)\r
379         {\r
380             string _str1 = property.Substring(0, 1);\r
381             string _str2 = property.Substring(1);\r
382             string _str = _str1.ToLower() + _str2;\r
383 \r
384             Property _prop = new Property(target, _str);\r
385             if (_prop.propertyIndex == Property.INVALID_INDEX)\r
386             {\r
387                 throw new System.Exception("second argument string property is invalid parameter!");\r
388             }\r
389 \r
390             dynamic obj = (object)destinationValue;\r
391 \r
392             if (alphaFunction != null)\r
393             {\r
394                 Tizen.NUI.TimePeriod time = new Tizen.NUI.TimePeriod(MilliSecondsToSeconds(startTime), MilliSecondsToSeconds(endTime - startTime));\r
395                 AnimateTo(_prop, new PropertyValue(obj), alphaFunction, time);\r
396             }\r
397             else\r
398             {\r
399                 Tizen.NUI.TimePeriod time = new Tizen.NUI.TimePeriod(MilliSecondsToSeconds(startTime), MilliSecondsToSeconds(endTime - startTime));\r
400                 AnimateTo(_prop, new PropertyValue(obj), time);\r
401             }\r
402         }\r
403 \r
404         public void AnimateBetween(Actor target, string property, KeyFrames keyFrames, AlphaFunction alphaFunction = null)\r
405         {\r
406             string _str1 = property.Substring(0, 1);\r
407             string _str2 = property.Substring(1);\r
408             string _str = _str1.ToLower() + _str2;\r
409 \r
410             Property _prop = new Property(target, _str);\r
411             if (_prop.propertyIndex == Property.INVALID_INDEX)\r
412             {\r
413                 throw new System.Exception("second argument string property is invalid parameter!");\r
414             }\r
415 \r
416             if (alphaFunction != null)\r
417             {\r
418 \r
419                 AnimateBetween(_prop, keyFrames);\r
420             }\r
421             else\r
422             {\r
423                 AnimateBetween(_prop, keyFrames, alphaFunction);\r
424             }\r
425         }\r
426 \r
427         public void AnimateBetween(Actor target, string property, KeyFrames keyFrames, int startTime, int endTime, Interpolation interpolation = Interpolation.Linear, AlphaFunction alphaFunction = null)\r
428         {\r
429             string _str1 = property.Substring(0, 1);\r
430             string _str2 = property.Substring(1);\r
431             string _str = _str1.ToLower() + _str2;\r
432 \r
433             Property _prop = new Property(target, _str);\r
434             if (_prop.propertyIndex == Property.INVALID_INDEX)\r
435             {\r
436                 throw new System.Exception("second argument string property is invalid parameter!");\r
437             }\r
438 \r
439             Tizen.NUI.TimePeriod time = new Tizen.NUI.TimePeriod(MilliSecondsToSeconds(startTime), MilliSecondsToSeconds(endTime - startTime));\r
440             if (alphaFunction != null)\r
441             {\r
442                 AnimateBetween(_prop, keyFrames, alphaFunction, time, interpolation);\r
443             }\r
444             else\r
445             {\r
446                 AnimateBetween(_prop, keyFrames, time, interpolation);\r
447             }\r
448         }\r
449 \r
450         public void AnimatePath(Actor actor, Path path, Vector3 forward, AlphaFunction alphaFunction = null)\r
451         {\r
452             if (alphaFunction == null)\r
453             {\r
454                 Animate(actor, path, forward);\r
455             }\r
456             else\r
457             {\r
458                 Animate(actor, path, forward, alphaFunction);\r
459             }\r
460         }\r
461 \r
462         public void AnimatePath(Actor actor, Path path, Vector3 forward, int startTime, int endTime, AlphaFunction alphaFunction = null)\r
463         {\r
464             TimePeriod time = new TimePeriod(MilliSecondsToSeconds(startTime), MilliSecondsToSeconds(endTime - startTime));\r
465             if (alphaFunction == null)\r
466             {\r
467                 Animate(actor, path, forward, time);\r
468             }\r
469             else\r
470             {\r
471                 Animate(actor, path, forward, alphaFunction, time);\r
472             }\r
473         }\r
474 \r
475 \r
476         public Animation() : this(NDalicPINVOKE.Animation_New(0.0f), true)\r
477         {\r
478             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
479         }\r
480 \r
481         internal Animation(float durationSeconds) : this(NDalicPINVOKE.Animation_New(durationSeconds), true)\r
482         {\r
483             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
484 \r
485         }\r
486         public static Animation DownCast(BaseHandle handle)\r
487         {\r
488             Animation ret = new Animation(NDalicPINVOKE.Animation_DownCast(BaseHandle.getCPtr(handle)), true);\r
489             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
490             return ret;\r
491         }\r
492 \r
493         internal Animation(Animation handle) : this(NDalicPINVOKE.new_Animation__SWIG_1(Animation.getCPtr(handle)), true)\r
494         {\r
495             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
496         }\r
497 \r
498         internal Animation Assign(Animation rhs)\r
499         {\r
500             Animation ret = new Animation(NDalicPINVOKE.Animation_Assign(swigCPtr, Animation.getCPtr(rhs)), false);\r
501             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
502             return ret;\r
503         }\r
504 \r
505         internal void SetDuration(float seconds)\r
506         {\r
507             NDalicPINVOKE.Animation_SetDuration(swigCPtr, seconds);\r
508             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
509         }\r
510 \r
511         internal float GetDuration()\r
512         {\r
513             float ret = NDalicPINVOKE.Animation_GetDuration(swigCPtr);\r
514             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
515             return ret;\r
516         }\r
517 \r
518         internal void SetLooping(bool looping)\r
519         {\r
520             NDalicPINVOKE.Animation_SetLooping(swigCPtr, looping);\r
521             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
522         }\r
523 \r
524         internal void SetLoopCount(int count)\r
525         {\r
526             NDalicPINVOKE.Animation_SetLoopCount(swigCPtr, count);\r
527             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
528         }\r
529 \r
530         internal int GetLoopCount()\r
531         {\r
532             int ret = NDalicPINVOKE.Animation_GetLoopCount(swigCPtr);\r
533             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
534             return ret;\r
535         }\r
536 \r
537         internal int GetCurrentLoop()\r
538         {\r
539             int ret = NDalicPINVOKE.Animation_GetCurrentLoop(swigCPtr);\r
540             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
541             return ret;\r
542         }\r
543 \r
544         internal bool IsLooping()\r
545         {\r
546             bool ret = NDalicPINVOKE.Animation_IsLooping(swigCPtr);\r
547             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
548             return ret;\r
549         }\r
550 \r
551         internal void SetEndAction(Animation.EndActions action)\r
552         {\r
553             NDalicPINVOKE.Animation_SetEndAction(swigCPtr, (int)action);\r
554             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
555         }\r
556 \r
557         internal Animation.EndActions GetEndAction()\r
558         {\r
559             Animation.EndActions ret = (Animation.EndActions)NDalicPINVOKE.Animation_GetEndAction(swigCPtr);\r
560             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
561             return ret;\r
562         }\r
563 \r
564         internal void SetDisconnectAction(Animation.EndActions disconnectAction)\r
565         {\r
566             NDalicPINVOKE.Animation_SetDisconnectAction(swigCPtr, (int)disconnectAction);\r
567             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
568         }\r
569 \r
570         internal Animation.EndActions GetDisconnectAction()\r
571         {\r
572             Animation.EndActions ret = (Animation.EndActions)NDalicPINVOKE.Animation_GetDisconnectAction(swigCPtr);\r
573             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
574             return ret;\r
575         }\r
576 \r
577         internal void SetDefaultAlphaFunction(AlphaFunction alpha)\r
578         {\r
579             NDalicPINVOKE.Animation_SetDefaultAlphaFunction(swigCPtr, AlphaFunction.getCPtr(alpha));\r
580             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
581         }\r
582 \r
583         internal AlphaFunction GetDefaultAlphaFunction()\r
584         {\r
585             AlphaFunction ret = new AlphaFunction(NDalicPINVOKE.Animation_GetDefaultAlphaFunction(swigCPtr), true);\r
586             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
587             return ret;\r
588         }\r
589 \r
590         internal void SetCurrentProgress(float progress)\r
591         {\r
592             NDalicPINVOKE.Animation_SetCurrentProgress(swigCPtr, progress);\r
593             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
594         }\r
595 \r
596         internal float GetCurrentProgress()\r
597         {\r
598             float ret = NDalicPINVOKE.Animation_GetCurrentProgress(swigCPtr);\r
599             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
600             return ret;\r
601         }\r
602 \r
603         internal void SetSpeedFactor(float factor)\r
604         {\r
605             NDalicPINVOKE.Animation_SetSpeedFactor(swigCPtr, factor);\r
606             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
607         }\r
608 \r
609         internal float GetSpeedFactor()\r
610         {\r
611             float ret = NDalicPINVOKE.Animation_GetSpeedFactor(swigCPtr);\r
612             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
613             return ret;\r
614         }\r
615 \r
616         internal void SetPlayRange(Vector2 range)\r
617         {\r
618             NDalicPINVOKE.Animation_SetPlayRange(swigCPtr, Vector2.getCPtr(range));\r
619             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
620         }\r
621 \r
622         internal Vector2 GetPlayRange()\r
623         {\r
624             Vector2 ret = new Vector2(NDalicPINVOKE.Animation_GetPlayRange(swigCPtr), true);\r
625             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
626             return ret;\r
627         }\r
628 \r
629         public void Play()\r
630         {\r
631             NDalicPINVOKE.Animation_Play(swigCPtr);\r
632             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
633         }\r
634 \r
635         public void PlayFrom(float progress)\r
636         {\r
637             NDalicPINVOKE.Animation_PlayFrom(swigCPtr, progress);\r
638             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
639         }\r
640 \r
641         public void Pause()\r
642         {\r
643             NDalicPINVOKE.Animation_Pause(swigCPtr);\r
644             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
645         }\r
646 \r
647         internal Animation.States GetState()\r
648         {\r
649             Animation.States ret = (Animation.States)NDalicPINVOKE.Animation_GetState(swigCPtr);\r
650             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
651             return ret;\r
652         }\r
653 \r
654         public void Stop()\r
655         {\r
656             NDalicPINVOKE.Animation_Stop(swigCPtr);\r
657             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
658         }\r
659 \r
660         public void Clear()\r
661         {\r
662             NDalicPINVOKE.Animation_Clear(swigCPtr);\r
663             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
664         }\r
665 \r
666         internal AnimationSignal FinishedSignal()\r
667         {\r
668             AnimationSignal ret = new AnimationSignal(NDalicPINVOKE.Animation_FinishedSignal(swigCPtr), false);\r
669             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
670             return ret;\r
671         }\r
672 \r
673         internal void AnimateBy(Property target, PropertyValue relativeValue)\r
674         {\r
675             NDalicPINVOKE.Animation_AnimateBy__SWIG_0(swigCPtr, Property.getCPtr(target), PropertyValue.getCPtr(relativeValue));\r
676             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
677         }\r
678 \r
679         internal void AnimateBy(Property target, PropertyValue relativeValue, AlphaFunction alpha)\r
680         {\r
681             NDalicPINVOKE.Animation_AnimateBy__SWIG_1(swigCPtr, Property.getCPtr(target), PropertyValue.getCPtr(relativeValue), AlphaFunction.getCPtr(alpha));\r
682             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
683         }\r
684 \r
685         internal void AnimateBy(Property target, PropertyValue relativeValue, TimePeriod period)\r
686         {\r
687             NDalicPINVOKE.Animation_AnimateBy__SWIG_2(swigCPtr, Property.getCPtr(target), PropertyValue.getCPtr(relativeValue), TimePeriod.getCPtr(period));\r
688             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
689         }\r
690 \r
691         internal void AnimateBy(Property target, PropertyValue relativeValue, AlphaFunction alpha, TimePeriod period)\r
692         {\r
693             NDalicPINVOKE.Animation_AnimateBy__SWIG_3(swigCPtr, Property.getCPtr(target), PropertyValue.getCPtr(relativeValue), AlphaFunction.getCPtr(alpha), TimePeriod.getCPtr(period));\r
694             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
695         }\r
696 \r
697         internal void AnimateTo(Property target, PropertyValue destinationValue)\r
698         {\r
699             NDalicPINVOKE.Animation_AnimateTo__SWIG_0(swigCPtr, Property.getCPtr(target), PropertyValue.getCPtr(destinationValue));\r
700             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
701         }\r
702 \r
703         internal void AnimateTo(Property target, PropertyValue destinationValue, AlphaFunction alpha)\r
704         {\r
705             NDalicPINVOKE.Animation_AnimateTo__SWIG_1(swigCPtr, Property.getCPtr(target), PropertyValue.getCPtr(destinationValue), AlphaFunction.getCPtr(alpha));\r
706             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
707         }\r
708 \r
709         internal void AnimateTo(Property target, PropertyValue destinationValue, TimePeriod period)\r
710         {\r
711             NDalicPINVOKE.Animation_AnimateTo__SWIG_2(swigCPtr, Property.getCPtr(target), PropertyValue.getCPtr(destinationValue), TimePeriod.getCPtr(period));\r
712             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
713         }\r
714 \r
715         internal void AnimateTo(Property target, PropertyValue destinationValue, AlphaFunction alpha, TimePeriod period)\r
716         {\r
717             NDalicPINVOKE.Animation_AnimateTo__SWIG_3(swigCPtr, Property.getCPtr(target), PropertyValue.getCPtr(destinationValue), AlphaFunction.getCPtr(alpha), TimePeriod.getCPtr(period));\r
718             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
719         }\r
720 \r
721         internal void AnimateBetween(Property target, KeyFrames keyFrames)\r
722         {\r
723             NDalicPINVOKE.Animation_AnimateBetween__SWIG_0(swigCPtr, Property.getCPtr(target), KeyFrames.getCPtr(keyFrames));\r
724             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
725         }\r
726 \r
727         internal void AnimateBetween(Property target, KeyFrames keyFrames, Animation.Interpolation interpolation)\r
728         {\r
729             NDalicPINVOKE.Animation_AnimateBetween__SWIG_1(swigCPtr, Property.getCPtr(target), KeyFrames.getCPtr(keyFrames), (int)interpolation);\r
730             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
731         }\r
732 \r
733         internal void AnimateBetween(Property target, KeyFrames keyFrames, AlphaFunction alpha)\r
734         {\r
735             NDalicPINVOKE.Animation_AnimateBetween__SWIG_2(swigCPtr, Property.getCPtr(target), KeyFrames.getCPtr(keyFrames), AlphaFunction.getCPtr(alpha));\r
736             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
737         }\r
738 \r
739         internal void AnimateBetween(Property target, KeyFrames keyFrames, AlphaFunction alpha, Animation.Interpolation interpolation)\r
740         {\r
741             NDalicPINVOKE.Animation_AnimateBetween__SWIG_3(swigCPtr, Property.getCPtr(target), KeyFrames.getCPtr(keyFrames), AlphaFunction.getCPtr(alpha), (int)interpolation);\r
742             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
743         }\r
744 \r
745         internal void AnimateBetween(Property target, KeyFrames keyFrames, TimePeriod period)\r
746         {\r
747             NDalicPINVOKE.Animation_AnimateBetween__SWIG_4(swigCPtr, Property.getCPtr(target), KeyFrames.getCPtr(keyFrames), TimePeriod.getCPtr(period));\r
748             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
749         }\r
750 \r
751         internal void AnimateBetween(Property target, KeyFrames keyFrames, TimePeriod period, Animation.Interpolation interpolation)\r
752         {\r
753             NDalicPINVOKE.Animation_AnimateBetween__SWIG_5(swigCPtr, Property.getCPtr(target), KeyFrames.getCPtr(keyFrames), TimePeriod.getCPtr(period), (int)interpolation);\r
754             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
755         }\r
756 \r
757         internal void AnimateBetween(Property target, KeyFrames keyFrames, AlphaFunction alpha, TimePeriod period)\r
758         {\r
759             NDalicPINVOKE.Animation_AnimateBetween__SWIG_6(swigCPtr, Property.getCPtr(target), KeyFrames.getCPtr(keyFrames), AlphaFunction.getCPtr(alpha), TimePeriod.getCPtr(period));\r
760             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
761         }\r
762 \r
763         internal void AnimateBetween(Property target, KeyFrames keyFrames, AlphaFunction alpha, TimePeriod period, Animation.Interpolation interpolation)\r
764         {\r
765             NDalicPINVOKE.Animation_AnimateBetween__SWIG_7(swigCPtr, Property.getCPtr(target), KeyFrames.getCPtr(keyFrames), AlphaFunction.getCPtr(alpha), TimePeriod.getCPtr(period), (int)interpolation);\r
766             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
767         }\r
768 \r
769         internal void Animate(Actor actor, Path path, Vector3 forward)\r
770         {\r
771             NDalicPINVOKE.Animation_Animate__SWIG_0(swigCPtr, Actor.getCPtr(actor), Path.getCPtr(path), Vector3.getCPtr(forward));\r
772             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
773         }\r
774 \r
775         internal void Animate(Actor actor, Path path, Vector3 forward, AlphaFunction alpha)\r
776         {\r
777             NDalicPINVOKE.Animation_Animate__SWIG_1(swigCPtr, Actor.getCPtr(actor), Path.getCPtr(path), Vector3.getCPtr(forward), AlphaFunction.getCPtr(alpha));\r
778             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
779         }\r
780 \r
781         internal void Animate(Actor actor, Path path, Vector3 forward, TimePeriod period)\r
782         {\r
783             NDalicPINVOKE.Animation_Animate__SWIG_2(swigCPtr, Actor.getCPtr(actor), Path.getCPtr(path), Vector3.getCPtr(forward), TimePeriod.getCPtr(period));\r
784             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
785         }\r
786 \r
787         internal void Animate(Actor actor, Path path, Vector3 forward, AlphaFunction alpha, TimePeriod period)\r
788         {\r
789             NDalicPINVOKE.Animation_Animate__SWIG_3(swigCPtr, Actor.getCPtr(actor), Path.getCPtr(path), Vector3.getCPtr(forward), AlphaFunction.getCPtr(alpha), TimePeriod.getCPtr(period));\r
790             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
791         }\r
792 \r
793         internal void Show(Actor actor, float delaySeconds)\r
794         {\r
795             NDalicPINVOKE.Animation_Show(swigCPtr, Actor.getCPtr(actor), delaySeconds);\r
796             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
797         }\r
798 \r
799         internal void Hide(Actor actor, float delaySeconds)\r
800         {\r
801             NDalicPINVOKE.Animation_Hide(swigCPtr, Actor.getCPtr(actor), delaySeconds);\r
802             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();\r
803         }\r
804 \r
805         public enum EndActions\r
806         {\r
807             Cancel,\r
808             Discard,\r
809             StopFinal\r
810         }\r
811 \r
812         public enum Interpolation\r
813         {\r
814             Linear,\r
815             Cubic\r
816         }\r
817 \r
818         public enum States\r
819         {\r
820             Stopped,\r
821             Playing,\r
822             Paused\r
823         }\r
824 \r
825     }
826
827 }