Release 4.0.0-preview1-00301
[platform/core/csapi/tizenfx.git] / src / Tizen.NUI / src / public / UIComponents / ScrollView.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     /// ScrollView contains views that can be scrolled manually (via touch).
27     /// </summary>
28     public class ScrollView : Scrollable
29     {
30         private global::System.Runtime.InteropServices.HandleRef swigCPtr;
31
32         internal ScrollView(global::System.IntPtr cPtr, bool cMemoryOwn) : base(NDalicPINVOKE.ScrollView_SWIGUpcast(cPtr), cMemoryOwn)
33         {
34             swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
35         }
36
37         internal static global::System.Runtime.InteropServices.HandleRef getCPtr(ScrollView obj)
38         {
39             return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
40         }
41
42         /// <summary>
43         /// Dispose
44         /// </summary>
45         /// <param name="type">the dispose type</param>
46         /// <since_tizen> 3 </since_tizen>
47         protected override void Dispose(DisposeTypes type)
48         {
49             if (disposed)
50             {
51                 return;
52             }
53
54             if (type == DisposeTypes.Explicit)
55             {
56                 //Called by User
57                 //Release your own managed resources here.
58                 //You should release all of your own disposable objects here.
59
60             }
61
62             //Release your own unmanaged resources here.
63             //You should not access any managed member here except static instance.
64             //because the execution order of Finalizes is non-deterministic.
65
66             if (_scrollViewSnapStartedCallbackDelegate != null)
67             {
68                 this.SnapStartedSignal().Disconnect(_scrollViewSnapStartedCallbackDelegate);
69             }
70
71             if (swigCPtr.Handle != global::System.IntPtr.Zero)
72             {
73                 if (swigCMemOwn)
74                 {
75                     swigCMemOwn = false;
76                     NDalicPINVOKE.delete_ScrollView(swigCPtr);
77                 }
78                 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
79             }
80
81             base.Dispose(type);
82         }
83
84         /// <summary>
85         /// Event arguments that passed via the SnapStarted signal.
86         /// </summary>
87         public class SnapStartedEventArgs : EventArgs
88         {
89             private Tizen.NUI.ScrollView.SnapEvent _snapEvent;
90
91             /// <summary>
92             /// SnapEventInfo is the SnapEvent information like snap or flick (it tells the target position, scale, rotation for the snap or flick).
93             /// </summary>
94             /// <since_tizen> 3 </since_tizen>
95             public Tizen.NUI.ScrollView.SnapEvent SnapEventInfo
96             {
97                 get
98                 {
99                     return _snapEvent;
100                 }
101                 set
102                 {
103                     _snapEvent = value;
104                 }
105             }
106         }
107
108         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
109         private delegate void SnapStartedCallbackDelegate(IntPtr data);
110         private DaliEventHandler<object, SnapStartedEventArgs> _scrollViewSnapStartedEventHandler;
111         private SnapStartedCallbackDelegate _scrollViewSnapStartedCallbackDelegate;
112
113         /// <summary>
114         /// SnapStarted can be used to subscribe or unsubscribe the event handler
115         /// The SnapStarted signal is emitted when the ScrollView has started to snap or flick (it tells the target
116         ///  position, scale, rotation for the snap or flick).
117         /// </summary>
118         /// <since_tizen> 3 </since_tizen>
119         public event DaliEventHandler<object, SnapStartedEventArgs> SnapStarted
120         {
121             add
122             {
123                 lock (this)
124                 {
125                     // Restricted to only one listener
126                     if (_scrollViewSnapStartedEventHandler == null)
127                     {
128                         _scrollViewSnapStartedEventHandler += value;
129
130                         _scrollViewSnapStartedCallbackDelegate = new SnapStartedCallbackDelegate(OnSnapStarted);
131                         this.SnapStartedSignal().Connect(_scrollViewSnapStartedCallbackDelegate);
132                     }
133                 }
134             }
135
136             remove
137             {
138                 lock (this)
139                 {
140                     if (_scrollViewSnapStartedEventHandler != null)
141                     {
142                         this.SnapStartedSignal().Disconnect(_scrollViewSnapStartedCallbackDelegate);
143                     }
144
145                     _scrollViewSnapStartedEventHandler -= value;
146                 }
147             }
148         }
149
150         // Callback for ScrollView SnapStarted signal
151         private void OnSnapStarted(IntPtr data)
152         {
153             SnapStartedEventArgs e = new SnapStartedEventArgs();
154
155             // Populate all members of "e" (SnapStartedEventArgs) with real data
156             e.SnapEventInfo = SnapEvent.GetSnapEventFromPtr(data);
157
158             if (_scrollViewSnapStartedEventHandler != null)
159             {
160                 //here we send all data to user event handlers
161                 _scrollViewSnapStartedEventHandler(this, e);
162             }
163         }
164
165         /// <summary>
166         /// Snaps signal event's data.
167         /// </summary>
168         public class SnapEvent : global::System.IDisposable
169         {
170             private global::System.Runtime.InteropServices.HandleRef swigCPtr;
171             /// <summary>
172             /// swigCMemOwn
173             /// </summary>
174             /// <since_tizen> 3 </since_tizen>
175             protected bool swigCMemOwn;
176
177             internal SnapEvent(global::System.IntPtr cPtr, bool cMemoryOwn)
178             {
179                 swigCMemOwn = cMemoryOwn;
180                 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
181             }
182
183             internal static global::System.Runtime.InteropServices.HandleRef getCPtr(SnapEvent obj)
184             {
185                 return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
186             }
187
188             //A Flag to check who called Dispose(). (By User or DisposeQueue)
189             private bool isDisposeQueued = false;
190             /// <summary>
191             /// A Flat to check if it is already disposed.
192             /// </summary>
193             /// swigCMemOwn
194             protected bool disposed = false;
195
196             /// <summary>
197             /// Dispose
198             /// </summary>
199             /// <since_tizen> 3 </since_tizen>
200             ~SnapEvent()
201             {
202                 if (!isDisposeQueued)
203                 {
204                     isDisposeQueued = true;
205                     DisposeQueue.Instance.Add(this);
206                 }
207             }
208
209             /// <summary>
210             /// Dispose.
211             /// </summary>
212             /// <since_tizen> 3 </since_tizen>
213             public void Dispose()
214             {
215                 //Throw excpetion if Dispose() is called in separate thread.
216                 if (!Window.IsInstalled())
217                 {
218                     throw new System.InvalidOperationException("This API called from separate thread. This API must be called from MainThread.");
219                 }
220
221                 if (isDisposeQueued)
222                 {
223                     Dispose(DisposeTypes.Implicit);
224                 }
225                 else
226                 {
227                     Dispose(DisposeTypes.Explicit);
228                     System.GC.SuppressFinalize(this);
229                 }
230             }
231
232             /// <summary>
233             /// Dispose
234             /// </summary>
235             /// <param name="type">the dispose type</param>
236             /// <since_tizen> 3 </since_tizen>
237             protected virtual void Dispose(DisposeTypes type)
238             {
239                 if (disposed)
240                 {
241                     return;
242                 }
243
244                 if (type == DisposeTypes.Explicit)
245                 {
246                     //Called by User
247                     //Release your own managed resources here.
248                     //You should release all of your own disposable objects here.
249
250                 }
251
252                 //Release your own unmanaged resources here.
253                 //You should not access any managed member here except static instance.
254                 //because the execution order of Finalizes is non-deterministic.
255
256                 if (swigCPtr.Handle != global::System.IntPtr.Zero)
257                 {
258                     if (swigCMemOwn)
259                     {
260                         swigCMemOwn = false;
261                         NDalicPINVOKE.delete_ScrollView_SnapEvent(swigCPtr);
262                     }
263                     swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
264                 }
265
266                 disposed = true;
267             }
268
269             /// <summary>
270             /// Get SnapEvent From Ptr
271             /// </summary>
272             /// <since_tizen> 3 </since_tizen>
273             public static SnapEvent GetSnapEventFromPtr(global::System.IntPtr cPtr)
274             {
275                 SnapEvent ret = new SnapEvent(cPtr, false);
276                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
277                 return ret;
278             }
279
280             internal SnapType type
281             {
282                 set
283                 {
284                     NDalicPINVOKE.ScrollView_SnapEvent_type_set(swigCPtr, (int)value);
285                     if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
286                 }
287                 get
288                 {
289                     SnapType ret = (SnapType)NDalicPINVOKE.ScrollView_SnapEvent_type_get(swigCPtr);
290                     if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
291                     return ret;
292                 }
293             }
294
295             /// <summary>
296             /// Scroll position.
297             /// </summary>
298             /// <since_tizen> 3 </since_tizen>
299             public Vector2 position
300             {
301                 set
302                 {
303                     NDalicPINVOKE.ScrollView_SnapEvent_position_set(swigCPtr, Vector2.getCPtr(value));
304                     if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
305                 }
306                 get
307                 {
308                     global::System.IntPtr cPtr = NDalicPINVOKE.ScrollView_SnapEvent_position_get(swigCPtr);
309                     Vector2 ret = (cPtr == global::System.IntPtr.Zero) ? null : new Vector2(cPtr, false);
310                     if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
311                     return ret;
312                 }
313             }
314
315             /// <summary>
316             /// Scroll duration.
317             /// </summary>
318             /// <since_tizen> 3 </since_tizen>
319             public float duration
320             {
321                 set
322                 {
323                     NDalicPINVOKE.ScrollView_SnapEvent_duration_set(swigCPtr, value);
324                     if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
325                 }
326                 get
327                 {
328                     float ret = NDalicPINVOKE.ScrollView_SnapEvent_duration_get(swigCPtr);
329                     if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
330                     return ret;
331                 }
332             }
333
334             /// <summary>
335             /// Create an instance of SnapEvent.
336             /// </summary>
337             /// <since_tizen> 3 </since_tizen>
338             public SnapEvent() : this(NDalicPINVOKE.new_ScrollView_SnapEvent(), true)
339             {
340                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
341             }
342
343         }
344
345         /// <summary>
346         /// This should be internal, please do not use.
347         /// </summary>
348         /// <since_tizen> 3 </since_tizen>
349         public new class Property
350         {
351             /// <summary>
352             /// This should be internal, please do not use.
353             /// </summary>
354             /// <since_tizen> 3 </since_tizen>
355             public static readonly int WRAP_ENABLED = NDalicPINVOKE.ScrollView_Property_WRAP_ENABLED_get();
356             /// <summary>
357             /// This should be internal, please do not use.
358             /// </summary>
359             /// <since_tizen> 3 </since_tizen>
360             public static readonly int PANNING_ENABLED = NDalicPINVOKE.ScrollView_Property_PANNING_ENABLED_get();
361             /// <summary>
362             /// This should be internal, please do not use.
363             /// </summary>
364             /// <since_tizen> 3 </since_tizen>
365             public static readonly int AXIS_AUTO_LOCK_ENABLED = NDalicPINVOKE.ScrollView_Property_AXIS_AUTO_LOCK_ENABLED_get();
366             /// <summary>
367             /// This should be internal, please do not use.
368             /// </summary>
369             /// <since_tizen> 3 </since_tizen>
370             public static readonly int WHEEL_SCROLL_DISTANCE_STEP = NDalicPINVOKE.ScrollView_Property_WHEEL_SCROLL_DISTANCE_STEP_get();
371             /// <summary>
372             /// This should be internal, please do not use.
373             /// </summary>
374             /// <since_tizen> 3 </since_tizen>
375             public static readonly int SCROLL_MODE = NDalicPINVOKE.ScrollView_Property_SCROLL_MODE_get();
376             /// <summary>
377             /// This should be internal, please do not use.
378             /// </summary>
379             /// <since_tizen> 3 </since_tizen>
380             public static readonly int SCROLL_POSITION = NDalicPINVOKE.ScrollView_Property_SCROLL_POSITION_get();
381             /// <summary>
382             /// This should be internal, please do not use.
383             /// </summary>
384             /// <since_tizen> 3 </since_tizen>
385             public static readonly int SCROLL_PRE_POSITION = NDalicPINVOKE.ScrollView_Property_SCROLL_PRE_POSITION_get();
386             /// <summary>
387             /// This should be internal, please do not use.
388             /// </summary>
389             /// <since_tizen> 3 </since_tizen>
390             public static readonly int SCROLL_PRE_POSITION_X = NDalicPINVOKE.ScrollView_Property_SCROLL_PRE_POSITION_X_get();
391             /// <summary>
392             /// This should be internal, please do not use.
393             /// </summary>
394             /// <since_tizen> 3 </since_tizen>
395             public static readonly int SCROLL_PRE_POSITION_Y = NDalicPINVOKE.ScrollView_Property_SCROLL_PRE_POSITION_Y_get();
396             /// <summary>
397             /// This should be internal, please do not use.
398             /// </summary>
399             /// <since_tizen> 3 </since_tizen>
400             public static readonly int SCROLL_PRE_POSITION_MAX = NDalicPINVOKE.ScrollView_Property_SCROLL_PRE_POSITION_MAX_get();
401             /// <summary>
402             /// This should be internal, please do not use.
403             /// </summary>
404             /// <since_tizen> 3 </since_tizen>
405             public static readonly int SCROLL_PRE_POSITION_MAX_X = NDalicPINVOKE.ScrollView_Property_SCROLL_PRE_POSITION_MAX_X_get();
406             /// <summary>
407             /// This should be internal, please do not use.
408             /// </summary>
409             /// <since_tizen> 3 </since_tizen>
410             public static readonly int SCROLL_PRE_POSITION_MAX_Y = NDalicPINVOKE.ScrollView_Property_SCROLL_PRE_POSITION_MAX_Y_get();
411             /// <summary>
412             /// This should be internal, please do not use.
413             /// </summary>
414             /// <since_tizen> 3 </since_tizen>
415             public static readonly int OVERSHOOT_X = NDalicPINVOKE.ScrollView_Property_OVERSHOOT_X_get();
416             /// <summary>
417             /// This should be internal, please do not use.
418             /// </summary>
419             /// <since_tizen> 3 </since_tizen>
420             public static readonly int OVERSHOOT_Y = NDalicPINVOKE.ScrollView_Property_OVERSHOOT_Y_get();
421             /// <summary>
422             /// This should be internal, please do not use.
423             /// </summary>
424             /// <since_tizen> 3 </since_tizen>
425             public static readonly int SCROLL_FINAL = NDalicPINVOKE.ScrollView_Property_SCROLL_FINAL_get();
426             /// <summary>
427             /// This should be internal, please do not use.
428             /// </summary>
429             /// <since_tizen> 3 </since_tizen>
430             public static readonly int SCROLL_FINAL_X = NDalicPINVOKE.ScrollView_Property_SCROLL_FINAL_X_get();
431             /// <summary>
432             /// This should be internal, please do not use.
433             /// </summary>
434             /// <since_tizen> 3 </since_tizen>
435             public static readonly int SCROLL_FINAL_Y = NDalicPINVOKE.ScrollView_Property_SCROLL_FINAL_Y_get();
436             /// <summary>
437             /// This should be internal, please do not use.
438             /// </summary>
439             /// <since_tizen> 3 </since_tizen>
440             public static readonly int WRAP = NDalicPINVOKE.ScrollView_Property_WRAP_get();
441             /// <summary>
442             /// This should be internal, please do not use.
443             /// </summary>
444             /// <since_tizen> 3 </since_tizen>
445             public static readonly int PANNING = NDalicPINVOKE.ScrollView_Property_PANNING_get();
446             /// <summary>
447             /// This should be internal, please do not use.
448             /// </summary>
449             /// <since_tizen> 3 </since_tizen>
450             public static readonly int SCROLLING = NDalicPINVOKE.ScrollView_Property_SCROLLING_get();
451             /// <summary>
452             /// This should be internal, please do not use.
453             /// </summary>
454             /// <since_tizen> 3 </since_tizen>
455             public static readonly int SCROLL_DOMAIN_SIZE = NDalicPINVOKE.ScrollView_Property_SCROLL_DOMAIN_SIZE_get();
456             /// <summary>
457             /// This should be internal, please do not use.
458             /// </summary>
459             /// <since_tizen> 3 </since_tizen>
460             public static readonly int SCROLL_DOMAIN_SIZE_X = NDalicPINVOKE.ScrollView_Property_SCROLL_DOMAIN_SIZE_X_get();
461             /// <summary>
462             /// This should be internal, please do not use.
463             /// </summary>
464             /// <since_tizen> 3 </since_tizen>
465             public static readonly int SCROLL_DOMAIN_SIZE_Y = NDalicPINVOKE.ScrollView_Property_SCROLL_DOMAIN_SIZE_Y_get();
466             /// <summary>
467             /// This should be internal, please do not use.
468             /// </summary>
469             /// <since_tizen> 3 </since_tizen>
470             public static readonly int SCROLL_DOMAIN_OFFSET = NDalicPINVOKE.ScrollView_Property_SCROLL_DOMAIN_OFFSET_get();
471             /// <summary>
472             /// This should be internal, please do not use.
473             /// </summary>
474             /// <since_tizen> 3 </since_tizen>
475             public static readonly int SCROLL_POSITION_DELTA = NDalicPINVOKE.ScrollView_Property_SCROLL_POSITION_DELTA_get();
476             /// <summary>
477             /// This should be internal, please do not use.
478             /// </summary>
479             /// <since_tizen> 3 </since_tizen>
480             public static readonly int START_PAGE_POSITION = NDalicPINVOKE.ScrollView_Property_START_PAGE_POSITION_get();
481
482         }
483
484         /// <summary>
485         /// Create an instance of ScrollView.
486         /// </summary>
487         /// <since_tizen> 3 </since_tizen>
488         public ScrollView() : this(NDalicPINVOKE.ScrollView_New(), true)
489         {
490             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
491
492         }
493
494         /// <summary>
495         /// Gets snap-animation's AlphaFunction.
496         /// </summary>
497         /// <returns>Current easing alpha function of the snap animation.</returns>
498         /// <since_tizen> 3 </since_tizen>
499         public AlphaFunction GetScrollSnapAlphaFunction()
500         {
501             AlphaFunction ret = new AlphaFunction(NDalicPINVOKE.ScrollView_GetScrollSnapAlphaFunction(swigCPtr), true);
502             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
503             return ret;
504         }
505
506         /// <summary>
507         /// Sets snap-animation's AlphaFunction.
508         /// </summary>
509         /// <param name="alpha">Easing alpha function of the snap animation.</param>
510         /// <since_tizen> 3 </since_tizen>
511         public void SetScrollSnapAlphaFunction(AlphaFunction alpha)
512         {
513             NDalicPINVOKE.ScrollView_SetScrollSnapAlphaFunction(swigCPtr, AlphaFunction.getCPtr(alpha));
514             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
515         }
516
517         /// <summary>
518         /// Gets flick-animation's AlphaFunction.
519         /// </summary>
520         /// <returns>Current easing alpha function of the flick animation.</returns>
521         /// <since_tizen> 3 </since_tizen>
522         public AlphaFunction GetScrollFlickAlphaFunction()
523         {
524             AlphaFunction ret = new AlphaFunction(NDalicPINVOKE.ScrollView_GetScrollFlickAlphaFunction(swigCPtr), true);
525             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
526             return ret;
527         }
528
529         /// <summary>
530         /// Sets flick-animation's AlphaFunction.
531         /// </summary>
532         /// <param name="alpha">Easing alpha function of the flick animation.</param>
533         /// <since_tizen> 3 </since_tizen>
534         public void SetScrollFlickAlphaFunction(AlphaFunction alpha)
535         {
536             NDalicPINVOKE.ScrollView_SetScrollFlickAlphaFunction(swigCPtr, AlphaFunction.getCPtr(alpha));
537             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
538         }
539
540         /// <summary>
541         /// Gets the time for the scroll snap-animation.
542         /// </summary>
543         /// <returns>The time in seconds for the animation to take.</returns>
544         /// <since_tizen> 3 </since_tizen>
545         public float GetScrollSnapDuration()
546         {
547             float ret = NDalicPINVOKE.ScrollView_GetScrollSnapDuration(swigCPtr);
548             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
549             return ret;
550         }
551
552         /// <summary>
553         /// Sets the time for the scroll snap-animation.
554         /// </summary>
555         /// <param name="time">The time in seconds for the animation to take.</param>
556         /// <since_tizen> 3 </since_tizen>
557         public void SetScrollSnapDuration(float time)
558         {
559             NDalicPINVOKE.ScrollView_SetScrollSnapDuration(swigCPtr, time);
560             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
561         }
562
563         /// <summary>
564         /// Gets the time for the scroll flick-animation.
565         /// </summary>
566         /// <returns>The time in seconds for the animation to take.</returns>
567         /// <since_tizen> 3 </since_tizen>
568         public float GetScrollFlickDuration()
569         {
570             float ret = NDalicPINVOKE.ScrollView_GetScrollFlickDuration(swigCPtr);
571             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
572             return ret;
573         }
574
575         /// <summary>
576         /// Sets the time for the scroll snap-animation.
577         /// </summary>
578         /// <param name="time">The time in seconds for the animation to take.</param>
579         /// <since_tizen> 3 </since_tizen>
580         public void SetScrollFlickDuration(float time)
581         {
582             NDalicPINVOKE.ScrollView_SetScrollFlickDuration(swigCPtr, time);
583             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
584         }
585
586         /// <summary>
587         /// Sets scroll sensibility of pan gesture.
588         /// </summary>
589         /// <param name="sensitive">True to enable scroll, false to disable scrolling.</param>
590         /// <since_tizen> 3 </since_tizen>
591         public void SetScrollSensitive(bool sensitive)
592         {
593             NDalicPINVOKE.ScrollView_SetScrollSensitive(swigCPtr, sensitive);
594             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
595         }
596
597         /// <summary>
598         /// Sets maximum overshoot amount.
599         /// </summary>
600         /// <param name="overshootX">The maximum number of horizontally scrolled pixels before overshoot X reaches 1.0f.</param>
601         /// <param name="overshootY">The maximum number of vertically scrolled pixels before overshoot X reaches 1.0f.</param>
602         /// <since_tizen> 3 </since_tizen>
603         public void SetMaxOvershoot(float overshootX, float overshootY)
604         {
605             NDalicPINVOKE.ScrollView_SetMaxOvershoot(swigCPtr, overshootX, overshootY);
606             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
607         }
608
609         /// <summary>
610         /// Sets Snap Overshoot animation's AlphaFunction.
611         /// </summary>
612         /// <param name="alpha">Easing alpha function of the overshoot snap animation.</param>
613         /// <since_tizen> 3 </since_tizen>
614         public void SetSnapOvershootAlphaFunction(AlphaFunction alpha)
615         {
616             NDalicPINVOKE.ScrollView_SetSnapOvershootAlphaFunction(swigCPtr, AlphaFunction.getCPtr(alpha));
617             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
618         }
619
620         /// <summary>
621         /// Sets Snap Overshoot animation's Duration.
622         /// </summary>
623         /// <param name="duration">duration The duration of the overshoot snap animation.</param>
624         /// <since_tizen> 3 </since_tizen>
625         public void SetSnapOvershootDuration(float duration)
626         {
627             NDalicPINVOKE.ScrollView_SetSnapOvershootDuration(swigCPtr, duration);
628             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
629         }
630
631         /// <summary>
632         /// Enables or Disables Actor Auto-Snap mode.<br />
633         /// When Actor Auto-Snap mode has been enabled, ScrollView will automatically,
634         /// snap to the closest actor (The closest actor will appear in the center of the ScrollView).
635         /// </summary>
636         /// <param name="enable">Enables (true), or disables (false) Actor AutoSnap.</param>
637         /// <since_tizen> 3 </since_tizen>
638         public void SetViewAutoSnap(bool enable)
639         {
640             NDalicPINVOKE.ScrollView_SetActorAutoSnap(swigCPtr, enable);
641             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
642         }
643
644         /// <summary>
645         /// Enables or Disables Wrap mode for ScrollView contents.<br />
646         /// When enabled, the ScrollView contents are wrapped over the X/Y Domain.
647         /// </summary>
648         /// <param name="enable">Enables (true), or disables (false) Wrap Mode.</param>
649         /// <since_tizen> 3 </since_tizen>
650         public void SetWrapMode(bool enable)
651         {
652             NDalicPINVOKE.ScrollView_SetWrapMode(swigCPtr, enable);
653             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
654         }
655
656         /// <summary>
657         /// Gets the current distance needed to scroll for ScrollUpdatedSignal to be emitted.
658         /// </summary>
659         /// <returns>Current scroll update distance.</returns>
660         /// <since_tizen> 3 </since_tizen>
661         public int GetScrollUpdateDistance()
662         {
663             int ret = NDalicPINVOKE.ScrollView_GetScrollUpdateDistance(swigCPtr);
664             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
665             return ret;
666         }
667
668         /// <summary>
669         /// Sets the distance needed to scroll for ScrollUpdatedSignal to be emitted.<br />
670         /// The scroll update distance tells ScrollView how far to move before ScrollUpdatedSignal the informs application.<br />
671         /// Each time the ScrollView crosses this distance the signal will be emitted.<br />
672         /// </summary>
673         /// <param name="distance">The distance for ScrollView to move before emitting update signal.</param>
674         /// <since_tizen> 3 </since_tizen>
675         public void SetScrollUpdateDistance(int distance)
676         {
677             NDalicPINVOKE.ScrollView_SetScrollUpdateDistance(swigCPtr, distance);
678             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
679         }
680
681         /// <summary>
682         /// Returns state of Axis Auto Lock mode.
683         /// </summary>
684         /// <returns>Whether Axis Auto Lock mode has been enabled or not.</returns>
685         /// <since_tizen> 3 </since_tizen>
686         public bool GetAxisAutoLock()
687         {
688             bool ret = NDalicPINVOKE.ScrollView_GetAxisAutoLock(swigCPtr);
689             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
690             return ret;
691         }
692
693         /// <summary>
694         /// Enables or Disables Axis Auto Lock mode for panning within the ScrollView.<br />
695         /// When enabled, any pan gesture that appears mostly horizontal or mostly
696         /// vertical, will be automatically restricted to horizontal only or vertical
697         /// only panning, until the pan gesture has completed.
698         /// </summary>
699         /// <param name="enable">Enables (true), or disables (false) AxisAutoLock mode.</param>
700         /// <since_tizen> 3 </since_tizen>
701         public void SetAxisAutoLock(bool enable)
702         {
703             NDalicPINVOKE.ScrollView_SetAxisAutoLock(swigCPtr, enable);
704             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
705         }
706
707         /// <summary>
708         /// Gets the gradient threshold at which a panning gesture should be locked to the Horizontal or Vertical axis.
709         /// </summary>
710         /// <returns>The gradient, a value between 0.0 and 1.0f.</returns>
711         /// <since_tizen> 3 </since_tizen>
712         public float GetAxisAutoLockGradient()
713         {
714             float ret = NDalicPINVOKE.ScrollView_GetAxisAutoLockGradient(swigCPtr);
715             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
716             return ret;
717         }
718
719         /// <summary>
720         /// Sets the gradient threshold at which a panning gesture should be locked to the Horizontal or Vertical axis.<br />
721         /// By default, this is 0.36 (0.36:1) which means angles less than 20 degrees to an axis will lock to that axis.<br />
722         /// </summary>
723         /// <param name="gradient">gradient A value between 0.0 and 1.0 (auto-lock for all angles).</param>
724         /// <since_tizen> 3 </since_tizen>
725         public void SetAxisAutoLockGradient(float gradient)
726         {
727             NDalicPINVOKE.ScrollView_SetAxisAutoLockGradient(swigCPtr, gradient);
728             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
729         }
730
731         /// <summary>
732         /// Gets the friction coefficient setting for ScrollView when flicking in free panning mode.
733         /// This is a value in stage-diagonals per second^2, stage-diagonal = Length( stage.width, stage.height )
734         /// </summary>
735         /// <returns>Friction coefficient is returned.</returns>
736         /// <since_tizen> 3 </since_tizen>
737         public float GetFrictionCoefficient()
738         {
739             float ret = NDalicPINVOKE.ScrollView_GetFrictionCoefficient(swigCPtr);
740             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
741             return ret;
742         }
743
744         /// <summary>
745         /// Sets the friction coefficient for ScrollView when flicking.<br />
746         /// </summary>
747         /// <param name="friction">Friction coefficient must be greater than 0.0 (default = 1.0).</param>
748         /// <since_tizen> 3 </since_tizen>
749         public void SetFrictionCoefficient(float friction)
750         {
751             NDalicPINVOKE.ScrollView_SetFrictionCoefficient(swigCPtr, friction);
752             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
753         }
754
755         /// <summary>
756         /// Gets the flick speed coefficient for ScrollView when flicking in free panning mode.<br />
757         /// This is a constant which multiplies the input touch flick velocity to determine the actual velocity at which to move the scrolling area.
758         /// </summary>
759         /// <returns>The flick speed coefficient is returned.</returns>
760         /// <since_tizen> 3 </since_tizen>
761         public float GetFlickSpeedCoefficient()
762         {
763             float ret = NDalicPINVOKE.ScrollView_GetFlickSpeedCoefficient(swigCPtr);
764             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
765             return ret;
766         }
767
768         /// <summary>
769         /// Sets the flick speed coefficient for ScrollView when flicking in free panning mode.<br />
770         /// This is a constant which multiplies the input touch flick velocity to determine the actual velocity at
771         /// which to move the scrolling area.<br />
772         /// </summary>
773         /// <param name="speed">The flick speed coefficient (default = 1.0).</param>
774         /// <since_tizen> 3 </since_tizen>
775         public void SetFlickSpeedCoefficient(float speed)
776         {
777             NDalicPINVOKE.ScrollView_SetFlickSpeedCoefficient(swigCPtr, speed);
778             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
779         }
780
781         /// <summary>
782         /// Gets the minimum pan distance required for a flick gesture in pixels.<br />
783         /// </summary>
784         /// <returns>Minimum pan distance vector with separate x and y distance.</returns>
785         /// <since_tizen> 3 </since_tizen>
786         public Vector2 GetMinimumDistanceForFlick()
787         {
788             Vector2 ret = new Vector2(NDalicPINVOKE.ScrollView_GetMinimumDistanceForFlick(swigCPtr), true);
789             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
790             return ret;
791         }
792
793         /// <summary>
794         /// Sets the minimum pan distance required for a flick in pixels.<br />
795         /// Takes a Vector2 containing separate x and y values. As long as the pan distance exceeds one of these axes, a flick will be allowed.
796         /// </summary>
797         /// <param name="distance">The flick speed coefficient (default = 1.0).</param>
798         /// <since_tizen> 3 </since_tizen>
799         public void SetMinimumDistanceForFlick(Vector2 distance)
800         {
801             NDalicPINVOKE.ScrollView_SetMinimumDistanceForFlick(swigCPtr, Vector2.getCPtr(distance));
802             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
803         }
804
805         /// <summary>
806         /// Returns the minimum pan speed required for a flick gesture in pixels per second.
807         /// </summary>
808         /// <returns>Minimum pan speed.</returns>
809         /// <since_tizen> 3 </since_tizen>
810         public float GetMinimumSpeedForFlick()
811         {
812             float ret = NDalicPINVOKE.ScrollView_GetMinimumSpeedForFlick(swigCPtr);
813             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
814             return ret;
815         }
816
817         /// <summary>
818         /// Sets the minimum pan speed required for a flick in pixels per second.<br />
819         /// </summary>
820         /// <param name="speed">The minimum pan speed for a flick.</param>
821         /// <since_tizen> 3 </since_tizen>
822         public void SetMinimumSpeedForFlick(float speed)
823         {
824             NDalicPINVOKE.ScrollView_SetMinimumSpeedForFlick(swigCPtr, speed);
825             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
826         }
827
828         /// <summary>
829         /// Gets the maximum flick speed setting for ScrollView when flicking in free panning mode.<br />
830         /// This is a value in stage-diagonals per second.
831         /// </summary>
832         /// <returns>Maximum flick speed is returned.</returns>
833         /// <since_tizen> 3 </since_tizen>
834         public float GetMaxFlickSpeed()
835         {
836             float ret = NDalicPINVOKE.ScrollView_GetMaxFlickSpeed(swigCPtr);
837             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
838             return ret;
839         }
840
841         /// <summary>
842         /// Sets the maximum flick speed for the ScrollView when flicking in free panning mode.<br />
843         /// This is a value in stage-diagonals per second. stage-diagonal = Length( stage.width, stage.height ).<br />
844         /// </summary>
845         /// <param name="speed">Maximum flick speed (default = 3.0).</param>
846         /// <since_tizen> 3 </since_tizen>
847         public void SetMaxFlickSpeed(float speed)
848         {
849             NDalicPINVOKE.ScrollView_SetMaxFlickSpeed(swigCPtr, speed);
850             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
851         }
852
853         /// <summary>
854         /// Gets the step of scroll distance in actor coordinates for each wheel event received in free panning mode.<br />
855         /// </summary>
856         /// <returns>The step of scroll distance(pixel) in X and Y axes.</returns>
857         /// <since_tizen> 3 </since_tizen>
858         public Vector2 GetWheelScrollDistanceStep()
859         {
860             Vector2 ret = new Vector2(NDalicPINVOKE.ScrollView_GetWheelScrollDistanceStep(swigCPtr), true);
861             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
862             return ret;
863         }
864
865         /// <summary>
866         /// Sets the step of scroll distance in actor coordinates for each wheel event received in free panning mode.<br />
867         /// </summary>
868         /// <param name="step">step The step of scroll distance(pixel) in X and Y axes.</param>
869         /// <since_tizen> 3 </since_tizen>
870         public void SetWheelScrollDistanceStep(Vector2 step)
871         {
872             NDalicPINVOKE.ScrollView_SetWheelScrollDistanceStep(swigCPtr, Vector2.getCPtr(step));
873             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
874         }
875
876         /// <summary>
877         /// Retrieves current scroll position.<br />
878         /// </summary>
879         /// <returns>The current scroll position.</returns>
880         /// <since_tizen> 3 </since_tizen>
881         public Vector2 GetCurrentScrollPosition()
882         {
883             Vector2 ret = new Vector2(NDalicPINVOKE.ScrollView_GetCurrentScrollPosition(swigCPtr), true);
884             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
885             return ret;
886         }
887
888         /// <summary>
889         /// Retrieves current scroll page based on ScrollView dimensions being the size of one page, and all pages laid out in<br />
890         /// a grid fashion, increasing from left to right until the end of the X-domain.
891         /// </summary>
892         /// <returns>The current scroll position.</returns>
893         /// <since_tizen> 3 </since_tizen>
894         public uint GetCurrentPage()
895         {
896             uint ret = NDalicPINVOKE.ScrollView_GetCurrentPage(swigCPtr);
897             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
898             return ret;
899         }
900
901         /// <summary>
902         /// Scrolls View to position specified (contents will scroll to this position).
903         /// </summary>
904         /// <param name="position">The position to scroll to.</param>
905         /// <since_tizen> 3 </since_tizen>
906         public void ScrollTo(Vector2 position)
907         {
908             NDalicPINVOKE.ScrollView_ScrollTo__SWIG_0(swigCPtr, Vector2.getCPtr(position));
909             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
910         }
911
912         /// <summary>
913         /// Scrolls View to position specified (contents will scroll to this position).
914         /// </summary>
915         /// <param name="position">The position to scroll to.</param>
916         /// <param name="duration">The duration of the animation in seconds.</param>
917         /// <since_tizen> 3 </since_tizen>
918         public void ScrollTo(Vector2 position, float duration)
919         {
920             NDalicPINVOKE.ScrollView_ScrollTo__SWIG_1(swigCPtr, Vector2.getCPtr(position), duration);
921             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
922         }
923
924         /// <summary>
925         /// Scrolls View to position specified (contents will scroll to this position).
926         /// </summary>
927         /// <param name="position">The position to scroll to.</param>
928         /// <param name="duration">The duration of the animation in seconds.</param>
929         /// <param name="alpha">The alpha function to use.</param>
930         /// <since_tizen> 3 </since_tizen>
931         public void ScrollTo(Vector2 position, float duration, AlphaFunction alpha)
932         {
933             NDalicPINVOKE.ScrollView_ScrollTo__SWIG_2(swigCPtr, Vector2.getCPtr(position), duration, AlphaFunction.getCPtr(alpha));
934             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
935         }
936
937         /// <summary>
938         /// Scrolls View to position specified (contents will scroll to this position).
939         /// </summary>
940         /// <param name="position">The position to scroll to.</param>
941         /// <param name="duration">The duration of the animation in seconds.</param>
942         /// <param name="horizontalBias">Whether to bias scrolling to left or right.</param>
943         /// <param name="verticalBias">Whether to bias scrolling to top or bottom.</param>
944         /// <since_tizen> 3 </since_tizen>
945         public void ScrollTo(Vector2 position, float duration, DirectionBias horizontalBias, DirectionBias verticalBias)
946         {
947             NDalicPINVOKE.ScrollView_ScrollTo__SWIG_3(swigCPtr, Vector2.getCPtr(position), duration, (int)horizontalBias, (int)verticalBias);
948             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
949         }
950
951         /// <summary>
952         /// Scrolls View to position specified (contents will scroll to this position).
953         /// </summary>
954         /// <param name="position">The position to scroll to.</param>
955         /// <param name="duration">The duration of the animation in seconds.</param>
956         /// <param name="alpha">Alpha function to use.</param>
957         /// <param name="horizontalBias">Whether to bias scrolling to left or right.</param>
958         /// <param name="verticalBias">Whether to bias scrolling to top or bottom.</param>
959         /// <since_tizen> 3 </since_tizen>
960         public void ScrollTo(Vector2 position, float duration, AlphaFunction alpha, DirectionBias horizontalBias, DirectionBias verticalBias)
961         {
962             NDalicPINVOKE.ScrollView_ScrollTo__SWIG_4(swigCPtr, Vector2.getCPtr(position), duration, AlphaFunction.getCPtr(alpha), (int)horizontalBias, (int)verticalBias);
963             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
964         }
965
966         /// <summary>
967         /// Scrolls View to position specified (contents will scroll to this position).
968         /// </summary>
969         /// <param name="page">The page to scroll to.</param>
970         /// <since_tizen> 3 </since_tizen>
971         public void ScrollTo(uint page)
972         {
973             NDalicPINVOKE.ScrollView_ScrollTo__SWIG_5(swigCPtr, page);
974             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
975         }
976
977         /// <summary>
978         /// Scrolls View to position specified (contents will scroll to this position).
979         /// </summary>
980         /// <param name="page">The page to scroll to.</param>
981         /// <param name="duration">The duration of the animation in seconds.</param>
982         /// <since_tizen> 3 </since_tizen>
983         public void ScrollTo(uint page, float duration)
984         {
985             NDalicPINVOKE.ScrollView_ScrollTo__SWIG_6(swigCPtr, page, duration);
986             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
987         }
988
989         /// <summary>
990         /// Scrolls View to position specified (contents will scroll to this position).
991         /// </summary>
992         /// <param name="page">The page to scroll to.</param>
993         /// <param name="duration">The duration of the animation in seconds.</param>
994         /// <param name="bias">Whether to bias scrolling to left or right.</param>
995         /// <since_tizen> 3 </since_tizen>
996         public void ScrollTo(uint page, float duration, DirectionBias bias)
997         {
998             NDalicPINVOKE.ScrollView_ScrollTo__SWIG_7(swigCPtr, page, duration, (int)bias);
999             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1000         }
1001
1002         /// <summary>
1003         /// Scrolls View to position specified (contents will scroll to this position).
1004         /// </summary>
1005         /// <param name="view">The view to center in on (via Scrolling).</param>
1006         /// <since_tizen> 3 </since_tizen>
1007         public void ScrollTo(View view)
1008         {
1009             NDalicPINVOKE.ScrollView_ScrollTo__SWIG_8(swigCPtr, View.getCPtr(view));
1010             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1011         }
1012
1013         /// <summary>
1014         /// Scrolls View to position specified (contents will scroll to this position).
1015         /// </summary>
1016         /// <param name="view">The view to center in on (via Scrolling).</param>
1017         /// <param name="duration">The duration of the animation in seconds.</param>
1018         /// <since_tizen> 3 </since_tizen>
1019         public void ScrollTo(View view, float duration)
1020         {
1021             NDalicPINVOKE.ScrollView_ScrollTo__SWIG_9(swigCPtr, View.getCPtr(view), duration);
1022             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1023         }
1024
1025         /// <summary>
1026         /// Scrolls View to the nearest snap points as specified by the Rulers.<br />
1027         /// If already at snap points, then will return false, and not scroll.<br />
1028         /// </summary>
1029         /// <returns>True if Snapping necessary.</returns>
1030         /// <since_tizen> 3 </since_tizen>
1031         public bool ScrollToSnapPoint()
1032         {
1033             bool ret = NDalicPINVOKE.ScrollView_ScrollToSnapPoint(swigCPtr);
1034             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1035             return ret;
1036         }
1037
1038         internal void ApplyConstraintToChildren(SWIGTYPE_p_Dali__Constraint constraint)
1039         {
1040             NDalicPINVOKE.ScrollView_ApplyConstraintToChildren(swigCPtr, SWIGTYPE_p_Dali__Constraint.getCPtr(constraint));
1041             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1042         }
1043
1044         /// <summary>
1045         /// Applies Effect to ScrollView.
1046         /// </summary>
1047         /// <param name="effect">The effect to apply to scroll view.</param>
1048         /// <since_tizen> 3 </since_tizen>
1049         public void ApplyEffect(ScrollViewEffect effect)
1050         {
1051             NDalicPINVOKE.ScrollView_ApplyEffect(swigCPtr, ScrollViewEffect.getCPtr(effect));
1052             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1053         }
1054
1055         /// <summary>
1056         /// Removes Effect from ScrollView.
1057         /// </summary>
1058         /// <param name="effect">The effect to remove.</param>
1059         /// <since_tizen> 3 </since_tizen>
1060         public void RemoveEffect(ScrollViewEffect effect)
1061         {
1062             NDalicPINVOKE.ScrollView_RemoveEffect(swigCPtr, ScrollViewEffect.getCPtr(effect));
1063             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1064         }
1065
1066         /// <summary>
1067         /// Remove All Effects from ScrollView.
1068         /// </summary>
1069         /// <since_tizen> 3 </since_tizen>
1070         public void RemoveAllEffects()
1071         {
1072             NDalicPINVOKE.ScrollView_RemoveAllEffects(swigCPtr);
1073             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1074         }
1075
1076         /// <summary>
1077         /// Binds view to this ScrollView.
1078         /// Once an actor is bound to a ScrollView, it will be subject to that ScrollView's properties.
1079         /// </summary>
1080         /// <param name="child">The view to add to this ScrollView.</param>
1081         /// <since_tizen> 3 </since_tizen>
1082         public void BindView(View child)
1083         {
1084             NDalicPINVOKE.ScrollView_BindActor(swigCPtr, View.getCPtr(child));
1085             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1086         }
1087
1088         /// <summary>
1089         /// Unbinds view to this ScrollView.
1090         /// Once an actor is bound to a ScrollView, it will be subject to that ScrollView's properties.
1091         /// </summary>
1092         /// <param name="child">The view to remove to this ScrollView.</param>
1093         /// <since_tizen> 3 </since_tizen>
1094         public void UnbindView(View child)
1095         {
1096             NDalicPINVOKE.ScrollView_UnbindActor(swigCPtr, View.getCPtr(child));
1097             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1098         }
1099
1100         /// <summary>
1101         /// Allows the user to constrain the scroll view in a particular direction.
1102         /// </summary>
1103         /// <param name="direction">The axis to constrain the scroll-view to.</param>
1104         /// <param name="threshold">The threshold to apply around the axis.</param>
1105         /// <since_tizen> 3 </since_tizen>
1106         public void SetScrollingDirection(Radian direction, Radian threshold)
1107         {
1108             NDalicPINVOKE.ScrollView_SetScrollingDirection__SWIG_0(swigCPtr, Radian.getCPtr(direction), Radian.getCPtr(threshold));
1109             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1110         }
1111
1112         /// <summary>
1113         /// Allows the user to constrain the scroll view in a particular direction.
1114         /// </summary>
1115         /// <param name="direction">The axis to constrain the scroll-view to.</param>
1116         /// <since_tizen> 3 </since_tizen>
1117         public void SetScrollingDirection(Radian direction)
1118         {
1119             NDalicPINVOKE.ScrollView_SetScrollingDirection__SWIG_1(swigCPtr, Radian.getCPtr(direction));
1120             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1121         }
1122
1123         /// <summary>
1124         /// Removes a direction constraint from the scroll view.
1125         /// </summary>
1126         /// <param name="direction">The axis to constrain the scroll-view to.</param>
1127         /// <since_tizen> 3 </since_tizen>
1128         public void RemoveScrollingDirection(Radian direction)
1129         {
1130             NDalicPINVOKE.ScrollView_RemoveScrollingDirection(swigCPtr, Radian.getCPtr(direction));
1131             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1132         }
1133
1134         internal ScrollViewSnapStartedSignal SnapStartedSignal()
1135         {
1136             ScrollViewSnapStartedSignal ret = new ScrollViewSnapStartedSignal(NDalicPINVOKE.ScrollView_SnapStartedSignal(swigCPtr), false);
1137             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1138             return ret;
1139         }
1140
1141         /// <summary>
1142         /// Sets and Gets WrapEnabled property.
1143         /// </summary>
1144         /// <since_tizen> 3 </since_tizen>
1145         public bool WrapEnabled
1146         {
1147             get
1148             {
1149                 bool temp = false;
1150                 GetProperty(ScrollView.Property.WRAP_ENABLED).Get(out temp);
1151                 return temp;
1152             }
1153             set
1154             {
1155                 SetProperty(ScrollView.Property.WRAP_ENABLED, new Tizen.NUI.PropertyValue(value));
1156             }
1157         }
1158
1159         /// <summary>
1160         /// Sets and Gets PanningEnabled property.
1161         /// </summary>
1162         /// <since_tizen> 3 </since_tizen>
1163         public bool PanningEnabled
1164         {
1165             get
1166             {
1167                 bool temp = false;
1168                 GetProperty(ScrollView.Property.PANNING_ENABLED).Get(out temp);
1169                 return temp;
1170             }
1171             set
1172             {
1173                 SetProperty(ScrollView.Property.PANNING_ENABLED, new Tizen.NUI.PropertyValue(value));
1174             }
1175         }
1176
1177         /// <summary>
1178         /// Sets and Gets AxisAutoLockEnabled property.
1179         /// </summary>
1180         /// <since_tizen> 3 </since_tizen>
1181         public bool AxisAutoLockEnabled
1182         {
1183             get
1184             {
1185                 bool temp = false;
1186                 GetProperty(ScrollView.Property.AXIS_AUTO_LOCK_ENABLED).Get(out temp);
1187                 return temp;
1188             }
1189             set
1190             {
1191                 SetProperty(ScrollView.Property.AXIS_AUTO_LOCK_ENABLED, new Tizen.NUI.PropertyValue(value));
1192             }
1193         }
1194
1195         /// <summary>
1196         /// Sets and Gets WheelScrollDistanceStep property.
1197         /// </summary>
1198         /// <since_tizen> 3 </since_tizen>
1199         public Vector2 WheelScrollDistanceStep
1200         {
1201             get
1202             {
1203                 Vector2 temp = new Vector2(0.0f, 0.0f);
1204                 GetProperty(ScrollView.Property.WHEEL_SCROLL_DISTANCE_STEP).Get(temp);
1205                 return temp;
1206             }
1207             set
1208             {
1209                 SetProperty(ScrollView.Property.WHEEL_SCROLL_DISTANCE_STEP, new Tizen.NUI.PropertyValue(value));
1210             }
1211         }
1212
1213         /// <summary>
1214         /// Sets and Gets ScrollPosition property.
1215         /// </summary>
1216         /// <since_tizen> 3 </since_tizen>
1217         public Vector2 ScrollPosition
1218         {
1219             get
1220             {
1221                 Vector2 temp = new Vector2(0.0f, 0.0f);
1222                 GetProperty(ScrollView.Property.SCROLL_POSITION).Get(temp);
1223                 return temp;
1224             }
1225             set
1226             {
1227                 SetProperty(ScrollView.Property.SCROLL_POSITION, new Tizen.NUI.PropertyValue(value));
1228             }
1229         }
1230
1231         /// <summary>
1232         /// Sets and Gets ScrollPrePosition property.
1233         /// </summary>
1234         /// <since_tizen> 3 </since_tizen>
1235         public Vector2 ScrollPrePosition
1236         {
1237             get
1238             {
1239                 Vector2 temp = new Vector2(0.0f, 0.0f);
1240                 GetProperty(ScrollView.Property.SCROLL_PRE_POSITION).Get(temp);
1241                 return temp;
1242             }
1243             set
1244             {
1245                 SetProperty(ScrollView.Property.SCROLL_PRE_POSITION, new Tizen.NUI.PropertyValue(value));
1246             }
1247         }
1248
1249         /// <summary>
1250         /// Sets and Gets ScrollPrePositionMax property.
1251         /// </summary>
1252         /// <since_tizen> 3 </since_tizen>
1253         public Vector2 ScrollPrePositionMax
1254         {
1255             get
1256             {
1257                 Vector2 temp = new Vector2(0.0f, 0.0f);
1258                 GetProperty(ScrollView.Property.SCROLL_PRE_POSITION_MAX).Get(temp);
1259                 return temp;
1260             }
1261             set
1262             {
1263                 SetProperty(ScrollView.Property.SCROLL_PRE_POSITION_MAX, new Tizen.NUI.PropertyValue(value));
1264             }
1265         }
1266
1267         /// <summary>
1268         /// Sets and Gets OvershootX property.
1269         /// </summary>
1270         /// <since_tizen> 3 </since_tizen>
1271         public float OvershootX
1272         {
1273             get
1274             {
1275                 float temp = 0.0f;
1276                 GetProperty(ScrollView.Property.OVERSHOOT_X).Get(out temp);
1277                 return temp;
1278             }
1279             set
1280             {
1281                 SetProperty(ScrollView.Property.OVERSHOOT_X, new Tizen.NUI.PropertyValue(value));
1282             }
1283         }
1284
1285         /// <summary>
1286         /// Sets and Gets OvershootY property.
1287         /// </summary>
1288         /// <since_tizen> 3 </since_tizen>
1289         public float OvershootY
1290         {
1291             get
1292             {
1293                 float temp = 0.0f;
1294                 GetProperty(ScrollView.Property.OVERSHOOT_Y).Get(out temp);
1295                 return temp;
1296             }
1297             set
1298             {
1299                 SetProperty(ScrollView.Property.OVERSHOOT_Y, new Tizen.NUI.PropertyValue(value));
1300             }
1301         }
1302
1303         /// <summary>
1304         /// Sets and Gets ScrollFinal property.
1305         /// </summary>
1306         /// <since_tizen> 3 </since_tizen>
1307         public Vector2 ScrollFinal
1308         {
1309             get
1310             {
1311                 Vector2 temp = new Vector2(0.0f, 0.0f);
1312                 GetProperty(ScrollView.Property.SCROLL_FINAL).Get(temp);
1313                 return temp;
1314             }
1315             set
1316             {
1317                 SetProperty(ScrollView.Property.SCROLL_FINAL, new Tizen.NUI.PropertyValue(value));
1318             }
1319         }
1320
1321         /// <summary>
1322         /// Sets and Gets Wrap property.
1323         /// </summary>
1324         /// <since_tizen> 3 </since_tizen>
1325         public bool Wrap
1326         {
1327             get
1328             {
1329                 bool temp = false;
1330                 GetProperty(ScrollView.Property.WRAP).Get(out temp);
1331                 return temp;
1332             }
1333             set
1334             {
1335                 SetProperty(ScrollView.Property.WRAP, new Tizen.NUI.PropertyValue(value));
1336             }
1337         }
1338
1339         /// <summary>
1340         /// Sets and Gets Panning property.
1341         /// </summary>
1342         /// <since_tizen> 3 </since_tizen>
1343         public bool Panning
1344         {
1345             get
1346             {
1347                 bool temp = false;
1348                 GetProperty(ScrollView.Property.PANNING).Get(out temp);
1349                 return temp;
1350             }
1351             set
1352             {
1353                 SetProperty(ScrollView.Property.PANNING, new Tizen.NUI.PropertyValue(value));
1354             }
1355         }
1356
1357         /// <summary>
1358         /// Sets and Gets Scrolling property.
1359         /// </summary>
1360         /// <since_tizen> 3 </since_tizen>
1361         public bool Scrolling
1362         {
1363             get
1364             {
1365                 bool temp = false;
1366                 GetProperty(ScrollView.Property.SCROLLING).Get(out temp);
1367                 return temp;
1368             }
1369             set
1370             {
1371                 SetProperty(ScrollView.Property.SCROLLING, new Tizen.NUI.PropertyValue(value));
1372             }
1373         }
1374
1375         /// <summary>
1376         /// Sets and Gets ScrollDomainSize property.
1377         /// </summary>
1378         /// <since_tizen> 3 </since_tizen>
1379         public Vector2 ScrollDomainSize
1380         {
1381             get
1382             {
1383                 Vector2 temp = new Vector2(0.0f, 0.0f);
1384                 GetProperty(ScrollView.Property.SCROLL_DOMAIN_SIZE).Get(temp);
1385                 return temp;
1386             }
1387             set
1388             {
1389                 SetProperty(ScrollView.Property.SCROLL_DOMAIN_SIZE, new Tizen.NUI.PropertyValue(value));
1390             }
1391         }
1392
1393         /// <summary>
1394         /// Sets and Gets ScrollDomainOffset property.
1395         /// </summary>
1396         /// <since_tizen> 3 </since_tizen>
1397         public Vector2 ScrollDomainOffset
1398         {
1399             get
1400             {
1401                 Vector2 temp = new Vector2(0.0f, 0.0f);
1402                 GetProperty(ScrollView.Property.SCROLL_DOMAIN_OFFSET).Get(temp);
1403                 return temp;
1404             }
1405             set
1406             {
1407                 SetProperty(ScrollView.Property.SCROLL_DOMAIN_OFFSET, new Tizen.NUI.PropertyValue(value));
1408             }
1409         }
1410
1411         /// <summary>
1412         /// Sets and Gets ScrollPositionDelta property.
1413         /// </summary>
1414         /// <since_tizen> 3 </since_tizen>
1415         public Vector2 ScrollPositionDelta
1416         {
1417             get
1418             {
1419                 Vector2 temp = new Vector2(0.0f, 0.0f);
1420                 GetProperty(ScrollView.Property.SCROLL_POSITION_DELTA).Get(temp);
1421                 return temp;
1422             }
1423             set
1424             {
1425                 SetProperty(ScrollView.Property.SCROLL_POSITION_DELTA, new Tizen.NUI.PropertyValue(value));
1426             }
1427         }
1428
1429         /// <summary>
1430         /// Sets and Gets StartPagePosition property.
1431         /// </summary>
1432         /// <since_tizen> 3 </since_tizen>
1433         public Vector3 StartPagePosition
1434         {
1435             get
1436             {
1437                 Vector3 temp = new Vector3(0.0f, 0.0f, 0.0f);
1438                 GetProperty(ScrollView.Property.START_PAGE_POSITION).Get(temp);
1439                 return temp;
1440             }
1441             set
1442             {
1443                 SetProperty(ScrollView.Property.START_PAGE_POSITION, new Tizen.NUI.PropertyValue(value));
1444             }
1445         }
1446
1447
1448         /// <summary>
1449         /// Sets and Gets ScrollMode property.
1450         /// </summary>
1451         /// <since_tizen> 3 </since_tizen>
1452         public PropertyMap ScrollMode
1453         {
1454             get
1455             {
1456                 PropertyValue value = GetProperty( ScrollView.Property.SCROLL_MODE );
1457                 PropertyMap map = new PropertyMap();
1458                 value.Get( map );
1459                 return map;
1460             }
1461             set
1462             {
1463                 SetProperty( ScrollView.Property.SCROLL_MODE, new PropertyValue( value ) );
1464             }
1465         }
1466
1467     }
1468
1469 }