dali 1.2.28 version upgrade
[platform/core/csapi/nui.git] / Tizen.NUI / src / public / Position.cs
1 // Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
2 // PROPRIETARY/CONFIDENTIAL 
3 // This software is the confidential and proprietary
4 // information of SAMSUNG ELECTRONICS ("Confidential Information"). You shall
5 // not disclose such Confidential Information and shall use it only in
6 // accordance with the terms of the license agreement you entered into with
7 // SAMSUNG ELECTRONICS. SAMSUNG make no representations or warranties about the
8 // suitability of the software, either express or implied, including but not
9 // limited to the implied warranties of merchantability, fitness for a
10 // particular purpose, or non-infringement. SAMSUNG shall not be liable for any
11 // damages suffered by licensee as a result of using, modifying or distributing
12 // this software or its derivatives.
13
14 // Copyright (c) 2017 Samsung Electronics Co., Ltd.
15 //
16 // Licensed under the Apache License, Version 2.0 (the "License");
17 // you may not use this file except in compliance with the License.
18 // You may obtain a copy of the License at
19 //
20 // http://www.apache.org/licenses/LICENSE-2.0
21 //
22 // Unless required by applicable law or agreed to in writing, software
23 // distributed under the License is distributed on an "AS IS" BASIS,
24 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
25 // See the License for the specific language governing permissions and
26 // limitations under the License.
27 //
28
29 // This File has been auto-generated by SWIG and then modified using DALi Ruby Scripts
30 // Some have been manually changed
31
32
33 namespace Tizen.NUI
34 {
35
36     public class Position : global::System.IDisposable
37     {
38         private global::System.Runtime.InteropServices.HandleRef swigCPtr;
39         protected bool swigCMemOwn;
40
41         internal Position(global::System.IntPtr cPtr, bool cMemoryOwn)
42         {
43             swigCMemOwn = cMemoryOwn;
44             swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
45         }
46
47         internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Position obj)
48         {
49             return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
50         }
51
52         ~Position()
53         {
54             DisposeQueue.Instance.Add(this);
55         }
56
57         public virtual void Dispose()
58         {
59             if (!Stage.IsInstalled())
60             {
61                 DisposeQueue.Instance.Add(this);
62                 return;
63             }
64
65             lock (this)
66             {
67                 if (swigCPtr.Handle != global::System.IntPtr.Zero)
68                 {
69                     if (swigCMemOwn)
70                     {
71                         swigCMemOwn = false;
72                         NDalicPINVOKE.delete_Vector3(swigCPtr);
73                     }
74                     swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
75                 }
76                 global::System.GC.SuppressFinalize(this);
77             }
78         }
79
80         internal static Position GetVector3FromPtr(global::System.IntPtr cPtr)
81         {
82             Position ret = new Position(cPtr, false);
83             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
84             return ret;
85         }
86
87         public Position() : this(NDalicPINVOKE.new_Vector3__SWIG_0(), true)
88         {
89             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
90         }
91
92         public Position(float x, float y, float z) : this(NDalicPINVOKE.new_Vector3__SWIG_1(x, y, z), true)
93         {
94             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
95         }
96
97         public float X
98         {
99             set
100             {
101                 NDalicPINVOKE.Vector3_X_set(swigCPtr, value);
102                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
103             }
104             get
105             {
106                 float ret = NDalicPINVOKE.Vector3_X_get(swigCPtr);
107                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
108                 return ret;
109             }
110         }
111
112         public float Y
113         {
114             set
115             {
116                 NDalicPINVOKE.Vector3_Y_set(swigCPtr, value);
117                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
118             }
119             get
120             {
121                 float ret = NDalicPINVOKE.Vector3_Y_get(swigCPtr);
122                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
123                 return ret;
124             }
125         }
126
127         public float Z
128         {
129             set
130             {
131                 NDalicPINVOKE.Vector3_Z_set(swigCPtr, value);
132                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
133             }
134             get
135             {
136                 float ret = NDalicPINVOKE.Vector3_Z_get(swigCPtr);
137                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
138                 return ret;
139             }
140         }
141
142         public static float ParentOriginTop
143         {
144             get
145             {
146                 float ret = NDalicPINVOKE.ParentOriginTop_get();
147                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
148                 return ret;
149             }
150         }
151
152         public static float ParentOriginBottom
153         {
154             get
155             {
156                 float ret = NDalicPINVOKE.ParentOriginBottom_get();
157                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
158                 return ret;
159             }
160         }
161
162         public static float ParentOriginLeft
163         {
164             get
165             {
166                 float ret = NDalicPINVOKE.ParentOriginLeft_get();
167                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
168                 return ret;
169             }
170         }
171
172         public static float ParentOriginRight
173         {
174             get
175             {
176                 float ret = NDalicPINVOKE.ParentOriginRight_get();
177                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
178                 return ret;
179             }
180         }
181
182         public static float ParentOriginMiddle
183         {
184             get
185             {
186                 float ret = NDalicPINVOKE.ParentOriginMiddle_get();
187                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
188                 return ret;
189             }
190         }
191
192         public static Position ParentOriginTopLeft
193         {
194             get
195             {
196                 global::System.IntPtr cPtr = NDalicPINVOKE.ParentOriginTopLeft_get();
197                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
198                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
199                 return ret;
200             }
201         }
202
203         public static Position ParentOriginTopCenter
204         {
205             get
206             {
207                 global::System.IntPtr cPtr = NDalicPINVOKE.ParentOriginTopCenter_get();
208                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
209                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
210                 return ret;
211             }
212         }
213
214         public static Position ParentOriginTopRight
215         {
216             get
217             {
218                 global::System.IntPtr cPtr = NDalicPINVOKE.ParentOriginTopRight_get();
219                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
220                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
221                 return ret;
222             }
223         }
224
225         public static Position ParentOriginCenterLeft
226         {
227             get
228             {
229                 global::System.IntPtr cPtr = NDalicPINVOKE.ParentOriginCenterLeft_get();
230                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
231                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
232                 return ret;
233             }
234         }
235
236         public static Position ParentOriginCenter
237         {
238             get
239             {
240                 global::System.IntPtr cPtr = NDalicPINVOKE.ParentOriginCenter_get();
241                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
242                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
243                 return ret;
244             }
245         }
246
247         public static Position ParentOriginCenterRight
248         {
249             get
250             {
251                 global::System.IntPtr cPtr = NDalicPINVOKE.ParentOriginCenterRight_get();
252                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
253                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
254                 return ret;
255             }
256         }
257
258         public static Position ParentOriginBottomLeft
259         {
260             get
261             {
262                 global::System.IntPtr cPtr = NDalicPINVOKE.ParentOriginBottomLeft_get();
263                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
264                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
265                 return ret;
266             }
267         }
268
269         public static Position ParentOriginBottomCenter
270         {
271             get
272             {
273                 global::System.IntPtr cPtr = NDalicPINVOKE.ParentOriginBottomCenter_get();
274                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
275                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
276                 return ret;
277             }
278         }
279
280         public static Position ParentOriginBottomRight
281         {
282             get
283             {
284                 global::System.IntPtr cPtr = NDalicPINVOKE.ParentOriginBottomRight_get();
285                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
286                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
287                 return ret;
288             }
289         }
290
291         public static float AnchorPointTop
292         {
293             get
294             {
295                 float ret = NDalicPINVOKE.AnchorPointTop_get();
296                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
297                 return ret;
298             }
299         }
300
301         public static float AnchorPointBottom
302         {
303             get
304             {
305                 float ret = NDalicPINVOKE.AnchorPointBottom_get();
306                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
307                 return ret;
308             }
309         }
310
311         public static float AnchorPointLeft
312         {
313             get
314             {
315                 float ret = NDalicPINVOKE.AnchorPointLeft_get();
316                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
317                 return ret;
318             }
319         }
320
321         public static float AnchorPointRight
322         {
323             get
324             {
325                 float ret = NDalicPINVOKE.AnchorPointRight_get();
326                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
327                 return ret;
328             }
329         }
330
331         public static float AnchorPointMiddle
332         {
333             get
334             {
335                 float ret = NDalicPINVOKE.AnchorPointMiddle_get();
336                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
337                 return ret;
338             }
339         }
340
341         public static Position AnchorPointTopLeft
342         {
343             get
344             {
345                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointTopLeft_get();
346                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
347                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
348                 return ret;
349             }
350         }
351
352         public static Position AnchorPointTopCenter
353         {
354             get
355             {
356                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointTopCenter_get();
357                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
358                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
359                 return ret;
360             }
361         }
362
363         public static Position AnchorPointTopRight
364         {
365             get
366             {
367                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointTopRight_get();
368                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
369                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
370                 return ret;
371             }
372         }
373
374         public static Position AnchorPointCenterLeft
375         {
376             get
377             {
378                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointCenterLeft_get();
379                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
380                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
381                 return ret;
382             }
383         }
384
385         public static Position AnchorPointCenter
386         {
387             get
388             {
389                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointCenter_get();
390                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
391                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
392                 return ret;
393             }
394         }
395
396         public static Position AnchorPointCenterRight
397         {
398             get
399             {
400                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointCenterRight_get();
401                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
402                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
403                 return ret;
404             }
405         }
406
407         public static Position AnchorPointBottomLeft
408         {
409             get
410             {
411                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointBottomLeft_get();
412                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
413                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
414                 return ret;
415             }
416         }
417
418         public static Position AnchorPointBottomCenter
419         {
420             get
421             {
422                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointBottomCenter_get();
423                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
424                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
425                 return ret;
426             }
427         }
428
429         public static Position AnchorPointBottomRight
430         {
431             get
432             {
433                 global::System.IntPtr cPtr = NDalicPINVOKE.AnchorPointBottomRight_get();
434                 Position ret = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false);
435                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
436                 return ret;
437             }
438         }
439
440     }
441
442     public struct ParentOrigin
443     {
444         public static readonly float Top = Position.ParentOriginTop;
445         public static readonly float Bottom = Position.ParentOriginBottom;
446         public static readonly float Left = Position.ParentOriginLeft;
447         public static readonly float Right = Position.ParentOriginRight;
448         public static readonly float Middle = Position.ParentOriginMiddle;
449         public static readonly Position TopLeft = Position.ParentOriginTopLeft;
450         public static readonly Position TopCenter = Position.ParentOriginTopCenter;
451         public static readonly Position TopRight = Position.ParentOriginTopRight;
452         public static readonly Position CenterLeft = Position.ParentOriginCenterLeft;
453         public static readonly Position Center = Position.ParentOriginCenter;
454         public static readonly Position CenterRight = Position.ParentOriginCenterRight;
455         public static readonly Position BottomLeft = Position.ParentOriginBottomLeft;
456         public static readonly Position BottomCenter = Position.ParentOriginBottomCenter;
457         public static readonly Position BottomRight = Position.ParentOriginBottomRight;
458     }
459     public struct AnchorPoint
460     {
461         public static readonly float Top = Position.AnchorPointTop;
462         public static readonly float Bottom = Position.AnchorPointBottom;
463         public static readonly float Left = Position.AnchorPointLeft;
464         public static readonly float Right = Position.AnchorPointRight;
465         public static readonly float Middle = Position.AnchorPointMiddle;
466         public static readonly Position TopLeft = Position.AnchorPointTopLeft;
467         public static readonly Position TopCenter = Position.AnchorPointTopCenter;
468         public static readonly Position TopRight = Position.AnchorPointTopRight;
469         public static readonly Position CenterLeft = Position.AnchorPointCenterLeft;
470         public static readonly Position Center = Position.AnchorPointCenter;
471         public static readonly Position CenterRight = Position.AnchorPointCenterRight;
472         public static readonly Position BottomLeft = Position.AnchorPointBottomLeft;
473         public static readonly Position BottomCenter = Position.AnchorPointBottomCenter;
474         public static readonly Position BottomRight = Position.AnchorPointBottomRight;
475     }
476
477 }