Merge "Change ItemView to public to make manual tct template." into tizen
[platform/core/csapi/tizenfx.git] / src / Tizen.NUI / src / public / PanGesture.cs
1 //------------------------------------------------------------------------------
2 // <auto-generated />
3 //
4 // This file was automatically generated by SWIG (http://www.swig.org).
5 // Version 3.0.9
6 //
7 // Do not make changes to this file unless you know what you are doing--modify
8 // the SWIG interface file instead.
9 //------------------------------------------------------------------------------
10
11 namespace Tizen.NUI
12 {
13
14     /// <summary>
15     /// A PanGesture is emitted when the user moves one or more fingers in a particular direction.<br>
16     /// A pan gesture will end in the following ways:<br>
17     /// - User releases the primary finger (the first touch).<br>
18     /// - User has more fingers on the screen than the maximum specified.<br>
19     /// - User has less fingers on the screen than the minimum specified.<br>
20     /// - Cancelled by the system.<br>
21     /// A pan gesture will continue to be sent to the actor under than initial pan until it ends.<br>
22     /// </summary>
23     public class PanGesture : Gesture
24     {
25         private global::System.Runtime.InteropServices.HandleRef swigCPtr;
26
27         internal PanGesture(global::System.IntPtr cPtr, bool cMemoryOwn) : base(NDalicPINVOKE.PanGesture_SWIGUpcast(cPtr), cMemoryOwn)
28         {
29             swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
30         }
31
32         internal static global::System.Runtime.InteropServices.HandleRef getCPtr(PanGesture obj)
33         {
34             return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
35         }
36
37         public override void Dispose()
38         {
39             if (!Stage.IsInstalled())
40             {
41                 DisposeQueue.Instance.Add(this);
42                 return;
43             }
44
45             lock (this)
46             {
47                 if (swigCPtr.Handle != global::System.IntPtr.Zero)
48                 {
49                     if (swigCMemOwn)
50                     {
51                         swigCMemOwn = false;
52                         NDalicPINVOKE.delete_PanGesture(swigCPtr);
53                     }
54                     swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
55                 }
56                 global::System.GC.SuppressFinalize(this);
57                 base.Dispose();
58             }
59         }
60
61
62         internal static PanGesture GetPanGestureFromPtr(global::System.IntPtr cPtr)
63         {
64             PanGesture ret = new PanGesture(cPtr, false);
65             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
66             return ret;
67         }
68
69         /// <summary>
70         /// The velocity at which the user is moving their fingers.<br>
71         /// This is represented as a Vector2 and is the pixel movement per millisecond.<br>
72         /// A positive x value shows that the user is panning to the right, a negative x value means the opposite.<br>
73         /// A positive y value shows that the user is panning downwards, a negative y values means upwards.<br>
74         /// </summary>
75         public Vector2 Velocity
76         {
77             get
78             {
79                 return velocity;
80             }
81         }
82
83         /// <summary>
84         /// This is a Vector2 showing how much the user has panned (dragged) since the last pan gesture or,
85         /// if the gesture has just started, then the amount panned since the user touched the screen.<br>
86         /// A positive x value shows that the user is panning to the right, a negative x value means the opposite.<br>
87         /// A positive y value shows that the user is panning downwards, a negative y value means upwards.<br>
88         /// </summary>
89         public Vector2 Displacement
90         {
91             get
92             {
93                 return displacement;
94             }
95         }
96
97         /// <summary>
98         /// This current touch position of the primary touch point in local actor coordinates.
99         /// </summary>
100         public Vector2 Position
101         {
102             get
103             {
104                 return position;
105             }
106         }
107
108         /// <summary>
109         /// The velocity at which the user is moving their fingers.<br>
110         /// This is represented as a Vector2 and is the pixel movement per millisecond.<br>
111         /// A positive x value shows that the user is panning to the right, a negative x value means the opposite.<br>
112         /// A positive y value shows that the user is panning downwards, a negative y values means upwards.<br>
113         /// This value represents the screen coordinates.<br>
114         /// </summary>
115         public Vector2 ScreenVelocity
116         {
117             get
118             {
119                 return screenVelocity;
120             }
121         }
122
123         /// <summary>
124         /// This is a Vector2 showing how much the user has panned (dragged) since the last pan gesture or,
125         /// if the gesture has just started, then the amount panned since the user touched the screen.<br>
126         /// A positive x value shows that the user is panning to the right, a negative x value means the opposite.<br>
127         /// A positive y value shows that the user is panning downwards, a negative y value means upwards.<br>
128         /// This value is in screen coordinates.<br>
129         /// </summary>
130         public Vector2 ScreenDisplacement
131         {
132             get
133             {
134                 return screenDisplacement;
135             }
136         }
137
138         /// <summary>
139         /// This current touch position of the primary touch point in screen coordinates.
140         /// </summary>
141         public Vector2 ScreenPosition
142         {
143             get
144             {
145                 return screenPosition;
146             }
147         }
148
149         /// <summary>
150         /// The total number of fingers touching the screen in a pan gesture.
151         /// </summary>
152         public uint NumberOfTouches
153         {
154             get
155             {
156                 return numberOfTouches;
157             }
158         }
159
160         /// <summary>
161         /// Default Constructor.
162         /// </summary>
163         public PanGesture() : this(NDalicPINVOKE.new_PanGesture__SWIG_0(), true)
164         {
165             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
166         }
167
168         /// <summary>
169         /// Constructor.
170         /// </summary>
171         /// <param name="state">The state of the gesture</param>
172         public PanGesture(Gesture.StateType state) : this(NDalicPINVOKE.new_PanGesture__SWIG_1((int)state), true)
173         {
174             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
175         }
176
177         /// <summary>
178         /// Copy constructor.
179         /// </summary>
180         /// <param name="rhs">A reference to the copied handle</param>
181         public PanGesture(PanGesture rhs) : this(NDalicPINVOKE.new_PanGesture__SWIG_2(PanGesture.getCPtr(rhs)), true)
182         {
183             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
184         }
185
186         /// <summary>
187         /// Assignment operator.
188         /// </summary>
189         /// <param name="rhs">A reference to the copied handle</param>
190         /// <returns>A reference to this</returns>
191         public PanGesture Assign(PanGesture rhs)
192         {
193             PanGesture ret = new PanGesture(NDalicPINVOKE.PanGesture_Assign(swigCPtr, PanGesture.getCPtr(rhs)), false);
194             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
195             return ret;
196         }
197
198         private Vector2 velocity
199         {
200             set
201             {
202                 NDalicPINVOKE.PanGesture_velocity_set(swigCPtr, Vector2.getCPtr(value));
203                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
204             }
205             get
206             {
207                 global::System.IntPtr cPtr = NDalicPINVOKE.PanGesture_velocity_get(swigCPtr);
208                 Vector2 ret = (cPtr == global::System.IntPtr.Zero) ? null : new Vector2(cPtr, false);
209                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
210                 return ret;
211             }
212         }
213
214         private Vector2 displacement
215         {
216             set
217             {
218                 NDalicPINVOKE.PanGesture_displacement_set(swigCPtr, Vector2.getCPtr(value));
219                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
220             }
221             get
222             {
223                 global::System.IntPtr cPtr = NDalicPINVOKE.PanGesture_displacement_get(swigCPtr);
224                 Vector2 ret = (cPtr == global::System.IntPtr.Zero) ? null : new Vector2(cPtr, false);
225                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
226                 return ret;
227             }
228         }
229
230         private Vector2 position
231         {
232             set
233             {
234                 NDalicPINVOKE.PanGesture_position_set(swigCPtr, Vector2.getCPtr(value));
235                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
236             }
237             get
238             {
239                 global::System.IntPtr cPtr = NDalicPINVOKE.PanGesture_position_get(swigCPtr);
240                 Vector2 ret = (cPtr == global::System.IntPtr.Zero) ? null : new Vector2(cPtr, false);
241                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
242                 return ret;
243             }
244         }
245
246         private Vector2 screenVelocity
247         {
248             set
249             {
250                 NDalicPINVOKE.PanGesture_screenVelocity_set(swigCPtr, Vector2.getCPtr(value));
251                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
252             }
253             get
254             {
255                 global::System.IntPtr cPtr = NDalicPINVOKE.PanGesture_screenVelocity_get(swigCPtr);
256                 Vector2 ret = (cPtr == global::System.IntPtr.Zero) ? null : new Vector2(cPtr, false);
257                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
258                 return ret;
259             }
260         }
261
262         private Vector2 screenDisplacement
263         {
264             set
265             {
266                 NDalicPINVOKE.PanGesture_screenDisplacement_set(swigCPtr, Vector2.getCPtr(value));
267                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
268             }
269             get
270             {
271                 global::System.IntPtr cPtr = NDalicPINVOKE.PanGesture_screenDisplacement_get(swigCPtr);
272                 Vector2 ret = (cPtr == global::System.IntPtr.Zero) ? null : new Vector2(cPtr, false);
273                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
274                 return ret;
275             }
276         }
277
278         private Vector2 screenPosition
279         {
280             set
281             {
282                 NDalicPINVOKE.PanGesture_screenPosition_set(swigCPtr, Vector2.getCPtr(value));
283                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
284             }
285             get
286             {
287                 global::System.IntPtr cPtr = NDalicPINVOKE.PanGesture_screenPosition_get(swigCPtr);
288                 Vector2 ret = (cPtr == global::System.IntPtr.Zero) ? null : new Vector2(cPtr, false);
289                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
290                 return ret;
291             }
292         }
293
294         private uint numberOfTouches
295         {
296             set
297             {
298                 NDalicPINVOKE.PanGesture_numberOfTouches_set(swigCPtr, value);
299                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
300             }
301             get
302             {
303                 uint ret = NDalicPINVOKE.PanGesture_numberOfTouches_get(swigCPtr);
304                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
305                 return ret;
306             }
307         }
308
309         /// <summary>
310         /// Returns the speed at which the user is moving their fingers.<br>
311         /// This is the pixel movement per millisecond.<br>
312         /// </summary>
313         /// <returns>The speed of the pan (in pixels per millisecond)</returns>
314         public float GetSpeed()
315         {
316             float ret = NDalicPINVOKE.PanGesture_GetSpeed(swigCPtr);
317             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
318             return ret;
319         }
320
321         /// <summary>
322         /// This returns the distance the user has panned (dragged) since the last pan gesture or,
323         /// if the gesture has just started, then the distance moved since the user touched the screen.<br>
324         /// This is always a positive value.<br>
325         /// </summary>
326         /// <returns>The distance, as a float, a user's finger has panned</returns>
327         public float GetDistance()
328         {
329             float ret = NDalicPINVOKE.PanGesture_GetDistance(swigCPtr);
330             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
331             return ret;
332         }
333
334         /// <summary>
335         /// Returns the speed at which the user is moving their fingers relative to screen coordinates.<br>
336         /// This is the pixel movement per millisecond.<br>
337         /// </summary>
338         /// <returns>The speed of the pan (in pixels per millisecond)</returns>
339         public float GetScreenSpeed()
340         {
341             float ret = NDalicPINVOKE.PanGesture_GetScreenSpeed(swigCPtr);
342             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
343             return ret;
344         }
345
346         /// <summary>
347         /// This returns the distance the user has panned (dragged) since the last pan gesture in screen
348         /// coordinates or, if the gesture has just started, then the distance in screen coordinates moved
349         /// since the user touched the screen.<br>
350         /// This is always a positive value.<br>
351         /// </summary>
352         /// <returns>The distance, as a float, a user's finger has panned</returns>
353         public float GetScreenDistance()
354         {
355             float ret = NDalicPINVOKE.PanGesture_GetScreenDistance(swigCPtr);
356             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
357             return ret;
358         }
359
360     }
361
362 }