6bd8eee717dce52faf48b7d5441b4d7e4c9cc151
[platform/core/csapi/tizenfx.git] / src / Tizen.NUI / src / public / Animation.cs
1 /*
2  * Copyright(c) 2017 Samsung Electronics Co., Ltd.
3  *
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
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
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.
15  *
16  */
17
18 namespace Tizen.NUI
19 {
20
21     using System;
22     using System.Runtime.InteropServices;
23     using Tizen.NUI.BaseComponents;
24
25     /// <summary>
26     /// Animation can be used to animate the properties of any number of objects, typically view.<br />
27     /// If the "Finished" event is connected to a member function of an object, it must be disconnected before the object is destroyed.<br />
28     /// This is typically done in the object destructor, and requires either the animation handle to be stored.<br />
29     /// The overall animation time is superseded by the values given in the animation time used when calling the AnimateTo(), AnimateBy(), AnimateBetween() and AnimatePath() methods.<br />
30     /// If any of the individual calls to those functions exceeds the overall animation time (Duration), then the overall animation time is automatically extended.<br />
31     /// </summary>
32     /// <since_tizen> 3 </since_tizen>
33     public class Animation : BaseHandle
34     {
35         private global::System.Runtime.InteropServices.HandleRef swigCPtr;
36
37         internal Animation(global::System.IntPtr cPtr, bool cMemoryOwn) : base(NDalicPINVOKE.Animation_SWIGUpcast(cPtr), cMemoryOwn)
38         {
39             swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
40
41             _animationFinishedEventCallback = OnFinished;
42             _finishedCallbackOfNative = System.Runtime.InteropServices.Marshal.GetFunctionPointerForDelegate<System.Delegate>(_animationFinishedEventCallback);
43         }
44
45         internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Animation obj)
46         {
47             return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
48         }
49
50         /// <summary>
51         /// To make animation instance be disposed.
52         /// </summary>
53         /// <since_tizen> 3 </since_tizen>
54         protected override void Dispose(DisposeTypes type)
55         {
56             if (this != null)
57             {
58                 if (_animationFinishedEventCallback != null)
59                 {
60                     FinishedSignal().Disconnect(_finishedCallbackOfNative);
61                 }
62
63                 if (_animationProgressReachedEventCallback != null)
64                 {
65
66                     ProgressReachedSignal().Disconnect(_animationProgressReachedEventCallback);
67                 }
68             }
69
70             if(disposed)
71             {
72                 return;
73             }
74             if(type == DisposeTypes.Explicit)
75             {
76                 //Called by User
77                 //Release your own managed resources here.
78                 //You should release all of your own disposable objects here.
79
80             }
81             else if(type == DisposeTypes.Implicit)
82             {
83
84             }
85
86             this?.Clear();
87
88             //Release your own unmanaged resources here.
89             //You should not access any managed member here except static instance.
90             //because the execution order of Finalizes is non-deterministic.
91
92             if (swigCPtr.Handle != global::System.IntPtr.Zero)
93             {
94                 if (swigCMemOwn)
95                 {
96                     swigCMemOwn = false;
97                     NDalicPINVOKE.delete_Animation(swigCPtr);
98                 }
99                 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
100             }
101
102             base.Dispose(type);
103         }
104
105         /// <summary>
106         /// Creates an initialized animation.<br />
107         /// The animation will not loop.<br />
108         /// The default end action is "Cancel".<br />
109         /// The default alpha function is linear.<br />
110         /// </summary>
111         /// <remarks>DurationmSeconds must be greater than zero.</remarks>
112         /// <param name="durationMilliSeconds">The duration in milliseconds.</param>
113         /// <since_tizen> 3 </since_tizen>
114         public Animation(int durationMilliSeconds) : this(NDalicPINVOKE.Animation_New((float)durationMilliSeconds / 1000.0f), true)
115         {
116             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
117         }
118
119         private AnimationFinishedEventCallbackType _animationFinishedEventCallback;
120         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
121         private delegate void AnimationFinishedEventCallbackType(IntPtr data);
122         private event EventHandler _animationFinishedEventHandler;
123
124         private System.IntPtr _finishedCallbackOfNative;
125
126         /**
127         * @brief Event for the finished signal which can be used to subscribe or unsubscribe the event handler.
128         * The finished signal is emitted when an animation's animations have finished.
129         */
130         /// <since_tizen> 3 </since_tizen>
131         public event EventHandler Finished
132         {
133             add
134             {
135                 if (_animationFinishedEventHandler == null && disposed == false)
136                 {
137                     FinishedSignal().Connect(_finishedCallbackOfNative);
138                 }
139                 _animationFinishedEventHandler += value;
140             }
141             remove
142             {
143                 _animationFinishedEventHandler -= value;
144
145                 if (_animationFinishedEventHandler == null && FinishedSignal().Empty() == false)
146                 {
147                     FinishedSignal().Disconnect(_finishedCallbackOfNative);
148                 }
149             }
150         }
151         private void OnFinished(IntPtr data)
152         {
153             if (_animationFinishedEventHandler != null)
154             {
155                 //here we send all data to user event handlers
156                 _animationFinishedEventHandler(this, null);
157             }
158         }
159
160         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
161         private delegate void AnimationProgressReachedEventCallbackType(IntPtr data);
162         private AnimationProgressReachedEventCallbackType _animationProgressReachedEventCallback;
163         private event EventHandler _animationProgressReachedEventHandler;
164         /**
165         * @brief Event for the ProgressReached signal, which can be used to subscribe or unsubscribe the event handler.
166         * The ProgressReached signal is emitted when the animation has reached a given progress percentage, this is set in the api SetProgressNotification.
167         */
168         /// <since_tizen> 3 </since_tizen>
169         public event EventHandler ProgressReached
170         {
171             add
172             {
173                 if (_animationProgressReachedEventHandler == null)
174                 {
175                     _animationProgressReachedEventCallback = OnProgressReached;
176                     ProgressReachedSignal().Connect(_animationProgressReachedEventCallback);
177                 }
178
179                 _animationProgressReachedEventHandler += value;
180             }
181             remove
182             {
183                 _animationProgressReachedEventHandler -= value;
184
185                 if (_animationProgressReachedEventHandler == null && ProgressReachedSignal().Empty() == false)
186                 {
187                     ProgressReachedSignal().Disconnect(_animationProgressReachedEventCallback);
188                 }
189             }
190         }
191         private void OnProgressReached(IntPtr data)
192         {
193             if (_animationProgressReachedEventHandler != null)
194             {
195                 //here we send all data to user event handlers
196                 _animationProgressReachedEventHandler(this, null);
197             }
198         }
199
200         private float MilliSecondsToSeconds(int millisec)
201         {
202             return (float)millisec / 1000.0f;
203         }
204
205         private int SecondsToMilliSeconds(float sec)
206         {
207             return (int)(sec * 1000);
208         }
209
210
211         /// <summary>
212         /// Gets or sets the duration in milliseconds of the animation.
213         /// </summary>
214         /// <since_tizen> 3 </since_tizen>
215         public int Duration
216         {
217             set
218             {
219                 SetDuration(MilliSecondsToSeconds(value));
220             }
221             get
222             {
223                 return SecondsToMilliSeconds(GetDuration());
224             }
225         }
226
227         /// <summary>
228         ///  Gets or sets the default alpha function for the animation.
229         /// </summary>
230         /// <since_tizen> 3 </since_tizen>
231         public AlphaFunction DefaultAlphaFunction
232         {
233             set
234             {
235                 SetDefaultAlphaFunction(value);
236             }
237             get
238             {
239                 AlphaFunction ret = GetDefaultAlphaFunction();
240                 return ret;
241             }
242         }
243
244         /// <summary>
245         /// Queries the state of the animation.
246         /// </summary>
247         /// <since_tizen> 3 </since_tizen>
248         public States State
249         {
250             get
251             {
252                 return GetState();
253             }
254         }
255
256         /// <summary>
257         /// Set: Enables looping for a specified number of repeats. A zero is the same as Looping = true; i.e., repeat forever.<br />
258         /// This property resets the looping value and should not be used with the Looping property.<br />
259         /// Setting this parameter does not cause the animation to Play().<br />
260         /// Get: Gets the loop count. A zero is the same as Looping = true; i.e., repeat forever.<br />
261         /// The loop count is initially 1 for play once.<br />
262         /// </summary>
263         /// <since_tizen> 3 </since_tizen>
264         public int LoopCount
265         {
266             set
267             {
268                 SetLoopCount(value);
269             }
270             get
271             {
272                 int ret = GetLoopCount();
273                 return ret;
274             }
275         }
276
277         /// <summary>
278         /// Gets or sets the status of whether the animation will loop.<br />
279         /// This property resets the loop count and should not be used with the LoopCount property.<br />
280         /// Setting this parameter does not cause the animation to Play().<br />
281         /// </summary>
282         /// <since_tizen> 3 </since_tizen>
283         public bool Looping
284         {
285             set
286             {
287                 SetLooping(value);
288             }
289             get
290             {
291                 bool ret = IsLooping();
292                 return ret;
293             }
294         }
295
296
297         /// <summary>
298         /// Gets or sets the end action of the animation.<br />
299         /// This action is performed when the animation ends or if it is stopped.<br />
300         /// The default end action is cancel.<br />
301         /// </summary>
302         /// <since_tizen> 3 </since_tizen>
303         public EndActions EndAction
304         {
305             set
306             {
307                 SetEndAction(value);
308             }
309             get
310             {
311                 return GetEndAction();
312             }
313         }
314
315
316         /// <summary>
317         /// Stops the animation.
318         /// </summary>
319         /// <param name="action">The end action can be set.</param>
320         /// <since_tizen> 3 </since_tizen>
321         public void Stop(EndActions action = EndActions.Cancel)
322         {
323             SetEndAction(action);
324             NDalicPINVOKE.Animation_Stop(swigCPtr);
325             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
326         }
327
328         /// <summary>
329         /// Gets the current loop count.<br />
330         /// A value 0 indicating the current loop count when looping.<br />
331         /// </summary>
332         /// <since_tizen> 3 </since_tizen>
333         public int CurrentLoop
334         {
335             get
336             {
337                 return GetCurrentLoop();
338             }
339         }
340
341         /// <summary>
342         /// Gets or sets the disconnect action.<br />
343         /// If any of the animated property owners are disconnected from the stage while the animation is being played, then this action is performed.<br />
344         /// The default action is cancel.<br />
345         /// </summary>
346         /// <since_tizen> 3 </since_tizen>
347         public EndActions DisconnectAction
348         {
349             set
350             {
351                 NDalicPINVOKE.Animation_SetDisconnectAction(swigCPtr, (int)value);
352                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
353             }
354             get
355             {
356                 Animation.EndActions ret = (Animation.EndActions)NDalicPINVOKE.Animation_GetDisconnectAction(swigCPtr);
357                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
358                 return ret;
359             }
360         }
361
362
363         /// <summary>
364         /// Gets or sets the progress of the animation.<br />
365         /// The animation will play (or continue playing) from this point.<br />
366         /// The progress must be in the 0-1 interval or in the play range interval if defined<br />
367         /// otherwise, it will be ignored.<br />
368         /// </summary>
369         /// <since_tizen> 3 </since_tizen>
370         public float CurrentProgress
371         {
372             set
373             {
374                 NDalicPINVOKE.Animation_SetCurrentProgress(swigCPtr, value);
375                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
376             }
377             get
378             {
379                 float ret = NDalicPINVOKE.Animation_GetCurrentProgress(swigCPtr);
380                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
381                 return ret;
382             }
383         }
384
385         /// <summary>
386         /// Gets or sets specificifications of a speed factor for the animation.<br />
387         /// The speed factor is a multiplier of the normal velocity of the animation.<br />
388         /// Values between [0, 1] will slow down the animation and values above one will speed up the animation.<br />
389         /// It is also possible to specify a negative multiplier to play the animation in reverse.<br />
390         /// </summary>
391         /// <since_tizen> 3 </since_tizen>
392         public float SpeedFactor
393         {
394             set
395             {
396                 NDalicPINVOKE.Animation_SetSpeedFactor(swigCPtr, value);
397                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
398             }
399             get
400             {
401                 float ret = NDalicPINVOKE.Animation_GetSpeedFactor(swigCPtr);
402                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
403                 return ret;
404             }
405         }
406
407         /// <summary>
408         /// Gets or sets the playing range.<br />
409         /// Animation will play between the values specified. Both values (range.x and range.y ) should be between 0-1,
410         /// otherwise they will be ignored. If the range provided is not in proper order (minimum, maximum ), it will be reordered.<br />
411         /// </summary>
412         /// <since_tizen> 3 </since_tizen>
413         public RelativeVector2 PlayRange
414         {
415             set
416             {
417                 NDalicPINVOKE.Animation_SetPlayRange(swigCPtr, Vector2.getCPtr(value));
418                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
419             }
420             get
421             {
422                 Vector2 ret = new Vector2(NDalicPINVOKE.Animation_GetPlayRange(swigCPtr), true);
423                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
424                 return ret;
425             }
426         }
427
428
429         /// <summary>
430         /// Gets or sets the progress notification marker which triggers the ProgressReachedSignal.<br />
431         /// Percentage of animation progress should be greater than 0 and less than 1, for example, 0.3 for 30% <br />
432         /// One notification can be set on each animation.
433         /// </summary>
434         /// <since_tizen> 3 </since_tizen>
435         public float ProgressNotification
436         {
437             set
438             {
439                 NDalicPINVOKE.Animation_SetProgressNotification(swigCPtr, value);
440                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
441             }
442             get
443             {
444                 float ret = NDalicPINVOKE.Animation_GetProgressNotification(swigCPtr);
445                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
446                 return ret;
447             }
448         }
449
450         /// <summary>
451         /// Animates a property value by a relative amount.<br />
452         /// </summary>
453         /// <param name="target">The target object to animate.</param>
454         /// <param name="property">The target property to animate.</param>
455         /// <param name="relativeValue">The property value will change by this amount.</param>
456         /// <param name="alphaFunction">The alpha function to apply.</param>
457         /// <since_tizen> 3 </since_tizen>
458         public void AnimateBy(View target, string property, object relativeValue, AlphaFunction alphaFunction = null)
459         {
460             Property _prop = PropertyHelper.GetPropertyFromString(target, property);
461
462             PropertyType propertyType = target.GetPropertyType(_prop.propertyIndex);
463             if(propertyType.Equals(PropertyType.Float))
464             {
465                 System.Type type = relativeValue.GetType();
466                 if (type.Equals(typeof(System.Int32)) || type.Equals(typeof(int)))
467                 {
468                     int num = (int)relativeValue;
469                     relativeValue = (float)num;
470                 }
471             }
472
473             PropertyValue val = PropertyValue.CreateFromObject(relativeValue);
474
475             if (alphaFunction != null)
476             {
477                 AnimateBy(_prop, val, alphaFunction);
478             }
479             else
480             {
481                 AnimateBy(_prop, val);
482             }
483         }
484
485         /// <summary>
486         /// Animates a property value by a relative amount.<br />
487         /// </summary>
488         /// <param name="target">The target object to animate.</param>
489         /// <param name="property">The target property to animate.</param>
490         /// <param name="relativeValue">The property value will change by this amount.</param>
491         /// <param name="startTime">The start time of the animation.</param>
492         /// <param name="endTime">The end time of the animation.</param>
493         /// <param name="alphaFunction">The alpha function to apply.</param>
494         /// <since_tizen> 3 </since_tizen>
495         public void AnimateBy(View target, string property, object relativeValue, int startTime, int endTime, AlphaFunction alphaFunction = null)
496         {
497             Property _prop = PropertyHelper.GetPropertyFromString(target, property);
498
499             PropertyType propertyType = target.GetPropertyType(_prop.propertyIndex);
500             if(propertyType.Equals(PropertyType.Float))
501             {
502                 System.Type type = relativeValue.GetType();
503                 if (type.Equals(typeof(System.Int32)) || type.Equals(typeof(int)))
504                 {
505                     int num = (int)relativeValue;
506                     relativeValue = (float)num;
507                 }
508             }
509
510             PropertyValue val = PropertyValue.CreateFromObject(relativeValue);
511
512             if (alphaFunction != null)
513             {
514                 Tizen.NUI.TimePeriod time = new Tizen.NUI.TimePeriod(MilliSecondsToSeconds(startTime), MilliSecondsToSeconds(endTime - startTime));
515                 AnimateBy(_prop, val, alphaFunction, time);
516             }
517             else
518             {
519                 Tizen.NUI.TimePeriod time = new Tizen.NUI.TimePeriod(MilliSecondsToSeconds(startTime), MilliSecondsToSeconds(endTime - startTime));
520                 AnimateBy(_prop, val, time);
521             }
522         }
523
524         /// <summary>
525         /// Animates a property to a destination value.<br />
526         /// </summary>
527         /// <param name="target">The target object to animate.</param>
528         /// <param name="property">The target property to animate.</param>
529         /// <param name="destinationValue">The destination value.</param>
530         /// <param name="alphaFunction">The alpha function to apply.</param>
531         /// <since_tizen> 3 </since_tizen>
532         public void AnimateTo(View target, string property, object destinationValue, AlphaFunction alphaFunction = null)
533         {
534             Property _prop = PropertyHelper.GetPropertyFromString(target, property);
535
536             PropertyType propertyType = target.GetPropertyType(_prop.propertyIndex);
537             if(propertyType.Equals(PropertyType.Float))
538             {
539                 System.Type type = destinationValue.GetType();
540                 if (type.Equals(typeof(System.Int32)) || type.Equals(typeof(int)))
541                 {
542                     int num = (int)destinationValue;
543                     destinationValue = (float)num;
544                 }
545             }
546
547             PropertyValue val = PropertyValue.CreateFromObject(destinationValue);
548
549             if (alphaFunction != null)
550             {
551                 AnimateTo(_prop, val, alphaFunction);
552             }
553             else
554             {
555                 AnimateTo(_prop, val);
556             }
557         }
558
559         /// <summary>
560         /// Animates a property to a destination value.<br />
561         /// </summary>
562         /// <param name="target">The target object to animate.</param>
563         /// <param name="property">The target property to animate.</param>
564         /// <param name="destinationValue">The destination value.</param>
565         /// <param name="startTime">The start time of the animation.</param>
566         /// <param name="endTime">The end time of the animation.</param>
567         /// <param name="alphaFunction">The alpha function to apply.</param>
568         /// <since_tizen> 3 </since_tizen>
569         public void AnimateTo(View target, string property, object destinationValue, int startTime, int endTime, AlphaFunction alphaFunction = null)
570         {
571             Property _prop = PropertyHelper.GetPropertyFromString(target, property);
572
573             PropertyType propertyType = target.GetPropertyType(_prop.propertyIndex);
574             if(propertyType.Equals(PropertyType.Float))
575             {
576                 System.Type type = destinationValue.GetType();
577                 if (type.Equals(typeof(System.Int32)) || type.Equals(typeof(int)))
578                 {
579                     int num = (int)destinationValue;
580                     destinationValue = (float)num;
581                 }
582             }
583
584             PropertyValue val = PropertyValue.CreateFromObject(destinationValue);
585
586             if (alphaFunction != null)
587             {
588                 Tizen.NUI.TimePeriod time = new Tizen.NUI.TimePeriod(MilliSecondsToSeconds(startTime), MilliSecondsToSeconds(endTime - startTime));
589                 AnimateTo(_prop, val, alphaFunction, time);
590             }
591             else
592             {
593                 Tizen.NUI.TimePeriod time = new Tizen.NUI.TimePeriod(MilliSecondsToSeconds(startTime), MilliSecondsToSeconds(endTime - startTime));
594                 AnimateTo(_prop, val, time);
595             }
596         }
597
598         /// <summary>
599         /// Animates a property between keyframes.
600         /// </summary>
601         /// <param name="target">The target object to animate.</param>
602         /// <param name="property">The target property to animate.</param>
603         /// <param name="keyFrames">The set of time or value pairs between which to animate.</param>
604         /// <param name="interpolation">The method used to interpolate between values.</param>
605         /// <param name="alphaFunction">The alpha function to apply.</param>
606         /// <since_tizen> 3 </since_tizen>
607         public void AnimateBetween(View target, string property, KeyFrames keyFrames, Interpolation interpolation = Interpolation.Linear, AlphaFunction alphaFunction = null)
608         {
609             Property _prop = PropertyHelper.GetPropertyFromString(target, property);
610
611             if (_prop.propertyIndex == Property.INVALID_INDEX)
612             {
613                 throw new System.ArgumentException("second argument string property is invalid parameter!");
614             }
615
616             if (alphaFunction != null)
617             {
618                 AnimateBetween(_prop, keyFrames, alphaFunction, interpolation);
619             }
620             else
621             {
622                 AnimateBetween(_prop, keyFrames, interpolation);
623             }
624         }
625
626
627         /// <summary>
628         /// Animates a property between keyframes.
629         /// </summary>
630         /// <param name="target">The target object to animate</param>
631         /// <param name="property">The target property to animate</param>
632         /// <param name="keyFrames">The set of time/value pairs between which to animate</param>
633         /// <param name="startTime">The start time of animation in milliseconds.</param>
634         /// <param name="endTime">The end time of animation in milliseconds.</param>
635         /// <param name="interpolation">The method used to interpolate between values.</param>
636         /// <param name="alphaFunction">The alpha function to apply.</param>
637         /// <since_tizen> 3 </since_tizen>
638         public void AnimateBetween(View target, string property, KeyFrames keyFrames, int startTime, int endTime, Interpolation interpolation = Interpolation.Linear, AlphaFunction alphaFunction = null)
639         {
640             Property _prop = PropertyHelper.GetPropertyFromString(target, property);
641
642             Tizen.NUI.TimePeriod time = new Tizen.NUI.TimePeriod(MilliSecondsToSeconds(startTime), MilliSecondsToSeconds(endTime - startTime));
643             if (alphaFunction != null)
644             {
645                 AnimateBetween(_prop, keyFrames, alphaFunction, time, interpolation);
646             }
647             else
648             {
649                 AnimateBetween(_prop, keyFrames, time, interpolation);
650             }
651         }
652
653         /// <summary>
654         /// Animates the view's position and orientation through a predefined path.<br />
655         /// The view will rotate to orient the supplied forward vector with the path's tangent.<br />
656         /// If forward is the zero vector then no rotation will happen.<br />
657         /// </summary>
658         /// <param name="view">The view to animate.</param>
659         /// <param name="path">It defines position and orientation.</param>
660         /// <param name="forward">The vector (in local space coordinate system) will be oriented with the path's tangent direction.</param>
661         /// <param name="alphaFunction">The alpha function to apply.</param>
662         /// <since_tizen> 3 </since_tizen>
663         public void AnimatePath(View view, Path path, Vector3 forward, AlphaFunction alphaFunction = null)
664         {
665             if (alphaFunction == null)
666             {
667                 Animate(view, path, forward);
668             }
669             else
670             {
671                 Animate(view, path, forward, alphaFunction);
672             }
673         }
674
675         /// <summary>
676         /// Animates the view's position and orientation through a predefined path.<br />
677         /// The view will rotate to orient the supplied forward vector with the path's tangent.<br />
678         /// If forward is the zero vector then no rotation will happen.<br />
679         /// </summary>
680         /// <param name="view">The view to animate.</param>
681         /// <param name="path">It defines position and orientation.</param>
682         /// <param name="forward">The vector (in local space coordinate system) will be oriented with the path's tangent direction.</param>
683         /// <param name="startTime">The start time of the animation.</param>
684         /// <param name="endTime">The end time of the animation.</param>
685         /// <param name="alphaFunction">The alpha function to apply.</param>
686         /// <since_tizen> 3 </since_tizen>
687         public void AnimatePath(View view, Path path, Vector3 forward, int startTime, int endTime, AlphaFunction alphaFunction = null)
688         {
689             TimePeriod time = new TimePeriod(MilliSecondsToSeconds(startTime), MilliSecondsToSeconds(endTime - startTime));
690             if (alphaFunction == null)
691             {
692                 Animate(view, path, forward, time);
693             }
694             else
695             {
696                 Animate(view, path, forward, alphaFunction, time);
697             }
698         }
699
700         /// <summary>
701         /// Creates an initialized animation.<br />
702         /// The animation will not loop.<br />
703         /// The default end action is "Cancel".<br />
704         /// The default alpha function is linear.<br />
705         /// </summary>
706         /// <since_tizen> 3 </since_tizen>
707         public Animation() : this(NDalicPINVOKE.Animation_New(0.0f), true)
708         {
709             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
710         }
711
712         internal Animation(float durationSeconds) : this(NDalicPINVOKE.Animation_New(durationSeconds), true)
713         {
714             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
715
716         }
717
718         /// <summary>
719         /// Downcasts a handle to animation handle.<br />
720         /// If handle points to an animation object, the downcast produces a valid handle.<br />
721         /// If not, the returned handle is left uninitialized.<br />
722         /// </summary>
723         /// <param name="handle">Handle to an object.</param>
724         /// <returns>Handle to an animation object or an uninitialized handle.</returns>
725         /// <since_tizen> 3 </since_tizen>
726         public static Animation DownCast(BaseHandle handle)
727         {
728             Animation ret =  Registry.GetManagedBaseHandleFromNativePtr(handle) as Animation;
729             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
730             return ret;
731         }
732
733         internal Animation(Animation handle) : this(NDalicPINVOKE.new_Animation__SWIG_1(Animation.getCPtr(handle)), true)
734         {
735             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
736         }
737
738         internal Animation Assign(Animation rhs)
739         {
740             Animation ret = new Animation(NDalicPINVOKE.Animation_Assign(swigCPtr, Animation.getCPtr(rhs)), false);
741             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
742             return ret;
743         }
744
745         internal void SetDuration(float seconds)
746         {
747             NDalicPINVOKE.Animation_SetDuration(swigCPtr, seconds);
748             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
749         }
750
751         internal float GetDuration()
752         {
753             float ret = NDalicPINVOKE.Animation_GetDuration(swigCPtr);
754             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
755             return ret;
756         }
757
758         internal void SetLooping(bool looping)
759         {
760             NDalicPINVOKE.Animation_SetLooping(swigCPtr, looping);
761             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
762         }
763
764         internal void SetLoopCount(int count)
765         {
766             NDalicPINVOKE.Animation_SetLoopCount(swigCPtr, count);
767             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
768         }
769
770         internal int GetLoopCount()
771         {
772             int ret = NDalicPINVOKE.Animation_GetLoopCount(swigCPtr);
773             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
774             return ret;
775         }
776
777         internal int GetCurrentLoop()
778         {
779             int ret = NDalicPINVOKE.Animation_GetCurrentLoop(swigCPtr);
780             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
781             return ret;
782         }
783
784         internal bool IsLooping()
785         {
786             bool ret = NDalicPINVOKE.Animation_IsLooping(swigCPtr);
787             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
788             return ret;
789         }
790
791         internal void SetEndAction(Animation.EndActions action)
792         {
793             NDalicPINVOKE.Animation_SetEndAction(swigCPtr, (int)action);
794             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
795         }
796
797         internal Animation.EndActions GetEndAction()
798         {
799             Animation.EndActions ret = (Animation.EndActions)NDalicPINVOKE.Animation_GetEndAction(swigCPtr);
800             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
801             return ret;
802         }
803
804         internal void SetDisconnectAction(Animation.EndActions disconnectAction)
805         {
806             NDalicPINVOKE.Animation_SetDisconnectAction(swigCPtr, (int)disconnectAction);
807             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
808         }
809
810         internal Animation.EndActions GetDisconnectAction()
811         {
812             Animation.EndActions ret = (Animation.EndActions)NDalicPINVOKE.Animation_GetDisconnectAction(swigCPtr);
813             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
814             return ret;
815         }
816
817         internal void SetDefaultAlphaFunction(AlphaFunction alpha)
818         {
819             NDalicPINVOKE.Animation_SetDefaultAlphaFunction(swigCPtr, AlphaFunction.getCPtr(alpha));
820             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
821         }
822
823         internal AlphaFunction GetDefaultAlphaFunction()
824         {
825             AlphaFunction ret = new AlphaFunction(NDalicPINVOKE.Animation_GetDefaultAlphaFunction(swigCPtr), true);
826             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
827             return ret;
828         }
829
830         internal void SetCurrentProgress(float progress)
831         {
832             NDalicPINVOKE.Animation_SetCurrentProgress(swigCPtr, progress);
833             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
834         }
835
836         internal float GetCurrentProgress()
837         {
838             float ret = NDalicPINVOKE.Animation_GetCurrentProgress(swigCPtr);
839             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
840             return ret;
841         }
842
843         internal void SetSpeedFactor(float factor)
844         {
845             NDalicPINVOKE.Animation_SetSpeedFactor(swigCPtr, factor);
846             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
847         }
848
849         internal float GetSpeedFactor()
850         {
851             float ret = NDalicPINVOKE.Animation_GetSpeedFactor(swigCPtr);
852             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
853             return ret;
854         }
855
856         internal void SetPlayRange(Vector2 range)
857         {
858             NDalicPINVOKE.Animation_SetPlayRange(swigCPtr, Vector2.getCPtr(range));
859             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
860         }
861
862         internal Vector2 GetPlayRange()
863         {
864             Vector2 ret = new Vector2(NDalicPINVOKE.Animation_GetPlayRange(swigCPtr), true);
865             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
866             return ret;
867         }
868
869         private static bool? disableAnimation = null;
870         private bool DisableAnimation
871         {
872             get
873             {
874                 if (disableAnimation.HasValue == false)
875                 {
876                     string type = Environment.GetEnvironmentVariable("PlatformSmartType");
877                     if (type == "Entry")
878                         disableAnimation = true;
879                     else
880                         disableAnimation = false;
881                 }
882                 return disableAnimation.Value;
883             }
884         }
885
886         /// <summary>
887         /// Plays the animation.
888         /// </summary>
889         /// <since_tizen> 3 </since_tizen>
890         public void Play()
891         {
892             NDalicPINVOKE.Animation_Play(swigCPtr);
893             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
894
895             if (DisableAnimation == true)
896                 Stop(EndActions.StopFinal);
897         }
898
899         /// <summary>
900         /// Plays the animation from a given point.<br />
901         /// The progress must be in the 0-1 interval or in the play range interval if defined,
902         /// otherwise, it will be ignored.<br />
903         /// </summary>
904         /// <param name="progress">A value between [0,1], or between the play range if specified, from where the animation should start playing.</param>
905         /// <since_tizen> 3 </since_tizen>
906         public void PlayFrom(float progress)
907         {
908             NDalicPINVOKE.Animation_PlayFrom(swigCPtr, progress);
909             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
910         }
911
912         /// <summary>
913         /// Plays the animation after a given delay time.<br/>
914         /// The delay time is not included in the looping time.<br/>
915         /// When the delay time is a negative value, it would treat as play immediately.<br/>
916         /// </summary>
917         /// <param name="delayMilliseconds">The delay time.</param>
918         /// <since_tizen> 4 </since_tizen>
919         public void PlayAfter(int delayMilliseconds)
920         {
921             NDalicPINVOKE.Animation_PlayAfter(swigCPtr, MilliSecondsToSeconds(delayMilliseconds));
922             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
923         }
924
925         /// <summary>
926         /// Pauses the animation.
927         /// </summary>
928         /// <since_tizen> 3 </since_tizen>
929         public void Pause()
930         {
931             NDalicPINVOKE.Animation_Pause(swigCPtr);
932             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
933         }
934
935         internal Animation.States GetState()
936         {
937             Animation.States ret = (Animation.States)NDalicPINVOKE.Animation_GetState(swigCPtr);
938             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
939             return ret;
940         }
941
942         /// <summary>
943         /// Stops the animation.
944         /// </summary>
945         /// <since_tizen> 3 </since_tizen>
946         public void Stop()
947         {
948             NDalicPINVOKE.Animation_Stop(swigCPtr);
949             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
950         }
951
952         /// <summary>
953         /// Clears the animation.<br />
954         /// This disconnects any objects that were being animated, effectively stopping the animation.<br />
955         /// </summary>
956         /// <since_tizen> 3 </since_tizen>
957         public void Clear()
958         {
959             NDalicPINVOKE.Animation_Clear(swigCPtr);
960             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
961         }
962
963         internal AnimationSignal FinishedSignal()
964         {
965             AnimationSignal ret = new AnimationSignal(NDalicPINVOKE.Animation_FinishedSignal(swigCPtr), false);
966             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
967             return ret;
968         }
969
970         internal AnimationSignal ProgressReachedSignal()
971         {
972             AnimationSignal ret = new AnimationSignal(NDalicPINVOKE.Animation_ProgressReachedSignal(swigCPtr), false);
973             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
974             return ret;
975         }
976
977         internal void AnimateBy(Property target, PropertyValue relativeValue)
978         {
979             NDalicPINVOKE.Animation_AnimateBy__SWIG_0(swigCPtr, Property.getCPtr(target), PropertyValue.getCPtr(relativeValue));
980             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
981         }
982
983         internal void AnimateBy(Property target, PropertyValue relativeValue, AlphaFunction alpha)
984         {
985             NDalicPINVOKE.Animation_AnimateBy__SWIG_1(swigCPtr, Property.getCPtr(target), PropertyValue.getCPtr(relativeValue), AlphaFunction.getCPtr(alpha));
986             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
987         }
988
989         internal void AnimateBy(Property target, PropertyValue relativeValue, TimePeriod period)
990         {
991             NDalicPINVOKE.Animation_AnimateBy__SWIG_2(swigCPtr, Property.getCPtr(target), PropertyValue.getCPtr(relativeValue), TimePeriod.getCPtr(period));
992             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
993         }
994
995         internal void AnimateBy(Property target, PropertyValue relativeValue, AlphaFunction alpha, TimePeriod period)
996         {
997             NDalicPINVOKE.Animation_AnimateBy__SWIG_3(swigCPtr, Property.getCPtr(target), PropertyValue.getCPtr(relativeValue), AlphaFunction.getCPtr(alpha), TimePeriod.getCPtr(period));
998             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
999         }
1000
1001         internal void AnimateTo(Property target, PropertyValue destinationValue)
1002         {
1003             NDalicPINVOKE.Animation_AnimateTo__SWIG_0(swigCPtr, Property.getCPtr(target), PropertyValue.getCPtr(destinationValue));
1004             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1005         }
1006
1007         internal void AnimateTo(Property target, PropertyValue destinationValue, AlphaFunction alpha)
1008         {
1009             NDalicPINVOKE.Animation_AnimateTo__SWIG_1(swigCPtr, Property.getCPtr(target), PropertyValue.getCPtr(destinationValue), AlphaFunction.getCPtr(alpha));
1010             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1011         }
1012
1013         internal void AnimateTo(Property target, PropertyValue destinationValue, TimePeriod period)
1014         {
1015             NDalicPINVOKE.Animation_AnimateTo__SWIG_2(swigCPtr, Property.getCPtr(target), PropertyValue.getCPtr(destinationValue), TimePeriod.getCPtr(period));
1016             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1017         }
1018
1019         internal void AnimateTo(Property target, PropertyValue destinationValue, AlphaFunction alpha, TimePeriod period)
1020         {
1021             NDalicPINVOKE.Animation_AnimateTo__SWIG_3(swigCPtr, Property.getCPtr(target), PropertyValue.getCPtr(destinationValue), AlphaFunction.getCPtr(alpha), TimePeriod.getCPtr(period));
1022             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1023         }
1024
1025         internal void AnimateBetween(Property target, KeyFrames keyFrames)
1026         {
1027             NDalicPINVOKE.Animation_AnimateBetween__SWIG_0(swigCPtr, Property.getCPtr(target), KeyFrames.getCPtr(keyFrames));
1028             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1029         }
1030
1031         internal void AnimateBetween(Property target, KeyFrames keyFrames, Animation.Interpolation interpolation)
1032         {
1033             NDalicPINVOKE.Animation_AnimateBetween__SWIG_1(swigCPtr, Property.getCPtr(target), KeyFrames.getCPtr(keyFrames), (int)interpolation);
1034             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1035         }
1036
1037         internal void AnimateBetween(Property target, KeyFrames keyFrames, AlphaFunction alpha)
1038         {
1039             NDalicPINVOKE.Animation_AnimateBetween__SWIG_2(swigCPtr, Property.getCPtr(target), KeyFrames.getCPtr(keyFrames), AlphaFunction.getCPtr(alpha));
1040             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1041         }
1042
1043         internal void AnimateBetween(Property target, KeyFrames keyFrames, AlphaFunction alpha, Animation.Interpolation interpolation)
1044         {
1045             NDalicPINVOKE.Animation_AnimateBetween__SWIG_3(swigCPtr, Property.getCPtr(target), KeyFrames.getCPtr(keyFrames), AlphaFunction.getCPtr(alpha), (int)interpolation);
1046             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1047         }
1048
1049         internal void AnimateBetween(Property target, KeyFrames keyFrames, TimePeriod period)
1050         {
1051             NDalicPINVOKE.Animation_AnimateBetween__SWIG_4(swigCPtr, Property.getCPtr(target), KeyFrames.getCPtr(keyFrames), TimePeriod.getCPtr(period));
1052             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1053         }
1054
1055         internal void AnimateBetween(Property target, KeyFrames keyFrames, TimePeriod period, Animation.Interpolation interpolation)
1056         {
1057             NDalicPINVOKE.Animation_AnimateBetween__SWIG_5(swigCPtr, Property.getCPtr(target), KeyFrames.getCPtr(keyFrames), TimePeriod.getCPtr(period), (int)interpolation);
1058             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1059         }
1060
1061         internal void AnimateBetween(Property target, KeyFrames keyFrames, AlphaFunction alpha, TimePeriod period)
1062         {
1063             NDalicPINVOKE.Animation_AnimateBetween__SWIG_6(swigCPtr, Property.getCPtr(target), KeyFrames.getCPtr(keyFrames), AlphaFunction.getCPtr(alpha), TimePeriod.getCPtr(period));
1064             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1065         }
1066
1067         internal void AnimateBetween(Property target, KeyFrames keyFrames, AlphaFunction alpha, TimePeriod period, Animation.Interpolation interpolation)
1068         {
1069             NDalicPINVOKE.Animation_AnimateBetween__SWIG_7(swigCPtr, Property.getCPtr(target), KeyFrames.getCPtr(keyFrames), AlphaFunction.getCPtr(alpha), TimePeriod.getCPtr(period), (int)interpolation);
1070             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1071         }
1072
1073         internal void Animate(View view, Path path, Vector3 forward)
1074         {
1075             NDalicPINVOKE.Animation_Animate__SWIG_0(swigCPtr, View.getCPtr(view), Path.getCPtr(path), Vector3.getCPtr(forward));
1076             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1077         }
1078
1079         internal void Animate(View view, Path path, Vector3 forward, AlphaFunction alpha)
1080         {
1081             NDalicPINVOKE.Animation_Animate__SWIG_1(swigCPtr, View.getCPtr(view), Path.getCPtr(path), Vector3.getCPtr(forward), AlphaFunction.getCPtr(alpha));
1082             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1083         }
1084
1085         internal void Animate(View view, Path path, Vector3 forward, TimePeriod period)
1086         {
1087             NDalicPINVOKE.Animation_Animate__SWIG_2(swigCPtr, View.getCPtr(view), Path.getCPtr(path), Vector3.getCPtr(forward), TimePeriod.getCPtr(period));
1088             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1089         }
1090
1091         internal void Animate(View view, Path path, Vector3 forward, AlphaFunction alpha, TimePeriod period)
1092         {
1093             NDalicPINVOKE.Animation_Animate__SWIG_3(swigCPtr, View.getCPtr(view), Path.getCPtr(path), Vector3.getCPtr(forward), AlphaFunction.getCPtr(alpha), TimePeriod.getCPtr(period));
1094             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1095         }
1096
1097         internal void Show(View view, float delaySeconds)
1098         {
1099             NDalicPINVOKE.Animation_Show(swigCPtr, View.getCPtr(view), delaySeconds);
1100             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1101         }
1102
1103         internal void Hide(View view, float delaySeconds)
1104         {
1105             NDalicPINVOKE.Animation_Hide(swigCPtr, View.getCPtr(view), delaySeconds);
1106             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1107         }
1108
1109         /// <summary>
1110         /// Enumeration for what to do when the animation ends, stopped, or destroyed.
1111         /// </summary>
1112         /// <since_tizen> 3 </since_tizen>
1113         public enum EndActions
1114         {
1115             /// <summary>
1116             /// When the animation ends, the animated property values are saved.
1117             /// </summary>
1118             Cancel,
1119             /// <summary>
1120             /// When the animation ends, the animated property values are forgotten.
1121             /// </summary>
1122             Discard,
1123             /// <summary>
1124             /// If the animation is stopped, the animated property values are saved as if the animation had run to completion, otherwise behaves like cancel.
1125             /// </summary>
1126             StopFinal
1127         }
1128
1129         /// <summary>
1130         /// Enumeration for what interpolation method to use on key-frame animations.
1131         /// </summary>
1132         /// <since_tizen> 3 </since_tizen>
1133         public enum Interpolation
1134         {
1135             /// <summary>
1136             /// Values in between key frames are interpolated using a linear polynomial. (Default)
1137             /// </summary>
1138             Linear,
1139             /// <summary>
1140             /// Values in between key frames are interpolated using a cubic polynomial.
1141             /// </summary>
1142             Cubic
1143         }
1144
1145         /// <summary>
1146         /// Enumeration for what state the animation is in.
1147         /// </summary>
1148         /// <remarks>Calling Reset() on this class will not reset the animation. It will call the BaseHandle.Reset() which drops the object handle.</remarks>
1149         /// <since_tizen> 3 </since_tizen>
1150         public enum States
1151         {
1152             /// <summary>
1153             /// The animation has stopped.
1154             /// </summary>
1155             Stopped,
1156             /// <summary>
1157             /// The animation is playing.
1158             /// </summary>
1159             Playing,
1160             /// <summary>
1161             /// The animation is paused.
1162             /// </summary>
1163             Paused
1164         }
1165
1166     }
1167
1168 }