[NUI] View.DoAction() added
[platform/core/csapi/tizenfx.git] / src / Tizen.NUI / src / public / BaseComponents / View.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 using System;
18 using System.ComponentModel;
19 using System.Runtime.InteropServices;
20
21 namespace Tizen.NUI.BaseComponents
22 {
23     /// <summary>
24     /// View is the base class for all views.
25     /// </summary>
26     /// <since_tizen> 3 </since_tizen>
27     public class View : Container
28     {
29         private global::System.Runtime.InteropServices.HandleRef swigCPtr;
30
31
32         internal View(global::System.IntPtr cPtr, bool cMemoryOwn) : base(NDalicPINVOKE.View_SWIGUpcast(cPtr), cMemoryOwn)
33         {
34             swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
35             PositionUsesPivotPoint = false;
36         }
37
38         internal static global::System.Runtime.InteropServices.HandleRef getCPtr(View obj)
39         {
40             return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
41         }
42
43         // From Container Base class
44
45         /// <summary>
46         /// Adds a child view to this view.
47         /// </summary>
48         /// <seealso cref="Container.Add" />
49         /// <since_tizen> 4 </since_tizen>
50         public override void Add(View child)
51         {
52             NDalicPINVOKE.Actor_Add(swigCPtr, View.getCPtr(child));
53             if (NDalicPINVOKE.SWIGPendingException.Pending)
54                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
55
56             Children.Add(child);
57         }
58
59         /// <summary>
60         /// Removes a child view from this View. If the view was not a child of this view, this is a no-op.
61         /// </summary>
62         /// <seealso cref="Container.Remove" />
63         /// <since_tizen> 4 </since_tizen>
64         public override void Remove(View child)
65         {
66             NDalicPINVOKE.Actor_Remove(swigCPtr, View.getCPtr(child));
67             if (NDalicPINVOKE.SWIGPendingException.Pending)
68                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
69
70             Children.Remove(child);
71         }
72
73         /// <summary>
74         /// Retrieves a child view by index.
75         /// </summary>
76         /// <seealso cref="Container.GetChildAt" />
77         /// <since_tizen> 4 </since_tizen>
78         public override View GetChildAt(uint index)
79         {
80             if (index < Children.Count)
81             {
82                 return Children[Convert.ToInt32(index)];
83             }
84             else
85             {
86                 return null;
87             }
88         }
89
90         /// <summary>
91         /// Retrieves the number of children held by the view.
92         /// </summary>
93         /// <seealso cref="Container.GetChildCount" />
94         /// <since_tizen> 4 </since_tizen>
95         public override uint GetChildCount()
96         {
97             return Convert.ToUInt32(Children.Count);
98         }
99
100         /// <summary>
101         /// Gets the views parent.
102         /// </summary>
103         /// <seealso cref="Container.GetParent()" />
104         /// <since_tizen> 4 </since_tizen>
105         public override Container GetParent()
106         {
107             IntPtr cPtr = NDalicPINVOKE.Actor_GetParent(swigCPtr);
108
109             BaseHandle basehandle = Registry.GetManagedBaseHandleFromNativePtr(cPtr);
110
111             if (NDalicPINVOKE.SWIGPendingException.Pending)
112                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
113
114             return basehandle as Container;
115         }
116
117         internal bool IsTopLevelView()
118         {
119             if(GetParent() is Layer)
120             {
121                 return true;
122             }
123             return false;
124         }
125
126         /// <summary>
127         /// you can override it to clean-up your own resources.
128         /// </summary>
129         /// <param name="type">DisposeTypes</param>
130         /// <since_tizen> 3 </since_tizen>
131         protected override void Dispose(DisposeTypes type)
132         {
133             if(disposed)
134             {
135                 return;
136             }
137
138             if(type == DisposeTypes.Explicit)
139             {
140                 //Called by User
141                 //Release your own managed resources here.
142                 //You should release all of your own disposable objects here.
143             }
144
145             //Release your own unmanaged resources here.
146             //You should not access any managed member here except static instance.
147             //because the execution order of Finalizes is non-deterministic.
148
149             DisConnectFromSignals();
150
151             if (swigCPtr.Handle != global::System.IntPtr.Zero)
152             {
153                 if (swigCMemOwn)
154                 {
155                     swigCMemOwn = false;
156                     NDalicPINVOKE.delete_View(swigCPtr);
157                 }
158                 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
159             }
160
161             base.Dispose(type);
162
163         }
164
165         private void DisConnectFromSignals()
166         {
167             // Save current CPtr.
168             global::System.Runtime.InteropServices.HandleRef currentCPtr = swigCPtr;
169
170             // Use BaseHandle CPtr as current might have been deleted already in derived classes.
171             swigCPtr = GetBaseHandleCPtrHandleRef;
172
173             if (_onRelayoutEventCallback != null)
174             {
175                 this.OnRelayoutSignal().Disconnect(_onRelayoutEventCallback);
176             }
177
178             if (_offWindowEventCallback != null)
179             {
180                 this.OffWindowSignal().Disconnect(_offWindowEventCallback);
181             }
182
183             if (_onWindowEventCallback != null)
184             {
185                 this.OnWindowSignal().Disconnect(_onWindowEventCallback);
186             }
187
188             if (_wheelEventCallback != null)
189             {
190                 this.WheelEventSignal().Disconnect(_wheelEventCallback);
191             }
192
193             if (_hoverEventCallback != null)
194             {
195                 this.HoveredSignal().Disconnect(_hoverEventCallback);
196             }
197
198             if (_touchDataCallback != null)
199             {
200                 this.TouchSignal().Disconnect(_touchDataCallback);
201             }
202
203             if (_ResourcesLoadedCallback != null)
204             {
205                 this.ResourcesLoadedSignal().Disconnect(_ResourcesLoadedCallback);
206             }
207
208             if (_offWindowEventCallback != null)
209             {
210                 this.OffWindowSignal().Disconnect(_offWindowEventCallback);
211             }
212
213             if (_onWindowEventCallback != null)
214             {
215                 this.OnWindowSignal().Disconnect(_onWindowEventCallback);
216             }
217
218             if (_wheelEventCallback != null)
219             {
220                 this.WheelEventSignal().Disconnect(_wheelEventCallback);
221             }
222
223             if (_hoverEventCallback != null)
224             {
225                 this.HoveredSignal().Disconnect(_hoverEventCallback);
226             }
227
228             if (_touchDataCallback != null)
229             {
230                 this.TouchSignal().Disconnect(_touchDataCallback);
231             }
232
233             if (_onRelayoutEventCallback != null)
234             {
235                 this.OnRelayoutSignal().Disconnect(_onRelayoutEventCallback);
236             }
237
238             if (_keyCallback != null)
239             {
240                 this.KeyEventSignal().Disconnect(_keyCallback);
241             }
242
243             if (_keyInputFocusLostCallback != null)
244             {
245                 this.KeyInputFocusLostSignal().Disconnect(_keyInputFocusLostCallback);
246             }
247
248             if (_keyInputFocusGainedCallback != null)
249             {
250                 this.KeyInputFocusGainedSignal().Disconnect(_keyInputFocusGainedCallback);
251             }
252
253             // BaseHandle CPtr is used in Registry and there is danger of deletion if we keep using it here.
254             // Restore current CPtr.
255             swigCPtr = currentCPtr;
256         }
257
258         private EventHandler _keyInputFocusGainedEventHandler;
259         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
260         private delegate void KeyInputFocusGainedCallbackType(IntPtr control);
261         private KeyInputFocusGainedCallbackType _keyInputFocusGainedCallback;
262
263         /// <summary>
264         /// An event for the KeyInputFocusGained signal which can be used to subscribe or unsubscribe the event handler provided by the user.<br />
265         /// The KeyInputFocusGained signal is emitted when the control gets the key input focus.<br />
266         /// </summary>
267         /// <since_tizen> 3 </since_tizen>
268         public event EventHandler FocusGained
269         {
270             add
271             {
272                 if (_keyInputFocusGainedEventHandler == null)
273                 {
274                     _keyInputFocusGainedCallback = OnKeyInputFocusGained;
275                     this.KeyInputFocusGainedSignal().Connect(_keyInputFocusGainedCallback);
276                 }
277
278                 _keyInputFocusGainedEventHandler += value;
279             }
280
281             remove
282             {
283                 _keyInputFocusGainedEventHandler -= value;
284
285                 if (_keyInputFocusGainedEventHandler == null && KeyInputFocusGainedSignal().Empty() == false)
286                 {
287                     this.KeyInputFocusGainedSignal().Disconnect(_keyInputFocusGainedCallback);
288                 }
289             }
290         }
291
292         private void OnKeyInputFocusGained(IntPtr view)
293         {
294             if (_keyInputFocusGainedEventHandler != null)
295             {
296                 _keyInputFocusGainedEventHandler(this, null);
297             }
298         }
299
300
301         private EventHandler _keyInputFocusLostEventHandler;
302         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
303         private delegate void KeyInputFocusLostCallbackType(IntPtr control);
304         private KeyInputFocusLostCallbackType _keyInputFocusLostCallback;
305
306         /// <summary>
307         /// An event for the KeyInputFocusLost signal which can be used to subscribe or unsubscribe the event handler provided by the user.<br />
308         /// The KeyInputFocusLost signal is emitted when the control loses the key input focus.<br />
309         /// </summary>
310         /// <since_tizen> 3 </since_tizen>
311         public event EventHandler FocusLost
312         {
313             add
314             {
315                 if (_keyInputFocusLostEventHandler == null)
316                 {
317                     _keyInputFocusLostCallback = OnKeyInputFocusLost;
318                     this.KeyInputFocusLostSignal().Connect(_keyInputFocusLostCallback);
319                 }
320
321                 _keyInputFocusLostEventHandler += value;
322             }
323
324             remove
325             {
326                 _keyInputFocusLostEventHandler -= value;
327
328                 if (_keyInputFocusLostEventHandler == null && KeyInputFocusLostSignal().Empty() == false)
329                 {
330                     this.KeyInputFocusLostSignal().Disconnect(_keyInputFocusLostCallback);
331                 }
332             }
333         }
334
335         private void OnKeyInputFocusLost(IntPtr view)
336         {
337             if (_keyInputFocusLostEventHandler != null)
338             {
339                 _keyInputFocusLostEventHandler(this, null);
340             }
341         }
342
343         /// <summary>
344         /// Event arguments that passed via the KeyEvent signal.
345         /// </summary>
346         /// <since_tizen> 3 </since_tizen>
347         public class KeyEventArgs : EventArgs
348         {
349             private Key _key;
350
351             /// <summary>
352             /// Key - is the key sent to the view.
353             /// </summary>
354             /// <since_tizen> 3 </since_tizen>
355             public Key Key
356             {
357                 get
358                 {
359                     return _key;
360                 }
361                 set
362                 {
363                     _key = value;
364                 }
365             }
366         }
367
368         private EventHandlerWithReturnType<object, KeyEventArgs, bool> _keyEventHandler;
369         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
370         private delegate bool KeyCallbackType(IntPtr control, IntPtr keyEvent);
371         private KeyCallbackType _keyCallback;
372
373         /// <summary>
374         /// An event for the KeyPressed signal which can be used to subscribe or unsubscribe the event handler provided by the user.<br />
375         /// The KeyPressed signal is emitted when the key event is received.<br />
376         /// </summary>
377         /// <since_tizen> 3 </since_tizen>
378         public event EventHandlerWithReturnType<object, KeyEventArgs, bool> KeyEvent
379         {
380             add
381             {
382                 if (_keyEventHandler == null)
383                 {
384                     _keyCallback = OnKeyEvent;
385                     this.KeyEventSignal().Connect(_keyCallback);
386                 }
387
388                 _keyEventHandler += value;
389             }
390
391             remove
392             {
393                 _keyEventHandler -= value;
394
395                 if (_keyEventHandler == null && KeyEventSignal().Empty() == false)
396                 {
397                     this.KeyEventSignal().Disconnect(_keyCallback);
398                 }
399             }
400         }
401
402         private bool OnKeyEvent(IntPtr view, IntPtr keyEvent)
403         {
404             KeyEventArgs e = new KeyEventArgs();
405
406             bool result = false;
407
408             e.Key = Tizen.NUI.Key.GetKeyFromPtr(keyEvent);
409
410             if (_keyEventHandler != null)
411             {
412                 Delegate[] delegateList = _keyEventHandler.GetInvocationList();
413
414                 // Oring the result of each callback.
415                 foreach ( EventHandlerWithReturnType<object, KeyEventArgs, bool> del in delegateList )
416                 {
417                     result |= del( this, e );
418                 }
419             }
420
421             return result;
422         }
423
424         private EventHandler _onRelayoutEventHandler;
425         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
426         private delegate void OnRelayoutEventCallbackType(IntPtr control);
427         private OnRelayoutEventCallbackType _onRelayoutEventCallback;
428
429         /// <summary>
430         /// An event for the OnRelayout signal which can be used to subscribe or unsubscribe the event handler.<br />
431         /// The OnRelayout signal is emitted after the size has been set on the view during relayout.<br />
432         /// </summary>
433         /// <since_tizen> 3 </since_tizen>
434         public event EventHandler Relayout
435         {
436             add
437             {
438                 if (_onRelayoutEventHandler == null)
439                 {
440                     _onRelayoutEventCallback = OnRelayout;
441                     this.OnRelayoutSignal().Connect(_onRelayoutEventCallback);
442                 }
443
444                 _onRelayoutEventHandler += value;
445             }
446
447             remove
448             {
449                 _onRelayoutEventHandler -= value;
450
451                 if (_onRelayoutEventHandler == null && OnRelayoutSignal().Empty() == false)
452                 {
453                     this.OnRelayoutSignal().Disconnect(_onRelayoutEventCallback);
454                 }
455
456             }
457         }
458
459         // Callback for View OnRelayout signal
460         private void OnRelayout(IntPtr data)
461         {
462             if (_onRelayoutEventHandler != null)
463             {
464                 _onRelayoutEventHandler(this, null);
465             }
466         }
467
468         /// <summary>
469         /// Event arguments that passed via the touch signal.
470         /// </summary>
471         /// <since_tizen> 3 </since_tizen>
472         public class TouchEventArgs : EventArgs
473         {
474             private Touch _touch;
475
476             /// <summary>
477             /// Touch - contains the information of touch points.
478             /// </summary>
479             /// <since_tizen> 3 </since_tizen>
480             public Touch Touch
481             {
482                 get
483                 {
484                     return _touch;
485                 }
486                 set
487                 {
488                     _touch = value;
489                 }
490             }
491         }
492
493         private EventHandlerWithReturnType<object, TouchEventArgs, bool> _touchDataEventHandler;
494         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
495         private delegate bool TouchDataCallbackType(IntPtr view, IntPtr touchData);
496         private TouchDataCallbackType _touchDataCallback;
497
498         /// <summary>
499         /// An event for the touched signal which can be used to subscribe or unsubscribe the event handler provided by the user.<br />
500         /// The touched signal is emitted when the touch input is received.<br />
501         /// </summary>
502         /// <since_tizen> 3 </since_tizen>
503         public event EventHandlerWithReturnType<object, TouchEventArgs, bool> TouchEvent
504         {
505             add
506             {
507                 if (_touchDataEventHandler == null)
508                 {
509                     _touchDataCallback = OnTouch;
510                     this.TouchSignal().Connect(_touchDataCallback);
511                 }
512
513                 _touchDataEventHandler += value;
514             }
515
516             remove
517             {
518                 _touchDataEventHandler -= value;
519
520                 if (_touchDataEventHandler == null && TouchSignal().Empty() == false)
521                 {
522                     this.TouchSignal().Disconnect(_touchDataCallback);
523                 }
524
525             }
526         }
527
528         // Callback for View TouchSignal
529         private bool OnTouch(IntPtr view, IntPtr touchData)
530         {
531             TouchEventArgs e = new TouchEventArgs();
532
533             e.Touch = Tizen.NUI.Touch.GetTouchFromPtr(touchData);
534
535             if (_touchDataEventHandler != null)
536             {
537                 return _touchDataEventHandler(this, e);
538             }
539             return false;
540         }
541
542
543         /// <summary>
544         /// Event arguments that passed via the hover signal.
545         /// </summary>
546         /// <since_tizen> 3 </since_tizen>
547         public class HoverEventArgs : EventArgs
548         {
549             private Hover _hover;
550
551             /// <summary>
552             /// Hover - contains touch points that represent the points that are currently being hovered or the points where a hover has stopped.
553             /// </summary>
554             /// <since_tizen> 3 </since_tizen>
555             public Hover Hover
556             {
557                 get
558                 {
559                     return _hover;
560                 }
561                 set
562                 {
563                     _hover = value;
564                 }
565             }
566         }
567
568         private EventHandlerWithReturnType<object, HoverEventArgs, bool> _hoverEventHandler;
569         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
570         private delegate bool HoverEventCallbackType(IntPtr view, IntPtr hoverEvent);
571         private HoverEventCallbackType _hoverEventCallback;
572
573         /// <summary>
574         /// An event for the hovered signal which can be used to subscribe or unsubscribe the event handler provided by the user.<br />
575         /// The hovered signal is emitted when the hover input is received.<br />
576         /// </summary>
577         /// <since_tizen> 3 </since_tizen>
578         public event EventHandlerWithReturnType<object, HoverEventArgs, bool> HoverEvent
579         {
580             add
581             {
582                 if (_hoverEventHandler == null)
583                 {
584                     _hoverEventCallback = OnHoverEvent;
585                     this.HoveredSignal().Connect(_hoverEventCallback);
586                 }
587
588                 _hoverEventHandler += value;
589             }
590
591             remove
592             {
593                 _hoverEventHandler -= value;
594
595                 if (_hoverEventHandler == null && HoveredSignal().Empty() == false)
596                 {
597                     this.HoveredSignal().Disconnect(_hoverEventCallback);
598                 }
599
600             }
601         }
602
603         // Callback for View Hover signal
604         private bool OnHoverEvent(IntPtr view, IntPtr hoverEvent)
605         {
606             HoverEventArgs e = new HoverEventArgs();
607
608             e.Hover = Tizen.NUI.Hover.GetHoverFromPtr(hoverEvent);
609
610             if (_hoverEventHandler != null)
611             {
612                 return _hoverEventHandler(this, e);
613             }
614             return false;
615         }
616
617
618         /// <summary>
619         /// Event arguments that passed via the wheel signal.
620         /// </summary>
621         /// <since_tizen> 3 </since_tizen>
622         public class WheelEventArgs : EventArgs
623         {
624             private Wheel _wheel;
625
626             /// <summary>
627             /// WheelEvent - store a wheel rolling type: MOUSE_WHEEL or CUSTOM_WHEEL.
628             /// </summary>
629             /// <since_tizen> 3 </since_tizen>
630             public Wheel Wheel
631             {
632                 get
633                 {
634                     return _wheel;
635                 }
636                 set
637                 {
638                     _wheel = value;
639                 }
640             }
641         }
642
643         private EventHandlerWithReturnType<object, WheelEventArgs, bool> _wheelEventHandler;
644         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
645         private delegate bool WheelEventCallbackType(IntPtr view, IntPtr wheelEvent);
646         private WheelEventCallbackType _wheelEventCallback;
647
648         /// <summary>
649         /// An event for the WheelMoved signal which can be used to subscribe or unsubscribe the event handler provided by the user.<br />
650         /// The WheelMoved signal is emitted when the wheel event is received.<br />
651         /// </summary>
652         /// <since_tizen> 3 </since_tizen>
653         public event EventHandlerWithReturnType<object, WheelEventArgs, bool> WheelEvent
654         {
655             add
656             {
657                 if (_wheelEventHandler == null)
658                 {
659                     _wheelEventCallback = OnWheelEvent;
660                     this.WheelEventSignal().Connect(_wheelEventCallback);
661                 }
662
663                 _wheelEventHandler += value;
664             }
665
666             remove
667             {
668                 _wheelEventHandler -= value;
669
670                 if (_wheelEventHandler == null && WheelEventSignal().Empty() == false)
671                 {
672                     this.WheelEventSignal().Disconnect(_wheelEventCallback);
673                 }
674
675             }
676         }
677
678         // Callback for View Wheel signal
679         private bool OnWheelEvent(IntPtr view, IntPtr wheelEvent)
680         {
681             WheelEventArgs e = new WheelEventArgs();
682
683             e.Wheel = Tizen.NUI.Wheel.GetWheelFromPtr(wheelEvent);
684
685             if (_wheelEventHandler != null)
686             {
687                 return _wheelEventHandler(this, e);
688             }
689             return false;
690         }
691
692
693         private EventHandler _onWindowEventHandler;
694         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
695         private delegate void OnWindowEventCallbackType(IntPtr control);
696         private OnWindowEventCallbackType _onWindowEventCallback;
697
698         /// <summary>
699         /// An event for the OnWindow signal which can be used to subscribe or unsubscribe the event handler.<br />
700         /// The OnWindow signal is emitted after the view has been connected to the window.<br />
701         /// </summary>
702         /// <since_tizen> 3 </since_tizen>
703         public event EventHandler AddedToWindow
704         {
705             add
706             {
707                 if (_onWindowEventHandler == null)
708                 {
709                     _onWindowEventCallback = OnWindow;
710                     this.OnWindowSignal().Connect(_onWindowEventCallback);
711                 }
712
713                 _onWindowEventHandler += value;
714             }
715
716             remove
717             {
718                 _onWindowEventHandler -= value;
719
720                 if (_onWindowEventHandler == null && OnWindowSignal().Empty() == false)
721                 {
722                     this.OnWindowSignal().Disconnect(_onWindowEventCallback);
723                 }
724             }
725         }
726
727         // Callback for View OnWindow signal
728         private void OnWindow(IntPtr data)
729         {
730             if (_onWindowEventHandler != null)
731             {
732                 _onWindowEventHandler(this, null);
733             }
734         }
735
736
737         private EventHandler _offWindowEventHandler;
738         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
739         private delegate void OffWindowEventCallbackType(IntPtr control);
740         private OffWindowEventCallbackType _offWindowEventCallback;
741
742         /// <summary>
743         /// An event for the OffWindow signal, which can be used to subscribe or unsubscribe the event handler.<br />
744         /// OffWindow signal is emitted after the view has been disconnected from the window.<br />
745         /// </summary>
746         /// <since_tizen> 3 </since_tizen>
747         public event EventHandler RemovedFromWindow
748         {
749             add
750             {
751                 if (_offWindowEventHandler == null)
752                 {
753                     _offWindowEventCallback = OffWindow;
754                     this.OffWindowSignal().Connect(_offWindowEventCallback);
755                 }
756
757                 _offWindowEventHandler += value;
758             }
759
760             remove
761             {
762                 _offWindowEventHandler -= value;
763
764                 if (_offWindowEventHandler == null && OffWindowSignal().Empty() == false)
765                 {
766                     this.OffWindowSignal().Disconnect(_offWindowEventCallback);
767                 }
768             }
769         }
770
771         // Callback for View OffWindow signal
772         private void OffWindow(IntPtr data)
773         {
774             if (_offWindowEventHandler != null)
775             {
776                 _offWindowEventHandler(this, null);
777             }
778         }
779
780         /// <summary>
781         /// Event arguments of visibility changed.
782         /// </summary>
783         /// <since_tizen> 3 </since_tizen>
784         public class VisibilityChangedEventArgs : EventArgs
785         {
786             private View _view;
787             private bool _visibility;
788             private VisibilityChangeType _type;
789
790             /// <summary>
791             /// The view, or child of view, whose visibility has changed.
792             /// </summary>
793             /// <since_tizen> 3 </since_tizen>
794             public View View
795             {
796                 get
797                 {
798                     return _view;
799                 }
800                 set
801                 {
802                     _view = value;
803                 }
804             }
805
806             /// <summary>
807             /// Whether the view is now visible or not.
808             /// </summary>
809             /// <since_tizen> 3 </since_tizen>
810             public bool Visibility
811             {
812                 get
813                 {
814                     return _visibility;
815                 }
816                 set
817                 {
818                     _visibility = value;
819                 }
820             }
821
822             /// <summary>
823             /// Whether the view's visible property has changed or a parent's.
824             /// </summary>
825             /// <since_tizen> 3 </since_tizen>
826             public VisibilityChangeType Type
827             {
828                 get
829                 {
830                     return _type;
831                 }
832                 set
833                 {
834                     _type = value;
835                 }
836             }
837         }
838
839         private EventHandler<VisibilityChangedEventArgs> _visibilityChangedEventHandler;
840         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
841         private delegate void VisibilityChangedEventCallbackType(IntPtr data, bool visibility, VisibilityChangeType type);
842         private VisibilityChangedEventCallbackType _visibilityChangedEventCallback;
843
844         /// <summary>
845         /// An event for visibility change which can be used to subscribe or unsubscribe the event handler.<br />
846         /// This signal is emitted when the visible property of this or a parent view is changed.<br />
847         /// </summary>
848         /// <since_tizen> 3 </since_tizen>
849         public event EventHandler<VisibilityChangedEventArgs> VisibilityChanged
850         {
851             add
852             {
853                 if (_visibilityChangedEventHandler == null)
854                 {
855                     _visibilityChangedEventCallback = OnVisibilityChanged;
856                     VisibilityChangedSignal(this).Connect(_visibilityChangedEventCallback);
857                 }
858
859                 _visibilityChangedEventHandler += value;
860             }
861
862             remove
863             {
864                 _visibilityChangedEventHandler -= value;
865
866                 if (_visibilityChangedEventHandler == null && VisibilityChangedSignal(this).Empty() == false)
867                 {
868                     VisibilityChangedSignal(this).Disconnect(_visibilityChangedEventCallback);
869                 }
870             }
871         }
872
873         // Callback for View visibility change signal
874         private void OnVisibilityChanged(IntPtr data, bool visibility, VisibilityChangeType type)
875         {
876             VisibilityChangedEventArgs e = new VisibilityChangedEventArgs();
877             if (data != null)
878             {
879                 e.View = Registry.GetManagedBaseHandleFromNativePtr(data) as View;
880             }
881             e.Visibility = visibility;
882             e.Type = type;
883
884             if (_visibilityChangedEventHandler != null)
885             {
886                 _visibilityChangedEventHandler(this, e);
887             }
888         }
889
890
891         /// <summary>
892         /// Event arguments of layout direction changed.
893         /// </summary>
894         /// <since_tizen> 4 </since_tizen>
895         public class LayoutDirectionChangedEventArgs : EventArgs
896         {
897             private View _view;
898             private ViewLayoutDirectionType _type;
899
900             /// <summary>
901             /// The view, or child of view, whose layout direction has changed.
902             /// </summary>
903             /// <since_tizen> 4 </since_tizen>
904             public View View
905             {
906                 get
907                 {
908                     return _view;
909                 }
910                 set
911                 {
912                     _view = value;
913                 }
914             }
915
916             /// <summary>
917             /// Whether the view's layout direction property has changed or a parent's.
918             /// </summary>
919             /// <since_tizen> 4 </since_tizen>
920             public ViewLayoutDirectionType Type
921             {
922                 get
923                 {
924                     return _type;
925                 }
926                 set
927                 {
928                     _type = value;
929                 }
930             }
931         }
932
933         private EventHandler<LayoutDirectionChangedEventArgs> _layoutDirectionChangedEventHandler;
934         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
935         private delegate void LayoutDirectionChangedEventCallbackType(IntPtr data, ViewLayoutDirectionType type);
936         private LayoutDirectionChangedEventCallbackType _layoutDirectionChangedEventCallback;
937
938         /// <summary>
939         /// Event for layout direction change which can be used to subscribe/unsubscribe the event handler.<br />
940         /// This signal is emitted when the layout direction property of this or a parent view is changed.<br />
941         /// </summary>
942         /// <since_tizen> 4 </since_tizen>
943         public event EventHandler<LayoutDirectionChangedEventArgs> LayoutDirectionChanged
944         {
945             add
946             {
947                 if (_layoutDirectionChangedEventHandler == null)
948                 {
949                     _layoutDirectionChangedEventCallback = OnLayoutDirectionChanged;
950                     LayoutDirectionChangedSignal(this).Connect(_layoutDirectionChangedEventCallback);
951                 }
952
953                 _layoutDirectionChangedEventHandler += value;
954             }
955
956             remove
957             {
958                 _layoutDirectionChangedEventHandler -= value;
959
960                 if (_layoutDirectionChangedEventHandler == null && LayoutDirectionChangedSignal(this).Empty() == false)
961                 {
962                     LayoutDirectionChangedSignal(this).Disconnect(_layoutDirectionChangedEventCallback);
963                 }
964             }
965         }
966
967         // Callback for View layout direction change signal
968         private void OnLayoutDirectionChanged(IntPtr data, ViewLayoutDirectionType type)
969         {
970             LayoutDirectionChangedEventArgs e = new LayoutDirectionChangedEventArgs();
971             if (data != null)
972             {
973                 e.View = Registry.GetManagedBaseHandleFromNativePtr(data) as View;
974             }
975             e.Type = type;
976
977             if (_layoutDirectionChangedEventHandler != null)
978             {
979                 _layoutDirectionChangedEventHandler(this, e);
980             }
981         }
982
983
984
985
986
987
988
989         // Resource Ready Signal
990
991         private EventHandler _resourcesLoadedEventHandler;
992         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
993         private delegate void ResourcesLoadedCallbackType(IntPtr control);
994         private ResourcesLoadedCallbackType _ResourcesLoadedCallback;
995
996         /// <summary>
997         /// An event for the ResourcesLoadedSignal signal which can be used to subscribe or unsubscribe the event handler provided by the user.<br />
998         /// This signal is emitted after all resources required by a view are loaded and ready.<br />
999         /// </summary>
1000         /// <since_tizen> 3 </since_tizen>
1001         public event EventHandler ResourcesLoaded
1002         {
1003             add
1004             {
1005                 if (_resourcesLoadedEventHandler == null)
1006                 {
1007                     _ResourcesLoadedCallback = OnResourcesLoaded;
1008                     this.ResourcesLoadedSignal().Connect(_ResourcesLoadedCallback);
1009                 }
1010
1011                 _resourcesLoadedEventHandler += value;
1012             }
1013
1014             remove
1015             {
1016                 _resourcesLoadedEventHandler -= value;
1017
1018                 if (_resourcesLoadedEventHandler == null && ResourcesLoadedSignal().Empty() == false)
1019                 {
1020                     this.ResourcesLoadedSignal().Disconnect(_ResourcesLoadedCallback);
1021                 }
1022             }
1023         }
1024
1025         private void OnResourcesLoaded(IntPtr view)
1026         {
1027             if (_resourcesLoadedEventHandler != null)
1028             {
1029                 _resourcesLoadedEventHandler(this, null);
1030             }
1031         }
1032
1033         internal IntPtr GetPtrfromView()
1034         {
1035             return (IntPtr)swigCPtr;
1036         }
1037
1038         internal class Property
1039         {
1040             internal static readonly int TOOLTIP = NDalicManualPINVOKE.View_Property_TOOLTIP_get();
1041             internal static readonly int STATE = NDalicManualPINVOKE.View_Property_STATE_get();
1042             internal static readonly int SUB_STATE = NDalicManualPINVOKE.View_Property_SUB_STATE_get();
1043             internal static readonly int LEFT_FOCUSABLE_VIEW_ID = NDalicManualPINVOKE.View_Property_LEFT_FOCUSABLE_ACTOR_ID_get();
1044             internal static readonly int RIGHT_FOCUSABLE_VIEW_ID = NDalicManualPINVOKE.View_Property_RIGHT_FOCUSABLE_ACTOR_ID_get();
1045             internal static readonly int UP_FOCUSABLE_VIEW_ID = NDalicManualPINVOKE.View_Property_UP_FOCUSABLE_ACTOR_ID_get();
1046             internal static readonly int DOWN_FOCUSABLE_VIEW_ID = NDalicManualPINVOKE.View_Property_DOWN_FOCUSABLE_ACTOR_ID_get();
1047             internal static readonly int STYLE_NAME = NDalicPINVOKE.View_Property_STYLE_NAME_get();
1048             internal static readonly int BACKGROUND = NDalicPINVOKE.View_Property_BACKGROUND_get();
1049             internal static readonly int SIBLING_ORDER = NDalicManualPINVOKE.Actor_Property_SIBLING_ORDER_get();
1050             internal static readonly int OPACITY = NDalicManualPINVOKE.Actor_Property_OPACITY_get();
1051             internal static readonly int SCREEN_POSITION = NDalicManualPINVOKE.Actor_Property_SCREEN_POSITION_get();
1052             internal static readonly int POSITION_USES_ANCHOR_POINT = NDalicManualPINVOKE.Actor_Property_POSITION_USES_ANCHOR_POINT_get();
1053             internal static readonly int PARENT_ORIGIN = NDalicPINVOKE.Actor_Property_PARENT_ORIGIN_get();
1054             internal static readonly int PARENT_ORIGIN_X = NDalicPINVOKE.Actor_Property_PARENT_ORIGIN_X_get();
1055             internal static readonly int PARENT_ORIGIN_Y = NDalicPINVOKE.Actor_Property_PARENT_ORIGIN_Y_get();
1056             internal static readonly int PARENT_ORIGIN_Z = NDalicPINVOKE.Actor_Property_PARENT_ORIGIN_Z_get();
1057             internal static readonly int ANCHOR_POINT = NDalicPINVOKE.Actor_Property_ANCHOR_POINT_get();
1058             internal static readonly int ANCHOR_POINT_X = NDalicPINVOKE.Actor_Property_ANCHOR_POINT_X_get();
1059             internal static readonly int ANCHOR_POINT_Y = NDalicPINVOKE.Actor_Property_ANCHOR_POINT_Y_get();
1060             internal static readonly int ANCHOR_POINT_Z = NDalicPINVOKE.Actor_Property_ANCHOR_POINT_Z_get();
1061             internal static readonly int SIZE = NDalicPINVOKE.Actor_Property_SIZE_get();
1062             internal static readonly int SIZE_WIDTH = NDalicPINVOKE.Actor_Property_SIZE_WIDTH_get();
1063             internal static readonly int SIZE_HEIGHT = NDalicPINVOKE.Actor_Property_SIZE_HEIGHT_get();
1064             internal static readonly int SIZE_DEPTH = NDalicPINVOKE.Actor_Property_SIZE_DEPTH_get();
1065             internal static readonly int POSITION = NDalicPINVOKE.Actor_Property_POSITION_get();
1066             internal static readonly int POSITION_X = NDalicPINVOKE.Actor_Property_POSITION_X_get();
1067             internal static readonly int POSITION_Y = NDalicPINVOKE.Actor_Property_POSITION_Y_get();
1068             internal static readonly int POSITION_Z = NDalicPINVOKE.Actor_Property_POSITION_Z_get();
1069             internal static readonly int WORLD_POSITION = NDalicPINVOKE.Actor_Property_WORLD_POSITION_get();
1070             internal static readonly int WORLD_POSITION_X = NDalicPINVOKE.Actor_Property_WORLD_POSITION_X_get();
1071             internal static readonly int WORLD_POSITION_Y = NDalicPINVOKE.Actor_Property_WORLD_POSITION_Y_get();
1072             internal static readonly int WORLD_POSITION_Z = NDalicPINVOKE.Actor_Property_WORLD_POSITION_Z_get();
1073             internal static readonly int ORIENTATION = NDalicPINVOKE.Actor_Property_ORIENTATION_get();
1074             internal static readonly int WORLD_ORIENTATION = NDalicPINVOKE.Actor_Property_WORLD_ORIENTATION_get();
1075             internal static readonly int SCALE = NDalicPINVOKE.Actor_Property_SCALE_get();
1076             internal static readonly int SCALE_X = NDalicPINVOKE.Actor_Property_SCALE_X_get();
1077             internal static readonly int SCALE_Y = NDalicPINVOKE.Actor_Property_SCALE_Y_get();
1078             internal static readonly int SCALE_Z = NDalicPINVOKE.Actor_Property_SCALE_Z_get();
1079             internal static readonly int WORLD_SCALE = NDalicPINVOKE.Actor_Property_WORLD_SCALE_get();
1080             internal static readonly int VISIBLE = NDalicPINVOKE.Actor_Property_VISIBLE_get();
1081             internal static readonly int WORLD_COLOR = NDalicPINVOKE.Actor_Property_WORLD_COLOR_get();
1082             internal static readonly int WORLD_MATRIX = NDalicPINVOKE.Actor_Property_WORLD_MATRIX_get();
1083             internal static readonly int NAME = NDalicPINVOKE.Actor_Property_NAME_get();
1084             internal static readonly int SENSITIVE = NDalicPINVOKE.Actor_Property_SENSITIVE_get();
1085             internal static readonly int LEAVE_REQUIRED = NDalicPINVOKE.Actor_Property_LEAVE_REQUIRED_get();
1086             internal static readonly int INHERIT_ORIENTATION = NDalicPINVOKE.Actor_Property_INHERIT_ORIENTATION_get();
1087             internal static readonly int INHERIT_SCALE = NDalicPINVOKE.Actor_Property_INHERIT_SCALE_get();
1088             internal static readonly int DRAW_MODE = NDalicPINVOKE.Actor_Property_DRAW_MODE_get();
1089             internal static readonly int SIZE_MODE_FACTOR = NDalicPINVOKE.Actor_Property_SIZE_MODE_FACTOR_get();
1090             internal static readonly int WIDTH_RESIZE_POLICY = NDalicPINVOKE.Actor_Property_WIDTH_RESIZE_POLICY_get();
1091             internal static readonly int HEIGHT_RESIZE_POLICY = NDalicPINVOKE.Actor_Property_HEIGHT_RESIZE_POLICY_get();
1092             internal static readonly int SIZE_SCALE_POLICY = NDalicPINVOKE.Actor_Property_SIZE_SCALE_POLICY_get();
1093             internal static readonly int WIDTH_FOR_HEIGHT = NDalicPINVOKE.Actor_Property_WIDTH_FOR_HEIGHT_get();
1094             internal static readonly int HEIGHT_FOR_WIDTH = NDalicPINVOKE.Actor_Property_HEIGHT_FOR_WIDTH_get();
1095             internal static readonly int MINIMUM_SIZE = NDalicPINVOKE.Actor_Property_MINIMUM_SIZE_get();
1096             internal static readonly int MAXIMUM_SIZE = NDalicPINVOKE.Actor_Property_MAXIMUM_SIZE_get();
1097             internal static readonly int INHERIT_POSITION = NDalicPINVOKE.Actor_Property_INHERIT_POSITION_get();
1098             internal static readonly int CLIPPING_MODE = NDalicPINVOKE.Actor_Property_CLIPPING_MODE_get();
1099             internal static readonly int INHERIT_LAYOUT_DIRECTION = NDalicManualPINVOKE.Actor_Property_INHERIT_LAYOUT_DIRECTION_get();
1100             internal static readonly int LAYOUT_DIRECTION = NDalicManualPINVOKE.Actor_Property_LAYOUT_DIRECTION_get();
1101             internal static readonly int MARGIN = NDalicPINVOKE.View_Property_MARGIN_get();
1102             internal static readonly int PADDING = NDalicPINVOKE.View_Property_PADDING_get();
1103         }
1104
1105         /// <summary>
1106         /// Describes the direction to move the focus towards.
1107         /// </summary>
1108         /// <since_tizen> 3 </since_tizen>
1109         public enum FocusDirection
1110         {
1111             /// <summary>
1112             /// Move keyboard focus towards the left direction.
1113             /// </summary>
1114             /// <since_tizen> 3 </since_tizen>
1115             Left,
1116             /// <summary>
1117             /// Move keyboard focus towards the right direction.
1118             /// </summary>
1119             /// <since_tizen> 3 </since_tizen>
1120             Right,
1121             /// <summary>
1122             /// Move keyboard focus towards the up direction.
1123             /// </summary>
1124             /// <since_tizen> 3 </since_tizen>
1125             Up,
1126             /// <summary>
1127             /// Move keyboard focus towards the down direction.
1128             /// </summary>
1129             /// <since_tizen> 3 </since_tizen>
1130             Down,
1131             /// <summary>
1132             /// Move keyboard focus towards the previous page direction.
1133             /// </summary>
1134             /// <since_tizen> 3 </since_tizen>
1135             PageUp,
1136             /// <summary>
1137             /// Move keyboard focus towards the next page direction.
1138             /// </summary>
1139             /// <since_tizen> 3 </since_tizen>
1140             PageDown
1141         }
1142
1143         /// <summary>
1144         /// Creates a new instance of a view.
1145         /// </summary>
1146         /// <since_tizen> 3 </since_tizen>
1147         public View() : this(NDalicPINVOKE.View_New(), true)
1148         {
1149             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1150
1151         }
1152         internal View(View uiControl) : this(NDalicPINVOKE.new_View__SWIG_1(View.getCPtr(uiControl)), true)
1153         {
1154             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1155         }
1156
1157         /// <summary>
1158         /// Downcasts a handle to view handle.<br />
1159         /// If handle points to a view, the downcast produces a valid handle.<br />
1160         /// If not, the returned handle is left uninitialized.<br />
1161         /// </summary>
1162         /// <param name="handle">A handle to an object.</param>
1163         /// <returns>A handle to a view or an uninitialized handle.</returns>
1164         /// <since_tizen> 3 </since_tizen>
1165         [Obsolete("Please do not use! This will be deprecated! Please use as keyword instead!")]
1166         [EditorBrowsable(EditorBrowsableState.Never)]
1167         public static View DownCast(BaseHandle handle)
1168         {
1169             View ret =  Registry.GetManagedBaseHandleFromNativePtr(handle) as View;
1170             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1171             return ret;
1172         }
1173
1174         /// <summary>
1175         /// [Obsolete("Please do not use! this will be deprecated, instead please use as keyword.")]
1176         /// </summary>
1177         /// <since_tizen> 3 </since_tizen>
1178         [Obsolete("Please do not use! This will be deprecated! Please use as keyword instead!")]
1179         [EditorBrowsable(EditorBrowsableState.Never)]
1180         public static T DownCast<T>(View view) where T : View
1181         {
1182             T ret = Registry.GetManagedBaseHandleFromNativePtr(view) as T;
1183             if (ret != null)
1184             {
1185                 return ret;
1186             }
1187             return null;
1188         }
1189
1190         private View ConvertIdToView(uint id)
1191         {
1192             View view = null;
1193
1194             if (Parent is View)
1195             {
1196                 View parentView = Parent as View;
1197                 view = parentView.FindChildById(id);
1198             }
1199
1200             if (!view)
1201             {
1202                 view = Window.Instance.GetRootLayer().FindChildById(id);
1203             }
1204
1205             return view;
1206         }
1207
1208         internal void SetKeyInputFocus()
1209         {
1210             NDalicPINVOKE.View_SetKeyInputFocus(swigCPtr);
1211             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1212         }
1213
1214         /// <summary>
1215         /// Queries whether the view has a focus.
1216         /// </summary>
1217         /// <returns>True if this view has a focus.</returns>
1218         /// <since_tizen> 3 </since_tizen>
1219         public bool HasFocus()
1220         {
1221             bool ret = NDalicPINVOKE.View_HasKeyInputFocus(swigCPtr);
1222             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1223             return ret;
1224         }
1225
1226         internal void ClearKeyInputFocus()
1227         {
1228             NDalicPINVOKE.View_ClearKeyInputFocus(swigCPtr);
1229             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1230         }
1231
1232         internal PinchGestureDetector GetPinchGestureDetector()
1233         {
1234             PinchGestureDetector ret = new PinchGestureDetector(NDalicPINVOKE.View_GetPinchGestureDetector(swigCPtr), true);
1235             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1236             return ret;
1237         }
1238
1239         internal PanGestureDetector GetPanGestureDetector()
1240         {
1241             PanGestureDetector ret = new PanGestureDetector(NDalicPINVOKE.View_GetPanGestureDetector(swigCPtr), true);
1242             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1243             return ret;
1244         }
1245
1246         internal TapGestureDetector GetTapGestureDetector()
1247         {
1248             TapGestureDetector ret = new TapGestureDetector(NDalicPINVOKE.View_GetTapGestureDetector(swigCPtr), true);
1249             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1250             return ret;
1251         }
1252
1253         internal LongPressGestureDetector GetLongPressGestureDetector()
1254         {
1255             LongPressGestureDetector ret = new LongPressGestureDetector(NDalicPINVOKE.View_GetLongPressGestureDetector(swigCPtr), true);
1256             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1257             return ret;
1258         }
1259
1260         /// <summary>
1261         /// Sets the name of the style to be applied to the view.
1262         /// </summary>
1263         /// <param name="styleName">A string matching a style described in a stylesheet.</param>
1264         /// <since_tizen> 3 </since_tizen>
1265         public void SetStyleName(string styleName)
1266         {
1267             NDalicPINVOKE.View_SetStyleName(swigCPtr, styleName);
1268             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1269         }
1270
1271         /// <summary>
1272         /// Retrieves the name of the style to be applied to the view (if any).
1273         /// </summary>
1274         /// <returns>A string matching a style, or an empty string.</returns>
1275         /// <since_tizen> 3 </since_tizen>
1276         public string GetStyleName()
1277         {
1278             string ret = NDalicPINVOKE.View_GetStyleName(swigCPtr);
1279             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1280             return ret;
1281         }
1282
1283         internal void SetBackgroundColor(Vector4 color)
1284         {
1285             NDalicPINVOKE.View_SetBackgroundColor(swigCPtr, Vector4.getCPtr(color));
1286             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1287         }
1288
1289         internal Vector4 GetBackgroundColor()
1290         {
1291             Vector4 ret = new Vector4(NDalicPINVOKE.View_GetBackgroundColor(swigCPtr), true);
1292             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1293             return ret;
1294         }
1295
1296         internal void SetBackgroundImage(Image image)
1297         {
1298             NDalicPINVOKE.View_SetBackgroundImage(swigCPtr, Image.getCPtr(image));
1299             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1300         }
1301
1302         /// <summary>
1303         /// Clears the background.
1304         /// </summary>
1305         /// <since_tizen> 3 </since_tizen>
1306         public void ClearBackground()
1307         {
1308             NDalicPINVOKE.View_ClearBackground(swigCPtr);
1309             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1310         }
1311
1312         internal ControlKeySignal KeyEventSignal()
1313         {
1314             ControlKeySignal ret = new ControlKeySignal(NDalicPINVOKE.View_KeyEventSignal(swigCPtr), false);
1315             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1316             return ret;
1317         }
1318
1319         internal KeyInputFocusSignal KeyInputFocusGainedSignal()
1320         {
1321             KeyInputFocusSignal ret = new KeyInputFocusSignal(NDalicPINVOKE.View_KeyInputFocusGainedSignal(swigCPtr), false);
1322             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1323             return ret;
1324         }
1325
1326         internal KeyInputFocusSignal KeyInputFocusLostSignal()
1327         {
1328             KeyInputFocusSignal ret = new KeyInputFocusSignal(NDalicPINVOKE.View_KeyInputFocusLostSignal(swigCPtr), false);
1329             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1330             return ret;
1331         }
1332
1333         internal View(ViewImpl implementation) : this(NDalicPINVOKE.new_View__SWIG_2(ViewImpl.getCPtr(implementation)), true)
1334         {
1335             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1336         }
1337
1338         internal enum PropertyRange
1339         {
1340             PROPERTY_START_INDEX = PropertyRanges.PROPERTY_REGISTRATION_START_INDEX,
1341             CONTROL_PROPERTY_START_INDEX = PROPERTY_START_INDEX,
1342             CONTROL_PROPERTY_END_INDEX = CONTROL_PROPERTY_START_INDEX + 1000
1343         }
1344
1345         /// <summary>
1346         /// The StyleName, type string.
1347         /// </summary>
1348         /// <since_tizen> 3 </since_tizen>
1349         public string StyleName
1350         {
1351             get
1352             {
1353                 string temp;
1354                 GetProperty(View.Property.STYLE_NAME).Get(out temp);
1355                 return temp;
1356             }
1357             set
1358             {
1359                 SetProperty(View.Property.STYLE_NAME, new Tizen.NUI.PropertyValue(value));
1360             }
1361         }
1362
1363         /// <summary>
1364         /// The mutually exclusive with BACKGROUND_IMAGE and BACKGROUND type Vector4.
1365         /// </summary>
1366         /// <since_tizen> 3 </since_tizen>
1367         public Color BackgroundColor
1368         {
1369             get
1370             {
1371                 Color backgroundColor = new Color(0.0f, 0.0f, 0.0f, 0.0f);
1372
1373                 Tizen.NUI.PropertyMap background = Background;
1374                 int visualType = 0;
1375                 background.Find(Visual.Property.Type)?.Get(out visualType);
1376                 if (visualType == (int)Visual.Type.Color)
1377                 {
1378                     background.Find(ColorVisualProperty.MixColor)?.Get(backgroundColor);
1379                 }
1380
1381                 return backgroundColor;
1382             }
1383             set
1384             {
1385                 SetProperty(View.Property.BACKGROUND, new Tizen.NUI.PropertyValue(value));
1386             }
1387         }
1388
1389         /// <summary>
1390         /// Creates an animation to animate the background color visual. If there is no
1391         /// background visual, creates one with transparent black as it's mixColor.
1392         /// </summary>
1393         /// <since_tizen> 3 </since_tizen>
1394         public Animation AnimateBackgroundColor( object destinationValue,
1395                                                  int startTime,
1396                                                  int endTime,
1397                                                  AlphaFunction.BuiltinFunctions? alphaFunction = null,
1398                                                  object initialValue = null)
1399         {
1400             Tizen.NUI.PropertyMap background = Background;
1401
1402             if( background.Empty() )
1403             {
1404                 // If there is no background yet, ensure there is a transparent
1405                 // color visual
1406                 BackgroundColor = new Color(0.0f, 0.0f, 0.0f, 0.0f);
1407                 background = Background;
1408             }
1409             return AnimateColor( "background", destinationValue, startTime, endTime, alphaFunction, initialValue );
1410         }
1411
1412         /// <summary>
1413         /// Creates an animation to animate the mixColor of the named visual.
1414         /// </summary>
1415         /// <since_tizen> 3 </since_tizen>
1416         public Animation AnimateColor( string targetVisual, object destinationColor, int startTime, int endTime, AlphaFunction.BuiltinFunctions? alphaFunction = null, object initialColor = null )
1417         {
1418             Animation animation = null;
1419             {
1420                 PropertyMap _animator = new PropertyMap();
1421                 if( alphaFunction != null )
1422                 {
1423                     _animator.Add("alphaFunction", new PropertyValue( AlphaFunction.BuiltinToPropertyKey(alphaFunction) ) );
1424                 }
1425
1426                 PropertyMap _timePeriod = new PropertyMap();
1427                 _timePeriod.Add( "duration", new PropertyValue((endTime-startTime)/1000.0f) );
1428                 _timePeriod.Add( "delay", new PropertyValue( startTime/1000.0f ) );
1429                 _animator.Add( "timePeriod", new PropertyValue( _timePeriod ) );
1430
1431                 PropertyMap _transition = new PropertyMap();
1432                 _transition.Add( "animator", new PropertyValue( _animator ) );
1433                 _transition.Add( "target", new PropertyValue( targetVisual ) );
1434                 _transition.Add( "property", new PropertyValue( "mixColor" ) );
1435
1436                 if( initialColor != null )
1437                 {
1438                     PropertyValue initValue = PropertyValue.CreateFromObject( initialColor );
1439                     _transition.Add( "initialValue", initValue );
1440                 }
1441
1442                 PropertyValue destValue = PropertyValue.CreateFromObject( destinationColor );
1443                 _transition.Add( "targetValue", destValue );
1444                 TransitionData _transitionData = new TransitionData( _transition );
1445
1446                 animation = new Animation( NDalicManualPINVOKE.View_CreateTransition(swigCPtr, TransitionData.getCPtr(_transitionData)), true );
1447                 if (NDalicPINVOKE.SWIGPendingException.Pending)
1448                     throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1449             }
1450             return animation;
1451         }
1452
1453         /// <summary>
1454         /// The mutually exclusive with BACKGROUND_COLOR and BACKGROUND type Map.
1455         /// </summary>
1456         /// <since_tizen> 3 </since_tizen>
1457         public string BackgroundImage
1458         {
1459             get
1460             {
1461                 string backgroundImage = "";
1462
1463                 Tizen.NUI.PropertyMap background = Background;
1464                 int visualType = 0;
1465                 background.Find(Visual.Property.Type)?.Get(out visualType);
1466                 if (visualType == (int)Visual.Type.Image)
1467                 {
1468                     background.Find(ImageVisualProperty.URL)?.Get(out backgroundImage);
1469                 }
1470
1471                 return backgroundImage;
1472             }
1473             set
1474             {
1475                 SetProperty(View.Property.BACKGROUND, new Tizen.NUI.PropertyValue(value));
1476             }
1477         }
1478
1479         /// <summary>
1480         /// The background of view.
1481         /// </summary>
1482         /// <since_tizen> 3 </since_tizen>
1483         public Tizen.NUI.PropertyMap Background
1484         {
1485             get
1486             {
1487                 Tizen.NUI.PropertyMap temp = new Tizen.NUI.PropertyMap();
1488                 GetProperty( View.Property.BACKGROUND ).Get(temp);
1489                 return temp;
1490             }
1491             set
1492             {
1493                 SetProperty(View.Property.BACKGROUND, new Tizen.NUI.PropertyValue(value));
1494             }
1495         }
1496
1497
1498         /// <summary>
1499         /// The current state of the view.
1500         /// </summary>
1501         /// <since_tizen> 3 </since_tizen>
1502         public States State
1503         {
1504             get
1505             {
1506                 int temp = 0;
1507                 if (GetProperty(View.Property.STATE).Get(out temp) == false)
1508                 {
1509                     NUILog.Error("State get error!");
1510                 }
1511                 switch (temp)
1512                 {
1513                     case 0:
1514                     {
1515                         return States.Normal;
1516                     }
1517                     case 1:
1518                     {
1519                         return States.Focused;
1520                     }
1521                     case 2:
1522                     {
1523                         return States.Disabled;
1524                     }
1525                     default:
1526                     {
1527                         return States.Normal;
1528                     }
1529                 }
1530             }
1531             set
1532             {
1533                 SetProperty(View.Property.STATE, new Tizen.NUI.PropertyValue((int)value));
1534             }
1535         }
1536
1537         /// <summary>
1538         /// The current sub state of the view.
1539         /// </summary>
1540         /// <since_tizen> 3 </since_tizen>
1541         public States SubState
1542         {
1543             get
1544             {
1545                 string temp;
1546                 if (GetProperty(View.Property.SUB_STATE).Get(out temp) == false)
1547                 {
1548                     NUILog.Error("subState get error!");
1549                 }
1550                 switch (temp)
1551                 {
1552                     case "NORMAL":
1553                         return States.Normal;
1554                     case "FOCUSED":
1555                         return States.Focused;
1556                     case "DISABLED":
1557                         return States.Disabled;
1558                     default:
1559                         return States.Normal;
1560                 }
1561             }
1562             set
1563             {
1564                 string valueToString = "";
1565                 switch (value)
1566                 {
1567                     case States.Normal:
1568                     {
1569                         valueToString = "NORMAL";
1570                         break;
1571                     }
1572                     case States.Focused:
1573                     {
1574                         valueToString = "FOCUSED";
1575                         break;
1576                     }
1577                     case States.Disabled:
1578                     {
1579                         valueToString = "DISABLED";
1580                         break;
1581                     }
1582                     default:
1583                     {
1584                         valueToString = "NORMAL";
1585                         break;
1586                     }
1587                 }
1588                 SetProperty(View.Property.SUB_STATE, new Tizen.NUI.PropertyValue(valueToString));
1589             }
1590         }
1591
1592         /// <summary>
1593         /// Displays a tooltip
1594         /// </summary>
1595         /// <since_tizen> 3 </since_tizen>
1596         public Tizen.NUI.PropertyMap Tooltip
1597         {
1598             get
1599             {
1600                 Tizen.NUI.PropertyMap temp = new Tizen.NUI.PropertyMap();
1601                 GetProperty(View.Property.TOOLTIP).Get(temp);
1602                 return temp;
1603             }
1604             set
1605             {
1606                 SetProperty(View.Property.TOOLTIP, new Tizen.NUI.PropertyValue(value));
1607             }
1608         }
1609
1610         /// <summary>
1611         /// Displays a tooltip as a text.
1612         /// </summary>
1613         /// <since_tizen> 3 </since_tizen>
1614         public string TooltipText
1615         {
1616             set
1617             {
1618                 SetProperty(View.Property.TOOLTIP, new Tizen.NUI.PropertyValue(value));
1619             }
1620         }
1621
1622         private int LeftFocusableViewId
1623         {
1624             get
1625             {
1626                 int temp = 0;
1627                 GetProperty(View.Property.LEFT_FOCUSABLE_VIEW_ID).Get(out temp);
1628                 return temp;
1629             }
1630             set
1631             {
1632                 SetProperty(View.Property.LEFT_FOCUSABLE_VIEW_ID, new Tizen.NUI.PropertyValue(value));
1633             }
1634         }
1635
1636         private int RightFocusableViewId
1637         {
1638             get
1639             {
1640                 int temp = 0;
1641                 GetProperty(View.Property.RIGHT_FOCUSABLE_VIEW_ID).Get(out temp);
1642                 return temp;
1643             }
1644             set
1645             {
1646                 SetProperty(View.Property.RIGHT_FOCUSABLE_VIEW_ID, new Tizen.NUI.PropertyValue(value));
1647             }
1648         }
1649
1650         private int UpFocusableViewId
1651         {
1652             get
1653             {
1654                 int temp = 0;
1655                 GetProperty(View.Property.UP_FOCUSABLE_VIEW_ID).Get(out temp);
1656                 return temp;
1657             }
1658             set
1659             {
1660                 SetProperty(View.Property.UP_FOCUSABLE_VIEW_ID, new Tizen.NUI.PropertyValue(value));
1661             }
1662         }
1663
1664         private int DownFocusableViewId
1665         {
1666             get
1667             {
1668                 int temp = 0;
1669                 GetProperty(View.Property.DOWN_FOCUSABLE_VIEW_ID).Get(out temp);
1670                 return temp;
1671             }
1672             set
1673             {
1674                 SetProperty(View.Property.DOWN_FOCUSABLE_VIEW_ID, new Tizen.NUI.PropertyValue(value));
1675             }
1676         }
1677
1678         /// <summary>
1679         /// The Child property of FlexContainer.<br />
1680         /// The proportion of the free space in the container, the flex item will receive.<br />
1681         /// If all items in the container set this property, their sizes will be proportional to the specified flex factor.<br />
1682         /// </summary>
1683         /// <since_tizen> 3 </since_tizen>
1684         public float Flex
1685         {
1686             get
1687             {
1688                 float temp = 0.0f;
1689                 GetProperty(FlexContainer.ChildProperty.FLEX).Get(out temp);
1690                 return temp;
1691             }
1692             set
1693             {
1694                 SetProperty(FlexContainer.ChildProperty.FLEX, new Tizen.NUI.PropertyValue(value));
1695             }
1696         }
1697
1698         /// <summary>
1699         /// The Child property of FlexContainer.<br />
1700         /// The alignment of the flex item along the cross axis, which, if set, overides the default alignment for all items in the container.<br />
1701         /// </summary>
1702         /// <since_tizen> 3 </since_tizen>
1703         public int AlignSelf
1704         {
1705             get
1706             {
1707                 int temp = 0;
1708                 GetProperty(FlexContainer.ChildProperty.ALIGN_SELF).Get(out temp);
1709                 return temp;
1710             }
1711             set
1712             {
1713                 SetProperty(FlexContainer.ChildProperty.ALIGN_SELF, new Tizen.NUI.PropertyValue(value));
1714             }
1715         }
1716
1717         /// <summary>
1718         /// The Child property of FlexContainer.<br />
1719         /// The space around the flex item.<br />
1720         /// </summary>
1721         /// <since_tizen> 3 </since_tizen>
1722         public Vector4 FlexMargin
1723         {
1724             get
1725             {
1726                 Vector4 temp = new Vector4(0.0f, 0.0f, 0.0f, 0.0f);
1727                 GetProperty(FlexContainer.ChildProperty.FLEX_MARGIN).Get(temp);
1728                 return temp;
1729             }
1730             set
1731             {
1732                 SetProperty(FlexContainer.ChildProperty.FLEX_MARGIN, new Tizen.NUI.PropertyValue(value));
1733             }
1734         }
1735
1736         /// <summary>
1737         /// The top-left cell this child occupies, if not set, the first available cell is used.
1738         /// </summary>
1739         /// <since_tizen> 3 </since_tizen>
1740         public Vector2 CellIndex
1741         {
1742             get
1743             {
1744                 Vector2 temp = new Vector2(0.0f, 0.0f);
1745                 GetProperty(TableView.ChildProperty.CELL_INDEX).Get(temp);
1746                 return temp;
1747             }
1748             set
1749             {
1750                 SetProperty(TableView.ChildProperty.CELL_INDEX, new Tizen.NUI.PropertyValue(value));
1751             }
1752         }
1753
1754         /// <summary>
1755         /// The number of rows this child occupies, if not set, the default value is 1.
1756         /// </summary>
1757         /// <since_tizen> 3 </since_tizen>
1758         public float RowSpan
1759         {
1760             get
1761             {
1762                 float temp = 0.0f;
1763                 GetProperty(TableView.ChildProperty.ROW_SPAN).Get(out temp);
1764                 return temp;
1765             }
1766             set
1767             {
1768                 SetProperty(TableView.ChildProperty.ROW_SPAN, new Tizen.NUI.PropertyValue(value));
1769             }
1770         }
1771
1772         /// <summary>
1773         /// The number of columns this child occupies, if not set, the default value is 1.
1774         /// </summary>
1775         /// <since_tizen> 3 </since_tizen>
1776         public float ColumnSpan
1777         {
1778             get
1779             {
1780                 float temp = 0.0f;
1781                 GetProperty(TableView.ChildProperty.COLUMN_SPAN).Get(out temp);
1782                 return temp;
1783             }
1784             set
1785             {
1786                 SetProperty(TableView.ChildProperty.COLUMN_SPAN, new Tizen.NUI.PropertyValue(value));
1787             }
1788         }
1789
1790         /// <summary>
1791         /// The horizontal alignment of this child inside the cells, if not set, the default value is 'left'.
1792         /// </summary>
1793         /// <since_tizen> 3 </since_tizen>
1794         public Tizen.NUI.HorizontalAlignmentType CellHorizontalAlignment
1795         {
1796             get
1797             {
1798                 string temp;
1799                 if (GetProperty(TableView.ChildProperty.CELL_HORIZONTAL_ALIGNMENT).Get(out temp) == false)
1800                 {
1801                     NUILog.Error("CellHorizontalAlignment get error!");
1802                 }
1803
1804                 switch (temp)
1805                 {
1806                     case "left":
1807                         return Tizen.NUI.HorizontalAlignmentType.Left;
1808                     case "center":
1809                         return Tizen.NUI.HorizontalAlignmentType.Center;
1810                     case "right":
1811                         return Tizen.NUI.HorizontalAlignmentType.Right;
1812                     default:
1813                         return Tizen.NUI.HorizontalAlignmentType.Left;
1814                 }
1815             }
1816             set
1817             {
1818                 string valueToString = "";
1819                 switch (value)
1820                 {
1821                     case Tizen.NUI.HorizontalAlignmentType.Left:
1822                     {
1823                         valueToString = "left";
1824                         break;
1825                     }
1826                     case Tizen.NUI.HorizontalAlignmentType.Center:
1827                     {
1828                         valueToString = "center";
1829                         break;
1830                     }
1831                     case Tizen.NUI.HorizontalAlignmentType.Right:
1832                     {
1833                         valueToString = "right";
1834                         break;
1835                     }
1836                     default:
1837                     {
1838                         valueToString = "left";
1839                         break;
1840                     }
1841                 }
1842                 SetProperty(TableView.ChildProperty.CELL_HORIZONTAL_ALIGNMENT, new Tizen.NUI.PropertyValue(valueToString));
1843             }
1844         }
1845
1846         /// <summary>
1847         /// The vertical alignment of this child inside the cells, if not set, the default value is 'top'.
1848         /// </summary>
1849         /// <since_tizen> 3 </since_tizen>
1850         public Tizen.NUI.VerticalAlignmentType CellVerticalAlignment
1851         {
1852             get
1853             {
1854                 string temp;
1855                 GetProperty(TableView.ChildProperty.CELL_VERTICAL_ALIGNMENT).Get(out temp);
1856                 {
1857                     NUILog.Error("CellVerticalAlignment get error!");
1858                 }
1859
1860                 switch (temp)
1861                 {
1862                     case "top":
1863                         return Tizen.NUI.VerticalAlignmentType.Top;
1864                     case "center":
1865                         return Tizen.NUI.VerticalAlignmentType.Center;
1866                     case "bottom":
1867                         return Tizen.NUI.VerticalAlignmentType.Bottom;
1868                     default:
1869                         return Tizen.NUI.VerticalAlignmentType.Top;
1870                 }
1871             }
1872             set
1873             {
1874                 string valueToString = "";
1875                 switch (value)
1876                 {
1877                     case Tizen.NUI.VerticalAlignmentType.Top:
1878                     {
1879                         valueToString = "top";
1880                         break;
1881                     }
1882                     case Tizen.NUI.VerticalAlignmentType.Center:
1883                     {
1884                         valueToString = "center";
1885                         break;
1886                     }
1887                     case Tizen.NUI.VerticalAlignmentType.Bottom:
1888                     {
1889                         valueToString = "bottom";
1890                         break;
1891                     }
1892                     default:
1893                     {
1894                         valueToString = "top";
1895                         break;
1896                     }
1897                 }
1898                 SetProperty(TableView.ChildProperty.CELL_VERTICAL_ALIGNMENT, new Tizen.NUI.PropertyValue(valueToString));
1899             }
1900         }
1901
1902         /// <summary>
1903         /// The left focusable view.<br />
1904         /// This will return null if not set.<br />
1905         /// This will also return null if the specified left focusable view is not on a window.<br />
1906         /// </summary>
1907         /// <since_tizen> 3 </since_tizen>
1908         public View LeftFocusableView
1909         {
1910             // As native side will be only storing IDs so need a logic to convert View to ID and vice-versa.
1911             get
1912             {
1913                 if (LeftFocusableViewId >= 0)
1914                 {
1915                     return ConvertIdToView((uint)LeftFocusableViewId);
1916                 }
1917                 return null;
1918             }
1919             set
1920             {
1921                 if(value)
1922                 {
1923                     LeftFocusableViewId = (int)value.GetId();
1924                 }
1925                 else
1926                 {
1927                     LeftFocusableViewId = -1;
1928                 }
1929             }
1930         }
1931
1932         /// <summary>
1933         /// The right focusable view.<br />
1934         /// This will return null if not set.<br />
1935         /// This will also return null if the specified right focusable view is not on a window.<br />
1936         /// </summary>
1937         /// <since_tizen> 3 </since_tizen>
1938         public View RightFocusableView
1939         {
1940             // As native side will be only storing IDs so need a logic to convert View to ID and vice-versa.
1941             get
1942             {
1943                 if (RightFocusableViewId >= 0)
1944                 {
1945                     return ConvertIdToView((uint)RightFocusableViewId);
1946                 }
1947                 return null;
1948             }
1949             set
1950             {
1951                 if(value)
1952                 {
1953                     RightFocusableViewId = (int)value.GetId();
1954                 }
1955                 else
1956                 {
1957                     RightFocusableViewId = -1;
1958                 }
1959             }
1960         }
1961
1962         /// <summary>
1963         /// The up focusable view.<br />
1964         /// This will return null if not set.<br />
1965         /// This will also return null if the specified up focusable view is not on a window.<br />
1966         /// </summary>
1967         /// <since_tizen> 3 </since_tizen>
1968         public View UpFocusableView
1969         {
1970             // As native side will be only storing IDs so need a logic to convert View to ID and vice-versa.
1971             get
1972             {
1973                 if (UpFocusableViewId >= 0)
1974                 {
1975                     return ConvertIdToView((uint)UpFocusableViewId);
1976                 }
1977                 return null;
1978             }
1979             set
1980             {
1981                 if(value)
1982                 {
1983                     UpFocusableViewId = (int)value.GetId();
1984                 }
1985                 else
1986                 {
1987                     UpFocusableViewId = -1;
1988                 }
1989             }
1990         }
1991
1992         /// <summary>
1993         /// The down focusable view.<br />
1994         /// This will return null if not set.<br />
1995         /// This will also return null if the specified down focusable view is not on a window.<br />
1996         /// </summary>
1997         /// <since_tizen> 3 </since_tizen>
1998         public View DownFocusableView
1999         {
2000             // As native side will be only storing IDs so need a logic to convert View to ID and vice-versa.
2001             get
2002             {
2003                 if (DownFocusableViewId >= 0)
2004                 {
2005                     return ConvertIdToView((uint)DownFocusableViewId);
2006                 }
2007                 return null;
2008             }
2009             set
2010             {
2011                 if(value)
2012                 {
2013                     DownFocusableViewId = (int)value.GetId();
2014                 }
2015                 else
2016                 {
2017                     DownFocusableViewId = -1;
2018                 }
2019             }
2020         }
2021
2022         /// <summary>
2023         /// Whether the view should be focusable by keyboard navigation.
2024         /// </summary>
2025         /// <since_tizen> 3 </since_tizen>
2026         public bool Focusable
2027         {
2028             set
2029             {
2030                 SetKeyboardFocusable(value);
2031             }
2032             get
2033             {
2034                 return IsKeyboardFocusable();
2035             }
2036         }
2037
2038         /// <summary>
2039         /// Enumeration for describing the states of the view.
2040         /// </summary>
2041         /// <since_tizen> 3 </since_tizen>
2042         public enum States
2043         {
2044             /// <summary>
2045             /// The normal state.
2046             /// </summary>
2047             Normal,
2048             /// <summary>
2049             /// The focused state.
2050             /// </summary>
2051             Focused,
2052             /// <summary>
2053             /// The disabled state.
2054             /// </summary>
2055             Disabled
2056         }
2057
2058         /// <summary>
2059         ///  Retrieves the position of the view.<br />
2060         ///  The coordinates are relative to the view's parent.<br />
2061         /// </summary>
2062         /// <since_tizen> 3 </since_tizen>
2063         public Position CurrentPosition
2064         {
2065             get
2066             {
2067                 return GetCurrentPosition();
2068             }
2069         }
2070
2071         /// <summary>
2072         /// Sets the size of a view for the width and the height.<br />
2073         /// Geometry can be scaled to fit within this area.<br />
2074         /// This does not interfere with the view's scale factor.<br />
2075         /// The views default depth is the minimum of width and height.<br />
2076         /// </summary>
2077         /// <since_tizen> 3 </since_tizen>
2078         public Size2D Size2D
2079         {
2080             get
2081             {
2082                 Size temp = new Size(0.0f, 0.0f, 0.0f);
2083                 GetProperty(View.Property.SIZE).Get(temp);
2084                 Size2D size = new Size2D((int)temp.Width, (int)temp.Height);
2085                 return size;
2086             }
2087             set
2088             {
2089                 SetProperty(View.Property.SIZE, new Tizen.NUI.PropertyValue(new Size(value)));
2090             }
2091         }
2092
2093         /// <summary>
2094         ///  Retrieves the size of the view.<br />
2095         ///  The coordinates are relative to the view's parent.<br />
2096         /// </summary>
2097         /// <since_tizen> 3 </since_tizen>
2098         public Size2D CurrentSize
2099         {
2100             get
2101             {
2102                 return GetCurrentSize();
2103             }
2104         }
2105
2106         /// <summary>
2107         /// [Obsolete("Please do not use! this will be deprecated. Please use Visibility instead.")]
2108         /// </summary>
2109         /// <since_tizen> 3 </since_tizen>
2110         [Obsolete("Please do not use! This will be deprecated! Please use Visibility instead!")]
2111         [EditorBrowsable(EditorBrowsableState.Never)]
2112         public bool Visible
2113         {
2114             get
2115             {
2116                 return IsVisible();
2117             }
2118         }
2119
2120         /// <summary>
2121         /// Retrieves and sets the view's opacity.<br />
2122         /// </summary>
2123         /// <since_tizen> 3 </since_tizen>
2124         public float Opacity
2125         {
2126             get
2127             {
2128                 float temp = 0.0f;
2129                 GetProperty(View.Property.OPACITY).Get(out temp);
2130                 return temp;
2131             }
2132             set
2133             {
2134                 SetProperty(View.Property.OPACITY, new Tizen.NUI.PropertyValue(value));
2135             }
2136         }
2137
2138         /// <summary>
2139         /// Sets the position of the view for X and Y.<br />
2140         /// By default, sets the position vector between the parent origin and the pivot point (default).<br />
2141         /// If the position inheritance is disabled, sets the world position.<br />
2142         /// </summary>
2143         /// <since_tizen> 3 </since_tizen>
2144         public Position2D Position2D
2145         {
2146             get
2147             {
2148                 Position temp = new Position(0.0f, 0.0f, 0.0f);
2149                 GetProperty(View.Property.POSITION).Get(temp);
2150                 return new Position2D(temp);
2151             }
2152             set
2153             {
2154                 SetProperty(View.Property.POSITION, new Tizen.NUI.PropertyValue(new Position(value)));
2155             }
2156         }
2157
2158         /// <summary>
2159         /// Retrieves the screen postion of the view.<br />
2160         /// </summary>
2161         /// <since_tizen> 3 </since_tizen>
2162         public Vector2 ScreenPosition
2163         {
2164             get
2165             {
2166                 Vector2 temp = new Vector2(0.0f, 0.0f);
2167                 GetProperty(View.Property.SCREEN_POSITION).Get(temp);
2168                 // Dali's default layer is default center origin. need to change as top left.
2169                 // NUI's Layer is like a transparent film which covers entire window. (Layer is not an actor of Dali)
2170                 // otherwise, this makes ScreenPosition as wrong value.
2171                 temp -= (Window.Instance.GetSize() * 0.5f);
2172                 return temp;
2173             }
2174         }
2175
2176         /// <summary>
2177         /// Determines whether the pivot point should be used to determine the position of the view.
2178         /// This is true by default.
2179         /// </summary>
2180         /// <remarks>If false, then the top-left of the view is used for the position.
2181         /// Setting this to false will allow scaling or rotation around the anchor-point without affecting the view's position.
2182         /// </remarks>
2183         /// <since_tizen> 3 </since_tizen>
2184         public bool PositionUsesPivotPoint
2185         {
2186             get
2187             {
2188                 bool temp = false;
2189                 GetProperty(View.Property.POSITION_USES_ANCHOR_POINT).Get(out temp);
2190                 return temp;
2191             }
2192             set
2193             {
2194                 SetProperty(View.Property.POSITION_USES_ANCHOR_POINT, new Tizen.NUI.PropertyValue(value));
2195             }
2196         }
2197
2198         /// <summary>
2199         /// Please do not use! this will be deprecated.
2200         /// </summary>
2201         /// Please do not use! this will be deprecated!
2202         /// Instead please use PositionUsesPivotPoint.
2203         /// <since_tizen> 3 </since_tizen>
2204         [Obsolete("Please do not use! This will be deprecated! Please use PositionUsesPivotPoint instead! " +
2205             "Like: " +
2206             "View view = new View(); " +
2207             "view.PivotPoint = PivotPoint.Center; " +
2208             "view.PositionUsesPivotPoint = true;")]
2209         [EditorBrowsable(EditorBrowsableState.Never)]
2210         public bool PositionUsesAnchorPoint
2211         {
2212             get
2213             {
2214                 bool temp = false;
2215                 GetProperty(View.Property.POSITION_USES_ANCHOR_POINT).Get(out temp);
2216                 return temp;
2217             }
2218             set
2219             {
2220                 SetProperty(View.Property.POSITION_USES_ANCHOR_POINT, new Tizen.NUI.PropertyValue(value));
2221             }
2222         }
2223
2224         internal bool FocusState
2225         {
2226             get
2227             {
2228                 return IsKeyboardFocusable();
2229             }
2230             set
2231             {
2232                 SetKeyboardFocusable(value);
2233             }
2234         }
2235
2236         /// <summary>
2237         /// Queries whether the view is connected to the stage.<br />
2238         /// When a view is connected, it will be directly or indirectly parented to the root view.<br />
2239         /// </summary>
2240         /// <since_tizen> 3 </since_tizen>
2241         public bool IsOnWindow
2242         {
2243             get
2244             {
2245                 return OnWindow();
2246             }
2247         }
2248
2249         /// <summary>
2250         /// Gets the depth in the hierarchy for the view.
2251         /// </summary>
2252         /// <since_tizen> 3 </since_tizen>
2253         public int HierarchyDepth
2254         {
2255             get
2256             {
2257                 return GetHierarchyDepth();
2258             }
2259         }
2260
2261         /// <summary>
2262         /// Sets the sibling order of the view so the depth position can be defined within the same parent.
2263         /// </summary>
2264         /// <remarks>
2265         /// Note the initial value is 0.
2266         /// Raise, Lower, RaiseToTop, LowerToBottom, RaiseAbove, and LowerBelow will override the sibling order.
2267         /// The values set by this property will likely change.
2268         /// </remarks>
2269         /// <since_tizen> 3 </since_tizen>
2270         public int SiblingOrder
2271         {
2272             get
2273             {
2274                 int temp = 0;
2275                 GetProperty(View.Property.SIBLING_ORDER).Get(out temp);
2276                 return temp;
2277             }
2278             set
2279             {
2280                 SetProperty(View.Property.SIBLING_ORDER, new Tizen.NUI.PropertyValue(value));
2281             }
2282         }
2283
2284         /// <summary>
2285         /// Returns the natural size of the view.
2286         /// </summary>
2287         /// <remarks>
2288         /// Deriving classes stipulate the natural size and by default a view has a zero natural size.
2289         /// </remarks>
2290         /// /// Please do not use! this will be deprecated!
2291         /// Instead please use NaturalSize2D.
2292         /// <since_tizen> 3 </since_tizen>
2293         [Obsolete("Please do not use! This will be deprecated! Please use NaturalSize2D instead! " +
2294             "Like: " +
2295             "TextLabel label = new TextLabel(\"Hello World!\"); " +
2296             "Size2D size = label.NaturalSize2D;")]
2297         [EditorBrowsable(EditorBrowsableState.Never)]
2298         public Vector3 NaturalSize
2299         {
2300             get
2301             {
2302                 Vector3 ret = new Vector3(NDalicPINVOKE.Actor_GetNaturalSize(swigCPtr), true);
2303                 if (NDalicPINVOKE.SWIGPendingException.Pending)
2304                     throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2305                 return ret;
2306             }
2307         }
2308
2309         /// <summary>
2310         /// Returns the natural size (Size2D) of the view.
2311         /// </summary>
2312         /// <remarks>
2313         /// Deriving classes stipulate the natural size and by default a view has a zero natural size.
2314         /// </remarks>
2315         /// <since_tizen> 4 </since_tizen>
2316         public Size2D NaturalSize2D
2317         {
2318             get
2319             {
2320                 Vector3 temp = new Vector3(NDalicPINVOKE.Actor_GetNaturalSize(swigCPtr), true);
2321                 if (NDalicPINVOKE.SWIGPendingException.Pending)
2322                     throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2323
2324                 return new Size2D((int)temp.Width, (int)temp.Height);
2325             }
2326         }
2327
2328         /// <summary>
2329         /// Shows the view.
2330         /// </summary>
2331         /// <remarks>
2332         /// This is an asynchronous method.
2333         /// </remarks>
2334         /// <since_tizen> 3 </since_tizen>
2335         public void Show()
2336         {
2337             SetVisible(true);
2338         }
2339
2340         /// <summary>
2341         /// Hides the view.
2342         /// </summary>
2343         /// <remarks>
2344         /// This is an asynchronous method.
2345         /// If the view is hidden, then the view and its children will not be rendered.
2346         /// This is regardless of the individual visibility of the children, i.e., the view will only be rendered if all of its parents are shown.
2347         /// </remarks>
2348         /// <since_tizen> 3 </since_tizen>
2349         public void Hide()
2350         {
2351             SetVisible(false);
2352         }
2353
2354         internal void Raise()
2355         {
2356             var parentChildren = Parent?.Children;
2357
2358             if (parentChildren != null)
2359             {
2360                 int currentIndex = parentChildren.IndexOf(this);
2361
2362                 // If the view is not already the last item in the list.
2363                 if (currentIndex != parentChildren.Count -1)
2364                 {
2365                     View temp = parentChildren[currentIndex + 1];
2366                     parentChildren[currentIndex + 1] = this;
2367                     parentChildren[currentIndex] = temp;
2368                 }
2369             }
2370
2371             NDalicPINVOKE.Raise(swigCPtr);
2372             if (NDalicPINVOKE.SWIGPendingException.Pending)
2373                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2374         }
2375
2376         internal void Lower()
2377         {
2378             var parentChildren = Parent?.Children;
2379
2380             if (parentChildren != null)
2381             {
2382                 int currentIndex = parentChildren.IndexOf(this);
2383
2384                 // If the view is not already the first item in the list.
2385                 if (currentIndex > 0)
2386                 {
2387                     View temp = parentChildren[currentIndex - 1];
2388                     parentChildren[currentIndex - 1] = this;
2389                     parentChildren[currentIndex] = temp;
2390                 }
2391             }
2392
2393             NDalicPINVOKE.Lower(swigCPtr);
2394             if (NDalicPINVOKE.SWIGPendingException.Pending)
2395                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2396         }
2397
2398         /// <summary>
2399         /// Raises the view above all other views.
2400         /// </summary>
2401         /// <remarks>
2402         /// Sibling order of views within the parent will be updated automatically.
2403         /// Once a raise or lower API is used, that view will then have an exclusive sibling order independent of insertion.
2404         /// </remarks>
2405         /// <since_tizen> 3 </since_tizen>
2406         public void RaiseToTop()
2407         {
2408             var parentChildren = Parent?.Children;
2409
2410             if (parentChildren != null)
2411             {
2412                 parentChildren.Remove(this);
2413                 parentChildren.Add(this);
2414             }
2415
2416             NDalicPINVOKE.RaiseToTop(swigCPtr);
2417             if (NDalicPINVOKE.SWIGPendingException.Pending)
2418                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2419         }
2420
2421         /// <summary>
2422         /// Lowers the view to the bottom of all views.
2423         /// </summary>
2424         /// <remarks>
2425         /// The sibling order of views within the parent will be updated automatically.
2426         /// Once a raise or lower API is used that view will then have an exclusive sibling order independent of insertion.
2427         /// </remarks>
2428         /// <since_tizen> 3 </since_tizen>
2429         public void LowerToBottom()
2430         {
2431             var parentChildren = Parent?.Children;
2432
2433             if (parentChildren != null)
2434             {
2435                 parentChildren.Remove(this);
2436                 parentChildren.Insert(0, this);
2437             }
2438
2439             NDalicPINVOKE.LowerToBottom(swigCPtr);
2440             if (NDalicPINVOKE.SWIGPendingException.Pending)
2441                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2442         }
2443
2444         /// <summary>
2445         /// Queries if all resources required by a view are loaded and ready.
2446         /// </summary>
2447         /// <remarks>Most resources are only loaded when the control is placed on the stage.
2448         /// </remarks>
2449         /// <since_tizen> 3 </since_tizen>
2450         public bool IsResourceReady()
2451         {
2452             bool ret = NDalicPINVOKE.IsResourceReady(swigCPtr);
2453             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2454             return ret;
2455         }
2456
2457         /// <summary>
2458         /// Raises the view to above the target view.
2459         /// </summary>
2460         /// <remarks>The sibling order of views within the parent will be updated automatically.
2461         /// Views on the level above the target view will still be shown above this view.
2462         /// Raising this view above views with the same sibling order as each other will raise this view above them.
2463         /// Once a raise or lower API is used that view will then have an exclusive sibling order independent of insertion.
2464         /// </remarks>
2465         /// <param name="target">Will be raised above this view.</param>
2466         internal void RaiseAbove(View target)
2467         {
2468             var parentChildren = Parent?.Children;
2469
2470             if (parentChildren != null)
2471             {
2472                 int currentIndex = parentChildren.IndexOf(this);
2473                 int targetIndex = parentChildren.IndexOf(target);
2474
2475                 // If the currentIndex is less than the target index and the target has the same parent.
2476                 if (currentIndex < targetIndex)
2477                 {
2478                     parentChildren.Remove(this);
2479                     parentChildren.Insert(targetIndex, this);
2480                 }
2481             }
2482
2483             NDalicPINVOKE.RaiseAbove(swigCPtr, View.getCPtr(target));
2484             if (NDalicPINVOKE.SWIGPendingException.Pending)
2485                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2486         }
2487
2488         /// <summary>
2489         /// Lowers the view to below the target view.
2490         /// </summary>
2491         /// <remarks>The sibling order of views within the parent will be updated automatically.
2492         /// Lowering this view below views with the same sibling order as each other will lower this view above them.
2493         /// Once a raise or lower API is used that view will then have an exclusive sibling order independent of insertion.
2494         /// </remarks>
2495         /// <param name="target">Will be lowered below this view.</param>
2496         internal void LowerBelow(View target)
2497         {
2498             var parentChildren = Parent?.Children;
2499
2500             if (parentChildren != null)
2501             {
2502                 int currentIndex = parentChildren.IndexOf(this);
2503                 int targetIndex = parentChildren.IndexOf(target);
2504
2505                 // If the currentIndex is not already the 0th index and the target has the same parent.
2506                 if ((currentIndex != 0) && (targetIndex != -1) &&
2507                     (currentIndex > targetIndex))
2508                 {
2509                     parentChildren.Remove(this);
2510                     parentChildren.Insert(targetIndex, this);
2511                 }
2512             }
2513
2514             NDalicPINVOKE.LowerBelow(swigCPtr, View.getCPtr(target));
2515             if (NDalicPINVOKE.SWIGPendingException.Pending)
2516                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2517         }
2518
2519         internal string GetName()
2520         {
2521             string ret = NDalicPINVOKE.Actor_GetName(swigCPtr);
2522             if (NDalicPINVOKE.SWIGPendingException.Pending)
2523                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2524             return ret;
2525         }
2526
2527         internal void SetName(string name)
2528         {
2529             NDalicPINVOKE.Actor_SetName(swigCPtr, name);
2530             if (NDalicPINVOKE.SWIGPendingException.Pending)
2531                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2532         }
2533
2534         internal uint GetId()
2535         {
2536             uint ret = NDalicPINVOKE.Actor_GetId(swigCPtr);
2537             if (NDalicPINVOKE.SWIGPendingException.Pending)
2538                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2539             return ret;
2540         }
2541
2542         internal bool IsRoot()
2543         {
2544             bool ret = NDalicPINVOKE.Actor_IsRoot(swigCPtr);
2545             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2546             return ret;
2547         }
2548
2549         internal bool OnWindow()
2550         {
2551             bool ret = NDalicPINVOKE.Actor_OnStage(swigCPtr);
2552             if (NDalicPINVOKE.SWIGPendingException.Pending)
2553                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2554             return ret;
2555         }
2556
2557         /// <summary>
2558         /// Gets the parent layer of this view.If a view has no parent, this method does nothing.
2559         /// </summary>
2560         /// <pre>The view has been initialized. </pre>
2561         /// <returns>the parent layer of view </returns>
2562         /// <since_tizen> 5 </since_tizen>
2563         public Layer GetLayer()
2564         {
2565             IntPtr cPtr = NDalicPINVOKE.Actor_GetLayer(swigCPtr);
2566             Layer ret = Registry.GetManagedBaseHandleFromNativePtr(cPtr) as Layer;
2567
2568             if (NDalicPINVOKE.SWIGPendingException.Pending)
2569                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2570             return ret;
2571         }
2572
2573         /// <summary>
2574         /// Removes a view from its parent view or layer. If a view has no parent, this method does nothing.
2575         /// </summary>
2576         /// <pre>The (child) view has been initialized. </pre>
2577         /// <since_tizen> 4 </since_tizen>
2578         public void Unparent()
2579         {
2580             GetParent()?.Remove(this);
2581         }
2582
2583         /// <summary>
2584         /// Search through this view's hierarchy for a view with the given name.
2585         /// The view itself is also considered in the search.
2586         /// </summary>
2587         /// <pre>The view has been initialized.</pre>
2588         /// <param name="viewName">The name of the view to find.</param>
2589         /// <returns>A handle to the view if found, or an empty handle if not.</returns>
2590         /// <since_tizen> 3 </since_tizen>
2591         public View FindChildByName(string viewName)
2592         {
2593             IntPtr cPtr = NDalicPINVOKE.Actor_FindChildByName(swigCPtr, viewName);
2594
2595             View ret = Registry.GetManagedBaseHandleFromNativePtr(cPtr) as View;
2596
2597             if (NDalicPINVOKE.SWIGPendingException.Pending)
2598                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2599             return ret;
2600         }
2601
2602         internal View FindChildById(uint id)
2603         {
2604             IntPtr cPtr = NDalicPINVOKE.Actor_FindChildById(swigCPtr, id);
2605
2606             View ret = Registry.GetManagedBaseHandleFromNativePtr(cPtr) as View;
2607
2608             if (NDalicPINVOKE.SWIGPendingException.Pending)
2609                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2610             return ret;
2611         }
2612
2613         internal void SetParentOrigin(Vector3 origin)
2614         {
2615             NDalicPINVOKE.Actor_SetParentOrigin(swigCPtr, Vector3.getCPtr(origin));
2616             if (NDalicPINVOKE.SWIGPendingException.Pending)
2617                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2618         }
2619
2620         internal Vector3 GetCurrentParentOrigin()
2621         {
2622             Vector3 ret = new Vector3(NDalicPINVOKE.Actor_GetCurrentParentOrigin(swigCPtr), true);
2623             if (NDalicPINVOKE.SWIGPendingException.Pending)
2624                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2625             return ret;
2626         }
2627
2628         internal void SetAnchorPoint(Vector3 anchorPoint)
2629         {
2630             NDalicPINVOKE.Actor_SetAnchorPoint(swigCPtr, Vector3.getCPtr(anchorPoint));
2631             if (NDalicPINVOKE.SWIGPendingException.Pending)
2632                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2633         }
2634
2635         internal Vector3 GetCurrentAnchorPoint()
2636         {
2637             Vector3 ret = new Vector3(NDalicPINVOKE.Actor_GetCurrentAnchorPoint(swigCPtr), true);
2638             if (NDalicPINVOKE.SWIGPendingException.Pending)
2639                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2640             return ret;
2641         }
2642
2643         internal void SetSize(float width, float height)
2644         {
2645             NDalicPINVOKE.Actor_SetSize__SWIG_0(swigCPtr, width, height);
2646             if (NDalicPINVOKE.SWIGPendingException.Pending)
2647                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2648         }
2649
2650         internal void SetSize(float width, float height, float depth)
2651         {
2652             NDalicPINVOKE.Actor_SetSize__SWIG_1(swigCPtr, width, height, depth);
2653             if (NDalicPINVOKE.SWIGPendingException.Pending)
2654                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2655         }
2656
2657         internal void SetSize(Vector2 size)
2658         {
2659             NDalicPINVOKE.Actor_SetSize__SWIG_2(swigCPtr, Vector2.getCPtr(size));
2660             if (NDalicPINVOKE.SWIGPendingException.Pending)
2661                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2662         }
2663
2664         internal void SetSize(Vector3 size)
2665         {
2666             NDalicPINVOKE.Actor_SetSize__SWIG_3(swigCPtr, Vector3.getCPtr(size));
2667             if (NDalicPINVOKE.SWIGPendingException.Pending)
2668                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2669         }
2670
2671         internal Vector3 GetTargetSize()
2672         {
2673             Vector3 ret = new Vector3(NDalicPINVOKE.Actor_GetTargetSize(swigCPtr), true);
2674             if (NDalicPINVOKE.SWIGPendingException.Pending)
2675                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2676             return ret;
2677         }
2678
2679         internal Size2D GetCurrentSize()
2680         {
2681             Size ret = new Size(NDalicPINVOKE.Actor_GetCurrentSize(swigCPtr), true);
2682             if (NDalicPINVOKE.SWIGPendingException.Pending)
2683                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2684             Size2D size = new Size2D((int)ret.Width, (int)ret.Height);
2685             return size;
2686         }
2687
2688         internal Vector3 GetNaturalSize()
2689         {
2690             Vector3 ret = new Vector3(NDalicPINVOKE.Actor_GetNaturalSize(swigCPtr), true);
2691             if (NDalicPINVOKE.SWIGPendingException.Pending)
2692                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2693             return ret;
2694         }
2695
2696         internal void SetPosition(float x, float y)
2697         {
2698             NDalicPINVOKE.Actor_SetPosition__SWIG_0(swigCPtr, x, y);
2699             if (NDalicPINVOKE.SWIGPendingException.Pending)
2700                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2701         }
2702
2703         internal void SetPosition(float x, float y, float z)
2704         {
2705             NDalicPINVOKE.Actor_SetPosition__SWIG_1(swigCPtr, x, y, z);
2706             if (NDalicPINVOKE.SWIGPendingException.Pending)
2707                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2708         }
2709
2710         internal void SetPosition(Vector3 position)
2711         {
2712             NDalicPINVOKE.Actor_SetPosition__SWIG_2(swigCPtr, Vector3.getCPtr(position));
2713             if (NDalicPINVOKE.SWIGPendingException.Pending)
2714                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2715         }
2716
2717         internal void SetX(float x)
2718         {
2719             NDalicPINVOKE.Actor_SetX(swigCPtr, x);
2720             if (NDalicPINVOKE.SWIGPendingException.Pending)
2721                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2722         }
2723
2724         internal void SetY(float y)
2725         {
2726             NDalicPINVOKE.Actor_SetY(swigCPtr, y);
2727             if (NDalicPINVOKE.SWIGPendingException.Pending)
2728                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2729         }
2730
2731         internal void SetZ(float z)
2732         {
2733             NDalicPINVOKE.Actor_SetZ(swigCPtr, z);
2734             if (NDalicPINVOKE.SWIGPendingException.Pending)
2735                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2736         }
2737
2738         internal void TranslateBy(Vector3 distance)
2739         {
2740             NDalicPINVOKE.Actor_TranslateBy(swigCPtr, Vector3.getCPtr(distance));
2741             if (NDalicPINVOKE.SWIGPendingException.Pending)
2742                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2743         }
2744
2745         internal Position GetCurrentPosition()
2746         {
2747             Position ret = new Position(NDalicPINVOKE.Actor_GetCurrentPosition(swigCPtr), true);
2748             if (NDalicPINVOKE.SWIGPendingException.Pending)
2749                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2750             return ret;
2751         }
2752
2753         internal Vector3 GetCurrentWorldPosition()
2754         {
2755             Vector3 ret = new Vector3(NDalicPINVOKE.Actor_GetCurrentWorldPosition(swigCPtr), true);
2756             if (NDalicPINVOKE.SWIGPendingException.Pending)
2757                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2758             return ret;
2759         }
2760
2761         internal void SetInheritPosition(bool inherit)
2762         {
2763             NDalicPINVOKE.Actor_SetInheritPosition(swigCPtr, inherit);
2764             if (NDalicPINVOKE.SWIGPendingException.Pending)
2765                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2766         }
2767
2768         internal bool IsPositionInherited()
2769         {
2770             bool ret = NDalicPINVOKE.Actor_IsPositionInherited(swigCPtr);
2771             if (NDalicPINVOKE.SWIGPendingException.Pending)
2772                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2773             return ret;
2774         }
2775
2776         internal void SetOrientation(Degree angle, Vector3 axis)
2777         {
2778             NDalicPINVOKE.Actor_SetOrientation__SWIG_0(swigCPtr, Degree.getCPtr(angle), Vector3.getCPtr(axis));
2779             if (NDalicPINVOKE.SWIGPendingException.Pending)
2780                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2781         }
2782
2783         internal void SetOrientation(Radian angle, Vector3 axis)
2784         {
2785             NDalicPINVOKE.Actor_SetOrientation__SWIG_1(swigCPtr, Radian.getCPtr(angle), Vector3.getCPtr(axis));
2786             if (NDalicPINVOKE.SWIGPendingException.Pending)
2787                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2788         }
2789
2790         internal void SetOrientation(Rotation orientation)
2791         {
2792             NDalicPINVOKE.Actor_SetOrientation__SWIG_2(swigCPtr, Rotation.getCPtr(orientation));
2793             if (NDalicPINVOKE.SWIGPendingException.Pending)
2794                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2795         }
2796
2797         internal void RotateBy(Degree angle, Vector3 axis)
2798         {
2799             NDalicPINVOKE.Actor_RotateBy__SWIG_0(swigCPtr, Degree.getCPtr(angle), Vector3.getCPtr(axis));
2800             if (NDalicPINVOKE.SWIGPendingException.Pending)
2801                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2802         }
2803
2804         internal void RotateBy(Radian angle, Vector3 axis)
2805         {
2806             NDalicPINVOKE.Actor_RotateBy__SWIG_1(swigCPtr, Radian.getCPtr(angle), Vector3.getCPtr(axis));
2807             if (NDalicPINVOKE.SWIGPendingException.Pending)
2808                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2809         }
2810
2811         internal void RotateBy(Rotation relativeRotation)
2812         {
2813             NDalicPINVOKE.Actor_RotateBy__SWIG_2(swigCPtr, Rotation.getCPtr(relativeRotation));
2814             if (NDalicPINVOKE.SWIGPendingException.Pending)
2815                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2816         }
2817
2818         internal Rotation GetCurrentOrientation()
2819         {
2820             Rotation ret = new Rotation(NDalicPINVOKE.Actor_GetCurrentOrientation(swigCPtr), true);
2821             if (NDalicPINVOKE.SWIGPendingException.Pending)
2822                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2823             return ret;
2824         }
2825
2826         internal void SetInheritOrientation(bool inherit)
2827         {
2828             NDalicPINVOKE.Actor_SetInheritOrientation(swigCPtr, inherit);
2829             if (NDalicPINVOKE.SWIGPendingException.Pending)
2830                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2831         }
2832
2833         internal bool IsOrientationInherited()
2834         {
2835             bool ret = NDalicPINVOKE.Actor_IsOrientationInherited(swigCPtr);
2836             if (NDalicPINVOKE.SWIGPendingException.Pending)
2837                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2838             return ret;
2839         }
2840
2841         internal Rotation GetCurrentWorldOrientation()
2842         {
2843             Rotation ret = new Rotation(NDalicPINVOKE.Actor_GetCurrentWorldOrientation(swigCPtr), true);
2844             if (NDalicPINVOKE.SWIGPendingException.Pending)
2845                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2846             return ret;
2847         }
2848
2849         internal void SetScale(float scale)
2850         {
2851             NDalicPINVOKE.Actor_SetScale__SWIG_0(swigCPtr, scale);
2852             if (NDalicPINVOKE.SWIGPendingException.Pending)
2853                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2854         }
2855
2856         internal void SetScale(float scaleX, float scaleY, float scaleZ)
2857         {
2858             NDalicPINVOKE.Actor_SetScale__SWIG_1(swigCPtr, scaleX, scaleY, scaleZ);
2859             if (NDalicPINVOKE.SWIGPendingException.Pending)
2860                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2861         }
2862
2863         internal void SetScale(Vector3 scale)
2864         {
2865             NDalicPINVOKE.Actor_SetScale__SWIG_2(swigCPtr, Vector3.getCPtr(scale));
2866             if (NDalicPINVOKE.SWIGPendingException.Pending)
2867                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2868         }
2869
2870         internal void ScaleBy(Vector3 relativeScale)
2871         {
2872             NDalicPINVOKE.Actor_ScaleBy(swigCPtr, Vector3.getCPtr(relativeScale));
2873             if (NDalicPINVOKE.SWIGPendingException.Pending)
2874                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2875         }
2876
2877         internal Vector3 GetCurrentScale()
2878         {
2879             Vector3 ret = new Vector3(NDalicPINVOKE.Actor_GetCurrentScale(swigCPtr), true);
2880             if (NDalicPINVOKE.SWIGPendingException.Pending)
2881                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2882             return ret;
2883         }
2884
2885         internal Vector3 GetCurrentWorldScale()
2886         {
2887             Vector3 ret = new Vector3(NDalicPINVOKE.Actor_GetCurrentWorldScale(swigCPtr), true);
2888             if (NDalicPINVOKE.SWIGPendingException.Pending)
2889                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2890             return ret;
2891         }
2892
2893         internal void SetInheritScale(bool inherit)
2894         {
2895             NDalicPINVOKE.Actor_SetInheritScale(swigCPtr, inherit);
2896             if (NDalicPINVOKE.SWIGPendingException.Pending)
2897                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2898         }
2899
2900         internal bool IsScaleInherited()
2901         {
2902             bool ret = NDalicPINVOKE.Actor_IsScaleInherited(swigCPtr);
2903             if (NDalicPINVOKE.SWIGPendingException.Pending)
2904                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2905             return ret;
2906         }
2907
2908         internal Matrix GetCurrentWorldMatrix()
2909         {
2910             Matrix ret = new Matrix(NDalicPINVOKE.Actor_GetCurrentWorldMatrix(swigCPtr), true);
2911             if (NDalicPINVOKE.SWIGPendingException.Pending)
2912                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2913             return ret;
2914         }
2915
2916         internal void SetVisible(bool visible)
2917         {
2918             NDalicPINVOKE.Actor_SetVisible(swigCPtr, visible);
2919             if (NDalicPINVOKE.SWIGPendingException.Pending)
2920                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2921         }
2922
2923         internal bool IsVisible()
2924         {
2925             bool ret = NDalicPINVOKE.Actor_IsVisible(swigCPtr);
2926             if (NDalicPINVOKE.SWIGPendingException.Pending)
2927                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2928             return ret;
2929         }
2930
2931         internal void SetOpacity(float opacity)
2932         {
2933             NDalicPINVOKE.Actor_SetOpacity(swigCPtr, opacity);
2934             if (NDalicPINVOKE.SWIGPendingException.Pending)
2935                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2936         }
2937
2938         internal float GetCurrentOpacity()
2939         {
2940             float ret = NDalicPINVOKE.Actor_GetCurrentOpacity(swigCPtr);
2941             if (NDalicPINVOKE.SWIGPendingException.Pending)
2942                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2943             return ret;
2944         }
2945
2946         internal void SetColor(Vector4 color)
2947         {
2948             NDalicPINVOKE.Actor_SetColor(swigCPtr, Vector4.getCPtr(color));
2949             if (NDalicPINVOKE.SWIGPendingException.Pending)
2950                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2951         }
2952
2953         internal Vector4 GetCurrentColor()
2954         {
2955             Vector4 ret = new Vector4(NDalicPINVOKE.Actor_GetCurrentColor(swigCPtr), true);
2956             if (NDalicPINVOKE.SWIGPendingException.Pending)
2957                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2958             return ret;
2959         }
2960
2961         internal void SetColorMode(ColorMode colorMode)
2962         {
2963             NDalicPINVOKE.Actor_SetColorMode(swigCPtr, (int)colorMode);
2964             if (NDalicPINVOKE.SWIGPendingException.Pending)
2965                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2966         }
2967
2968         internal ColorMode GetColorMode()
2969         {
2970             ColorMode ret = (ColorMode)NDalicPINVOKE.Actor_GetColorMode(swigCPtr);
2971             if (NDalicPINVOKE.SWIGPendingException.Pending)
2972                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2973             return ret;
2974         }
2975
2976         internal Vector4 GetCurrentWorldColor()
2977         {
2978             Vector4 ret = new Vector4(NDalicPINVOKE.Actor_GetCurrentWorldColor(swigCPtr), true);
2979             if (NDalicPINVOKE.SWIGPendingException.Pending)
2980                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2981             return ret;
2982         }
2983
2984         internal void SetDrawMode(DrawModeType drawMode)
2985         {
2986             NDalicPINVOKE.Actor_SetDrawMode(swigCPtr, (int)drawMode);
2987             if (NDalicPINVOKE.SWIGPendingException.Pending)
2988                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2989         }
2990
2991         internal DrawModeType GetDrawMode()
2992         {
2993             DrawModeType ret = (DrawModeType)NDalicPINVOKE.Actor_GetDrawMode(swigCPtr);
2994             if (NDalicPINVOKE.SWIGPendingException.Pending)
2995                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2996             return ret;
2997         }
2998
2999         /// <summary>
3000         /// Converts screen coordinates into the view's coordinate system using the default camera.
3001         /// </summary>
3002         /// <pre>The view has been initialized.</pre>
3003         /// <remarks>The view coordinates are relative to the top-left(0.0, 0.0, 0.5).</remarks>
3004         /// <param name="localX">On return, the X-coordinate relative to the view.</param>
3005         /// <param name="localY">On return, the Y-coordinate relative to the view.</param>
3006         /// <param name="screenX">The screen X-coordinate.</param>
3007         /// <param name="screenY">The screen Y-coordinate.</param>
3008         /// <returns>True if the conversion succeeded.</returns>
3009         /// <since_tizen> 3 </since_tizen>
3010         public bool ScreenToLocal(out float localX, out float localY, float screenX, float screenY)
3011         {
3012             bool ret = NDalicPINVOKE.Actor_ScreenToLocal(swigCPtr, out localX, out localY, screenX, screenY);
3013             if (NDalicPINVOKE.SWIGPendingException.Pending)
3014                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3015             return ret;
3016         }
3017
3018         internal void SetKeyboardFocusable(bool focusable)
3019         {
3020             NDalicPINVOKE.Actor_SetKeyboardFocusable(swigCPtr, focusable);
3021             if (NDalicPINVOKE.SWIGPendingException.Pending)
3022                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3023         }
3024
3025         internal bool IsKeyboardFocusable()
3026         {
3027             bool ret = NDalicPINVOKE.Actor_IsKeyboardFocusable(swigCPtr);
3028             if (NDalicPINVOKE.SWIGPendingException.Pending)
3029                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3030             return ret;
3031         }
3032
3033         internal void SetResizePolicy(ResizePolicyType policy, DimensionType dimension)
3034         {
3035             NDalicPINVOKE.Actor_SetResizePolicy(swigCPtr, (int)policy, (int)dimension);
3036             if (NDalicPINVOKE.SWIGPendingException.Pending)
3037                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3038         }
3039
3040         internal ResizePolicyType GetResizePolicy(DimensionType dimension)
3041         {
3042             ResizePolicyType ret = (ResizePolicyType)NDalicPINVOKE.Actor_GetResizePolicy(swigCPtr, (int)dimension);
3043             if (NDalicPINVOKE.SWIGPendingException.Pending)
3044                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3045             return ret;
3046         }
3047
3048         /// <summary>
3049         /// Sets the relative to parent size factor of the view.<br />
3050         /// This factor is only used when ResizePolicy is set to either:
3051         /// ResizePolicy::SIZE_RELATIVE_TO_PARENT or ResizePolicy::SIZE_FIXED_OFFSET_FROM_PARENT.<br />
3052         /// This view's size is set to the view's size multiplied by or added to this factor, depending on ResizePolicy.<br />
3053         /// </summary>
3054         /// <pre>The view has been initialized.</pre>
3055         /// <param name="factor">A Vector3 representing the relative factor to be applied to each axis.</param>
3056         /// <since_tizen> 3 </since_tizen>
3057         public void SetSizeModeFactor(Vector3 factor)
3058         {
3059             NDalicPINVOKE.Actor_SetSizeModeFactor(swigCPtr, Vector3.getCPtr(factor));
3060             if (NDalicPINVOKE.SWIGPendingException.Pending)
3061                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3062         }
3063
3064         internal Vector3 GetSizeModeFactor()
3065         {
3066             Vector3 ret = new Vector3(NDalicPINVOKE.Actor_GetSizeModeFactor(swigCPtr), true);
3067             if (NDalicPINVOKE.SWIGPendingException.Pending)
3068                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3069             return ret;
3070         }
3071
3072         /// <summary>
3073         /// Calculates the height of the view given a width.<br />
3074         /// The natural size is used for default calculation.<br />
3075         /// Size 0 is treated as aspect ratio 1:1.<br />
3076         /// </summary>
3077         /// <param name="width">The width to use.</param>
3078         /// <returns>The height based on the width.</returns>
3079         /// <since_tizen> 3 </since_tizen>
3080         public float GetHeightForWidth(float width)
3081         {
3082             float ret = NDalicPINVOKE.Actor_GetHeightForWidth(swigCPtr, width);
3083             if (NDalicPINVOKE.SWIGPendingException.Pending)
3084                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3085             return ret;
3086         }
3087
3088         /// <summary>
3089         /// Calculates the width of the view given a height.<br />
3090         /// The natural size is used for default calculation.<br />
3091         /// Size 0 is treated as aspect ratio 1:1.<br />
3092         /// </summary>
3093         /// <param name="height">The height to use.</param>
3094         /// <returns>The width based on the height.</returns>
3095         /// <since_tizen> 3 </since_tizen>
3096         public float GetWidthForHeight(float height)
3097         {
3098             float ret = NDalicPINVOKE.Actor_GetWidthForHeight(swigCPtr, height);
3099             if (NDalicPINVOKE.SWIGPendingException.Pending)
3100                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3101             return ret;
3102         }
3103
3104         /// <summary>
3105         /// Return the amount of size allocated for relayout.
3106         /// </summary>
3107         /// <param name="dimension">The dimension to retrieve.</param>
3108         /// <returns>Return the size.</returns>
3109         /// <since_tizen> 3 </since_tizen>
3110         public float GetRelayoutSize(DimensionType dimension)
3111         {
3112             float ret = NDalicPINVOKE.Actor_GetRelayoutSize(swigCPtr, (int)dimension);
3113             if (NDalicPINVOKE.SWIGPendingException.Pending)
3114                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3115             return ret;
3116         }
3117
3118         /// <summary>
3119         /// Set the padding for the view.
3120         /// </summary>
3121         /// <param name="padding">Padding for the view.</param>
3122         /// <since_tizen> 3 </since_tizen>
3123         public void SetPadding(PaddingType padding)
3124         {
3125             NDalicPINVOKE.Actor_SetPadding(swigCPtr, PaddingType.getCPtr(padding));
3126             if (NDalicPINVOKE.SWIGPendingException.Pending)
3127                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3128         }
3129
3130         /// <summary>
3131         /// Return the value of padding for the view.
3132         /// </summary>
3133         /// <param name="paddingOut">the value of padding for the view</param>
3134         /// <since_tizen> 3 </since_tizen>
3135         public void GetPadding(PaddingType paddingOut)
3136         {
3137             NDalicPINVOKE.Actor_GetPadding(swigCPtr, PaddingType.getCPtr(paddingOut));
3138             if (NDalicPINVOKE.SWIGPendingException.Pending)
3139                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3140         }
3141
3142         internal void SetMinimumSize(Vector2 size)
3143         {
3144             NDalicPINVOKE.Actor_SetMinimumSize(swigCPtr, Vector2.getCPtr(size));
3145             if (NDalicPINVOKE.SWIGPendingException.Pending)
3146                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3147         }
3148
3149         internal Vector2 GetMinimumSize()
3150         {
3151             Vector2 ret = new Vector2(NDalicPINVOKE.Actor_GetMinimumSize(swigCPtr), true);
3152             if (NDalicPINVOKE.SWIGPendingException.Pending)
3153                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3154             return ret;
3155         }
3156
3157         internal void SetMaximumSize(Vector2 size)
3158         {
3159             NDalicPINVOKE.Actor_SetMaximumSize(swigCPtr, Vector2.getCPtr(size));
3160             if (NDalicPINVOKE.SWIGPendingException.Pending)
3161                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3162         }
3163
3164         internal Vector2 GetMaximumSize()
3165         {
3166             Vector2 ret = new Vector2(NDalicPINVOKE.Actor_GetMaximumSize(swigCPtr), true);
3167             if (NDalicPINVOKE.SWIGPendingException.Pending)
3168                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3169             return ret;
3170         }
3171
3172         internal int GetHierarchyDepth()
3173         {
3174             int ret = NDalicPINVOKE.Actor_GetHierarchyDepth(swigCPtr);
3175             if (NDalicPINVOKE.SWIGPendingException.Pending)
3176                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3177             return ret;
3178         }
3179
3180         /// <since_tizen> 3 </since_tizen>
3181         public uint AddRenderer(Renderer renderer)
3182         {
3183             uint ret = NDalicPINVOKE.Actor_AddRenderer(swigCPtr, Renderer.getCPtr(renderer));
3184             if (NDalicPINVOKE.SWIGPendingException.Pending)
3185                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3186             return ret;
3187         }
3188
3189         internal uint GetRendererCount()
3190         {
3191             uint ret = NDalicPINVOKE.Actor_GetRendererCount(swigCPtr);
3192             if (NDalicPINVOKE.SWIGPendingException.Pending)
3193                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3194             return ret;
3195         }
3196
3197         /// <since_tizen> 3 </since_tizen>
3198         public Renderer GetRendererAt(uint index)
3199         {
3200             IntPtr cPtr = NDalicPINVOKE.Actor_GetRendererAt(swigCPtr, index);
3201             Renderer ret = Registry.GetManagedBaseHandleFromNativePtr(cPtr) as Renderer;
3202
3203             if (NDalicPINVOKE.SWIGPendingException.Pending)
3204                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3205             return ret;
3206         }
3207
3208         /// <since_tizen> 3 </since_tizen>
3209         public void RemoveRenderer(Renderer renderer)
3210         {
3211             NDalicPINVOKE.Actor_RemoveRenderer__SWIG_0(swigCPtr, Renderer.getCPtr(renderer));
3212             if (NDalicPINVOKE.SWIGPendingException.Pending)
3213                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3214         }
3215
3216         /// <since_tizen> 3 </since_tizen>
3217         public void RemoveRenderer(uint index)
3218         {
3219             NDalicPINVOKE.Actor_RemoveRenderer__SWIG_1(swigCPtr, index);
3220             if (NDalicPINVOKE.SWIGPendingException.Pending)
3221                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3222         }
3223
3224         internal TouchDataSignal TouchSignal()
3225         {
3226             TouchDataSignal ret = new TouchDataSignal(NDalicPINVOKE.Actor_TouchSignal(swigCPtr), false);
3227             if (NDalicPINVOKE.SWIGPendingException.Pending)
3228                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3229             return ret;
3230         }
3231
3232         internal HoverSignal HoveredSignal()
3233         {
3234             HoverSignal ret = new HoverSignal(NDalicPINVOKE.Actor_HoveredSignal(swigCPtr), false);
3235             if (NDalicPINVOKE.SWIGPendingException.Pending)
3236                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3237             return ret;
3238         }
3239
3240         internal WheelSignal WheelEventSignal()
3241         {
3242             WheelSignal ret = new WheelSignal(NDalicPINVOKE.Actor_WheelEventSignal(swigCPtr), false);
3243             if (NDalicPINVOKE.SWIGPendingException.Pending)
3244                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3245             return ret;
3246         }
3247
3248         internal ViewSignal OnWindowSignal()
3249         {
3250             ViewSignal ret = new ViewSignal(NDalicPINVOKE.Actor_OnStageSignal(swigCPtr), false);
3251             if (NDalicPINVOKE.SWIGPendingException.Pending)
3252                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3253             return ret;
3254         }
3255
3256         internal ViewSignal OffWindowSignal()
3257         {
3258             ViewSignal ret = new ViewSignal(NDalicPINVOKE.Actor_OffStageSignal(swigCPtr), false);
3259             if (NDalicPINVOKE.SWIGPendingException.Pending)
3260                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3261             return ret;
3262         }
3263
3264         internal ViewSignal OnRelayoutSignal()
3265         {
3266             ViewSignal ret = new ViewSignal(NDalicPINVOKE.Actor_OnRelayoutSignal(swigCPtr), false);
3267             if (NDalicPINVOKE.SWIGPendingException.Pending)
3268                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3269             return ret;
3270         }
3271
3272         internal ViewVisibilityChangedSignal VisibilityChangedSignal(View view) {
3273             ViewVisibilityChangedSignal ret = new ViewVisibilityChangedSignal(NDalicPINVOKE.VisibilityChangedSignal(View.getCPtr(view)), false);
3274             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3275             return ret;
3276         }
3277
3278
3279         internal ViewLayoutDirectionChangedSignal LayoutDirectionChangedSignal(View view) {
3280             ViewLayoutDirectionChangedSignal ret = new ViewLayoutDirectionChangedSignal(NDalicManualPINVOKE.LayoutDirectionChangedSignal(View.getCPtr(view)), false);
3281             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3282             return ret;
3283         }
3284
3285
3286         internal ViewSignal ResourcesLoadedSignal()
3287         {
3288             ViewSignal ret = new ViewSignal(NDalicPINVOKE.ResourceReadySignal(swigCPtr), false);
3289             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3290             return ret;
3291         }
3292
3293         /// <summary>
3294         /// Gets or sets the origin of a view within its parent's area.<br />
3295         /// This is expressed in unit coordinates, such that (0.0, 0.0, 0.5) is the top-left corner of the parent, and (1.0, 1.0, 0.5) is the bottom-right corner.<br />
3296         /// The default parent-origin is ParentOrigin.TopLeft (0.0, 0.0, 0.5).<br />
3297         /// A view's position is the distance between this origin and the view's anchor-point.<br />
3298         /// </summary>
3299         /// <pre>The view has been initialized.</pre>
3300         /// <since_tizen> 3 </since_tizen>
3301         public Position ParentOrigin
3302         {
3303             get
3304             {
3305                 Position temp = new Position(0.0f, 0.0f, 0.0f);
3306                 GetProperty(View.Property.PARENT_ORIGIN).Get(temp);
3307                 return temp;
3308             }
3309             set
3310             {
3311                 SetProperty(View.Property.PARENT_ORIGIN, new Tizen.NUI.PropertyValue(value));
3312             }
3313         }
3314
3315         internal float ParentOriginX
3316         {
3317             get
3318             {
3319                 float temp = 0.0f;
3320                 GetProperty(View.Property.PARENT_ORIGIN_X).Get(out temp);
3321                 return temp;
3322             }
3323             set
3324             {
3325                 SetProperty(View.Property.PARENT_ORIGIN_X, new Tizen.NUI.PropertyValue(value));
3326             }
3327         }
3328
3329         internal float ParentOriginY
3330         {
3331             get
3332             {
3333                 float temp = 0.0f;
3334                 GetProperty(View.Property.PARENT_ORIGIN_Y).Get(out temp);
3335                 return temp;
3336             }
3337             set
3338             {
3339                 SetProperty(View.Property.PARENT_ORIGIN_Y, new Tizen.NUI.PropertyValue(value));
3340             }
3341         }
3342
3343         internal float ParentOriginZ
3344         {
3345             get
3346             {
3347                 float temp = 0.0f;
3348                 GetProperty(View.Property.PARENT_ORIGIN_Z).Get(out temp);
3349                 return temp;
3350             }
3351             set
3352             {
3353                 SetProperty(View.Property.PARENT_ORIGIN_Z, new Tizen.NUI.PropertyValue(value));
3354             }
3355         }
3356
3357         /// <summary>
3358         /// Gets or sets the anchor-point of a view.<br />
3359         /// This is expressed in unit coordinates, such that (0.0, 0.0, 0.5) is the top-left corner of the view, and (1.0, 1.0, 0.5) is the bottom-right corner.<br />
3360         /// The default pivot point is PivotPoint.Center (0.5, 0.5, 0.5).<br />
3361         /// A view position is the distance between its parent-origin and this anchor-point.<br />
3362         /// A view's orientation is the rotation from its default orientation, the rotation is centered around its anchor-point.<br />
3363         /// <pre>The view has been initialized.</pre>
3364         /// </summary>
3365         /// <since_tizen> 3 </since_tizen>
3366         public Position PivotPoint
3367         {
3368             get
3369             {
3370                 Position temp = new Position(0.0f, 0.0f, 0.0f);
3371                 GetProperty(View.Property.ANCHOR_POINT).Get(temp);
3372                 return temp;
3373             }
3374             set
3375             {
3376                 SetProperty(View.Property.ANCHOR_POINT, new Tizen.NUI.PropertyValue(value));
3377             }
3378         }
3379
3380         internal float PivotPointX
3381         {
3382             get
3383             {
3384                 float temp = 0.0f;
3385                 GetProperty(View.Property.ANCHOR_POINT_X).Get(out temp);
3386                 return temp;
3387             }
3388             set
3389             {
3390                 SetProperty(View.Property.ANCHOR_POINT_X, new Tizen.NUI.PropertyValue(value));
3391             }
3392         }
3393
3394         internal float PivotPointY
3395         {
3396             get
3397             {
3398                 float temp = 0.0f;
3399                 GetProperty(View.Property.ANCHOR_POINT_Y).Get(out temp);
3400                 return temp;
3401             }
3402             set
3403             {
3404                 SetProperty(View.Property.ANCHOR_POINT_Y, new Tizen.NUI.PropertyValue(value));
3405             }
3406         }
3407
3408         internal float PivotPointZ
3409         {
3410             get
3411             {
3412                 float temp = 0.0f;
3413                 GetProperty(View.Property.ANCHOR_POINT_Z).Get(out temp);
3414                 return temp;
3415             }
3416             set
3417             {
3418                 SetProperty(View.Property.ANCHOR_POINT_Z, new Tizen.NUI.PropertyValue(value));
3419             }
3420         }
3421
3422         /// <summary>
3423         /// Gets or sets the size width of the view.
3424         /// </summary>
3425         /// <since_tizen> 3 </since_tizen>
3426         public float SizeWidth
3427         {
3428             get
3429             {
3430                 float temp = 0.0f;
3431                 GetProperty(View.Property.SIZE_WIDTH).Get(out temp);
3432                 return temp;
3433             }
3434             set
3435             {
3436                 SetProperty(View.Property.SIZE_WIDTH, new Tizen.NUI.PropertyValue(value));
3437             }
3438         }
3439
3440         /// <summary>
3441         /// Gets or sets the size height of the view.
3442         /// </summary>
3443         /// <since_tizen> 3 </since_tizen>
3444         public float SizeHeight
3445         {
3446             get
3447             {
3448                 float temp = 0.0f;
3449                 GetProperty(View.Property.SIZE_HEIGHT).Get(out temp);
3450                 return temp;
3451             }
3452             set
3453             {
3454                 SetProperty(View.Property.SIZE_HEIGHT, new Tizen.NUI.PropertyValue(value));
3455             }
3456         }
3457
3458         /// <summary>
3459         /// Gets or sets the position of the view.<br />
3460         /// By default, sets the position vector between the parent origin and pivot point (default).<br />
3461         /// If the position inheritance is disabled, sets the world position.<br />
3462         /// </summary>
3463         /// <since_tizen> 3 </since_tizen>
3464         public Position Position
3465         {
3466             get
3467             {
3468                 Vector3 temp = new Vector3(0.0f, 0.0f, 0.0f);
3469                 GetProperty(View.Property.POSITION).Get(temp);
3470                 return temp;
3471             }
3472             set
3473             {
3474                 SetProperty(View.Property.POSITION, new Tizen.NUI.PropertyValue(value));
3475             }
3476         }
3477
3478         /// <summary>
3479         /// Gets or sets the position X of the view.
3480         /// </summary>
3481         /// <since_tizen> 3 </since_tizen>
3482         public float PositionX
3483         {
3484             get
3485             {
3486                 float temp = 0.0f;
3487                 GetProperty(View.Property.POSITION_X).Get(out temp);
3488                 return temp;
3489             }
3490             set
3491             {
3492                 SetProperty(View.Property.POSITION_X, new Tizen.NUI.PropertyValue(value));
3493             }
3494         }
3495
3496         /// <summary>
3497         /// Gets or sets the position Y of the view.
3498         /// </summary>
3499         /// <since_tizen> 3 </since_tizen>
3500         public float PositionY
3501         {
3502             get
3503             {
3504                 float temp = 0.0f;
3505                 GetProperty(View.Property.POSITION_Y).Get(out temp);
3506                 return temp;
3507             }
3508             set
3509             {
3510                 SetProperty(View.Property.POSITION_Y, new Tizen.NUI.PropertyValue(value));
3511             }
3512         }
3513
3514         /// <summary>
3515         /// Gets or sets the position Z of the view.
3516         /// </summary>
3517         /// <since_tizen> 3 </since_tizen>
3518         public float PositionZ
3519         {
3520             get
3521             {
3522                 float temp = 0.0f;
3523                 GetProperty(View.Property.POSITION_Z).Get(out temp);
3524                 return temp;
3525             }
3526             set
3527             {
3528                 SetProperty(View.Property.POSITION_Z, new Tizen.NUI.PropertyValue(value));
3529             }
3530         }
3531
3532         /// <summary>
3533         /// Gets or sets the world position of the view.
3534         /// </summary>
3535         /// <since_tizen> 3 </since_tizen>
3536         public Vector3 WorldPosition
3537         {
3538             get
3539             {
3540                 Vector3 temp = new Vector3(0.0f, 0.0f, 0.0f);
3541                 GetProperty(View.Property.WORLD_POSITION).Get(temp);
3542                 return temp;
3543             }
3544         }
3545
3546         internal float WorldPositionX
3547         {
3548             get
3549             {
3550                 float temp = 0.0f;
3551                 GetProperty(View.Property.WORLD_POSITION_X).Get(out temp);
3552                 return temp;
3553             }
3554         }
3555
3556         internal float WorldPositionY
3557         {
3558             get
3559             {
3560                 float temp = 0.0f;
3561                 GetProperty(View.Property.WORLD_POSITION_Y).Get(out temp);
3562                 return temp;
3563             }
3564         }
3565
3566         internal float WorldPositionZ
3567         {
3568             get
3569             {
3570                 float temp = 0.0f;
3571                 GetProperty(View.Property.WORLD_POSITION_Z).Get(out temp);
3572                 return temp;
3573             }
3574         }
3575
3576         /// <summary>
3577         /// Gets or sets the orientation of the view.<br />
3578         /// The view's orientation is the rotation from its default orientation, and the rotation is centered around its anchor-point.<br />
3579         /// </summary>
3580         /// <remarks>This is an asynchronous method.</remarks>
3581         /// <since_tizen> 3 </since_tizen>
3582         public Rotation Orientation
3583         {
3584             get
3585             {
3586                 Rotation temp = new Rotation();
3587                 GetProperty(View.Property.ORIENTATION).Get(temp);
3588                 return temp;
3589             }
3590             set
3591             {
3592                 SetProperty(View.Property.ORIENTATION, new Tizen.NUI.PropertyValue(value));
3593             }
3594         }
3595
3596         /// <summary>
3597         /// Gets or sets the world orientation of the view.<br />
3598         /// </summary>
3599         /// <since_tizen> 3 </since_tizen>
3600         public Rotation WorldOrientation
3601         {
3602             get
3603             {
3604                 Rotation temp = new Rotation();
3605                 GetProperty(View.Property.WORLD_ORIENTATION).Get(temp);
3606                 return temp;
3607             }
3608         }
3609
3610         /// <summary>
3611         /// Gets or sets the scale factor applied to the view.<br />
3612         /// </summary>
3613         /// <since_tizen> 3 </since_tizen>
3614         public Vector3 Scale
3615         {
3616             get
3617             {
3618                 Vector3 temp = new Vector3(0.0f, 0.0f, 0.0f);
3619                 GetProperty(View.Property.SCALE).Get(temp);
3620                 return temp;
3621             }
3622             set
3623             {
3624                 SetProperty(View.Property.SCALE, new Tizen.NUI.PropertyValue(value));
3625             }
3626         }
3627
3628         /// <summary>
3629         /// Gets or sets the scale X factor applied to the view.
3630         /// </summary>
3631         /// <since_tizen> 3 </since_tizen>
3632         public float ScaleX
3633         {
3634             get
3635             {
3636                 float temp = 0.0f;
3637                 GetProperty(View.Property.SCALE_X).Get(out temp);
3638                 return temp;
3639             }
3640             set
3641             {
3642                 SetProperty(View.Property.SCALE_X, new Tizen.NUI.PropertyValue(value));
3643             }
3644         }
3645
3646         /// <summary>
3647         /// Gets or sets the scale Y factor applied to the view.
3648         /// </summary>
3649         /// <since_tizen> 3 </since_tizen>
3650         public float ScaleY
3651         {
3652             get
3653             {
3654                 float temp = 0.0f;
3655                 GetProperty(View.Property.SCALE_Y).Get(out temp);
3656                 return temp;
3657             }
3658             set
3659             {
3660                 SetProperty(View.Property.SCALE_Y, new Tizen.NUI.PropertyValue(value));
3661             }
3662         }
3663
3664         /// <summary>
3665         /// Gets or sets the scale Z factor applied to the view.
3666         /// </summary>
3667         /// <since_tizen> 3 </since_tizen>
3668         public float ScaleZ
3669         {
3670             get
3671             {
3672                 float temp = 0.0f;
3673                 GetProperty(View.Property.SCALE_Z).Get(out temp);
3674                 return temp;
3675             }
3676             set
3677             {
3678                 SetProperty(View.Property.SCALE_Z, new Tizen.NUI.PropertyValue(value));
3679             }
3680         }
3681
3682         /// <summary>
3683         /// Gets the world scale of the view.
3684         /// </summary>
3685         /// <since_tizen> 3 </since_tizen>
3686         public Vector3 WorldScale
3687         {
3688             get
3689             {
3690                 Vector3 temp = new Vector3(0.0f, 0.0f, 0.0f);
3691                 GetProperty(View.Property.WORLD_SCALE).Get(temp);
3692                 return temp;
3693             }
3694         }
3695
3696         /// <summary>
3697         /// Retrieves the visibility flag of the view.
3698         /// </summary>
3699         /// <remarks>
3700         /// If the view is not visible, then the view and its children will not be rendered.
3701         /// This is regardless of the individual visibility values of the children, i.e., the view will only be rendered if all of its parents have visibility set to true.
3702         /// </remarks>
3703         /// <since_tizen> 3 </since_tizen>
3704         public bool Visibility
3705         {
3706             get
3707             {
3708                 bool temp = false;
3709                 GetProperty(View.Property.VISIBLE).Get(out temp);
3710                 return temp;
3711             }
3712         }
3713
3714         /// <summary>
3715         /// Gets the view's world color.
3716         /// </summary>
3717         /// <since_tizen> 3 </since_tizen>
3718         public Vector4 WorldColor
3719         {
3720             get
3721             {
3722                 Vector4 temp = new Vector4(0.0f, 0.0f, 0.0f, 0.0f);
3723                 GetProperty(View.Property.WORLD_COLOR).Get(temp);
3724                 return temp;
3725             }
3726         }
3727
3728         internal Matrix WorldMatrix
3729         {
3730             get
3731             {
3732                 Matrix temp = new Matrix();
3733                 GetProperty(View.Property.WORLD_MATRIX).Get(temp);
3734                 return temp;
3735             }
3736         }
3737
3738         /// <summary>
3739         /// Gets or sets the view's name.
3740         /// </summary>
3741         /// <since_tizen> 3 </since_tizen>
3742         public string Name
3743         {
3744             get
3745             {
3746                 string temp;
3747                 GetProperty(View.Property.NAME).Get(out temp);
3748                 return temp;
3749             }
3750             set
3751             {
3752                 SetProperty(View.Property.NAME, new Tizen.NUI.PropertyValue(value));
3753             }
3754         }
3755
3756         /// <summary>
3757         /// Get the number of children held by the view.
3758         /// </summary>
3759         /// <since_tizen> 3 </since_tizen>
3760         public new uint ChildCount
3761         {
3762             get
3763             {
3764                 return GetChildCount();
3765             }
3766         }
3767
3768         /// <summary>
3769         /// Gets the view's ID.
3770         /// Readonly
3771         /// </summary>
3772         /// <since_tizen> 3 </since_tizen>
3773         public uint ID
3774         {
3775             get
3776             {
3777                 return GetId();
3778             }
3779         }
3780
3781         /// <summary>
3782         /// Gets or sets the status of whether the view should emit touch or hover signals.
3783         /// </summary>
3784         /// <since_tizen> 3 </since_tizen>
3785         public bool Sensitive
3786         {
3787             get
3788             {
3789                 bool temp = false;
3790                 GetProperty(View.Property.SENSITIVE).Get(out temp);
3791                 return temp;
3792             }
3793             set
3794             {
3795                 SetProperty(View.Property.SENSITIVE, new Tizen.NUI.PropertyValue(value));
3796             }
3797         }
3798
3799         /// <summary>
3800         /// Gets or sets the status of whether the view should receive a notification when touch or hover motion events leave the boundary of the view.
3801         /// </summary>
3802         /// <since_tizen> 3 </since_tizen>
3803         public bool LeaveRequired
3804         {
3805             get
3806             {
3807                 bool temp = false;
3808                 GetProperty(View.Property.LEAVE_REQUIRED).Get(out temp);
3809                 return temp;
3810             }
3811             set
3812             {
3813                 SetProperty(View.Property.LEAVE_REQUIRED, new Tizen.NUI.PropertyValue(value));
3814             }
3815         }
3816
3817         /// <summary>
3818         /// Gets or sets the status of whether a child view inherits it's parent's orientation.
3819         /// </summary>
3820         /// <since_tizen> 3 </since_tizen>
3821         public bool InheritOrientation
3822         {
3823             get
3824             {
3825                 bool temp = false;
3826                 GetProperty(View.Property.INHERIT_ORIENTATION).Get(out temp);
3827                 return temp;
3828             }
3829             set
3830             {
3831                 SetProperty(View.Property.INHERIT_ORIENTATION, new Tizen.NUI.PropertyValue(value));
3832             }
3833         }
3834
3835         /// <summary>
3836         /// Gets or sets the status of whether a child view inherits it's parent's scale.
3837         /// </summary>
3838         /// <since_tizen> 3 </since_tizen>
3839         public bool InheritScale
3840         {
3841             get
3842             {
3843                 bool temp = false;
3844                 GetProperty(View.Property.INHERIT_SCALE).Get(out temp);
3845                 return temp;
3846             }
3847             set
3848             {
3849                 SetProperty(View.Property.INHERIT_SCALE, new Tizen.NUI.PropertyValue(value));
3850             }
3851         }
3852
3853         /// <summary>
3854         /// Gets or sets the status of how the view and its children should be drawn.<br />
3855         /// Not all views are renderable, but DrawMode can be inherited from any view.<br />
3856         /// If an object is in a 3D layer, it will be depth-tested against other objects in the world, i.e., it may be obscured if other objects are in front.<br />
3857         /// If DrawMode.Overlay2D is used, the view and its children will be drawn as a 2D overlay.<br />
3858         /// Overlay views are drawn in a separate pass, after all non-overlay views within the layer.<br />
3859         /// For overlay views, the drawing order is with respect to tree levels of views, and depth-testing will not be used.<br />
3860         /// </summary>
3861         /// <since_tizen> 3 </since_tizen>
3862         public DrawModeType DrawMode
3863         {
3864             get
3865             {
3866                 string temp;
3867                 if (GetProperty(View.Property.DRAW_MODE).Get(out temp) == false)
3868                 {
3869                     NUILog.Error("DrawMode get error!");
3870                 }
3871                 switch (temp)
3872                 {
3873                     case "NORMAL":
3874                     return DrawModeType.Normal;
3875                     case "OVERLAY_2D":
3876                     return DrawModeType.Overlay2D;
3877                     case "STENCIL":
3878                     return DrawModeType.Stencil;
3879                     default:
3880                     return DrawModeType.Normal;
3881                 }
3882             }
3883             set
3884             {
3885                 SetProperty(View.Property.DRAW_MODE, new Tizen.NUI.PropertyValue((int)value));
3886             }
3887         }
3888
3889         /// <summary>
3890         /// Gets or sets the relative to parent size factor of the view.<br />
3891         /// This factor is only used when ResizePolicyType is set to either: ResizePolicyType.SizeRelativeToParent or ResizePolicyType.SizeFixedOffsetFromParent.<br />
3892         /// This view's size is set to the view's size multiplied by or added to this factor, depending on ResizePolicyType.<br />
3893         /// </summary>
3894         /// <since_tizen> 3 </since_tizen>
3895         public Vector3 SizeModeFactor
3896         {
3897             get
3898             {
3899                 Vector3 temp = new Vector3(0.0f, 0.0f, 0.0f);
3900                 GetProperty(View.Property.SIZE_MODE_FACTOR).Get(temp);
3901                 return temp;
3902             }
3903             set
3904             {
3905                 SetProperty(View.Property.SIZE_MODE_FACTOR, new Tizen.NUI.PropertyValue(value));
3906             }
3907         }
3908
3909         /// <summary>
3910         /// Gets or sets the width resize policy to be used.
3911         /// </summary>
3912         /// <since_tizen> 3 </since_tizen>
3913         public ResizePolicyType WidthResizePolicy
3914         {
3915             get
3916             {
3917                 string temp;
3918                 if (GetProperty(View.Property.WIDTH_RESIZE_POLICY).Get(out temp) == false)
3919                 {
3920                     NUILog.Error("WidthResizePolicy get error!");
3921                 }
3922                 switch (temp)
3923                 {
3924                     case "FIXED":
3925                         return ResizePolicyType.Fixed;
3926                     case "USE_NATURAL_SIZE":
3927                         return ResizePolicyType.UseNaturalSize;
3928                     case "FILL_TO_PARENT":
3929                         return ResizePolicyType.FillToParent;
3930                     case "SIZE_RELATIVE_TO_PARENT":
3931                         return ResizePolicyType.SizeRelativeToParent;
3932                     case "SIZE_FIXED_OFFSET_FROM_PARENT":
3933                         return ResizePolicyType.SizeFixedOffsetFromParent;
3934                     case "FIT_TO_CHILDREN":
3935                         return ResizePolicyType.FitToChildren;
3936                     case "DIMENSION_DEPENDENCY":
3937                         return ResizePolicyType.DimensionDependency;
3938                     case "USE_ASSIGNED_SIZE":
3939                         return ResizePolicyType.UseAssignedSize;
3940                     default:
3941                         return ResizePolicyType.Fixed;
3942                 }
3943             }
3944             set
3945             {
3946                 SetProperty(View.Property.WIDTH_RESIZE_POLICY, new Tizen.NUI.PropertyValue((int)value));
3947             }
3948         }
3949
3950         /// <summary>
3951         /// Gets or sets the height resize policy to be used.
3952         /// </summary>
3953         /// <since_tizen> 3 </since_tizen>
3954         public ResizePolicyType HeightResizePolicy
3955         {
3956             get
3957             {
3958                 string temp;
3959                 if (GetProperty(View.Property.HEIGHT_RESIZE_POLICY).Get(out temp) == false)
3960                 {
3961                     NUILog.Error("HeightResizePolicy get error!");
3962                 }
3963                 switch (temp)
3964                 {
3965                     case "FIXED":
3966                         return ResizePolicyType.Fixed;
3967                     case "USE_NATURAL_SIZE":
3968                         return ResizePolicyType.UseNaturalSize;
3969                     case "FILL_TO_PARENT":
3970                         return ResizePolicyType.FillToParent;
3971                     case "SIZE_RELATIVE_TO_PARENT":
3972                         return ResizePolicyType.SizeRelativeToParent;
3973                     case "SIZE_FIXED_OFFSET_FROM_PARENT":
3974                         return ResizePolicyType.SizeFixedOffsetFromParent;
3975                     case "FIT_TO_CHILDREN":
3976                         return ResizePolicyType.FitToChildren;
3977                     case "DIMENSION_DEPENDENCY":
3978                         return ResizePolicyType.DimensionDependency;
3979                     case "USE_ASSIGNED_SIZE":
3980                         return ResizePolicyType.UseAssignedSize;
3981                     default:
3982                         return ResizePolicyType.Fixed;
3983                 }
3984             }
3985             set
3986             {
3987                 SetProperty(View.Property.HEIGHT_RESIZE_POLICY, new Tizen.NUI.PropertyValue((int)value));
3988             }
3989         }
3990
3991         /// <summary>
3992         /// Gets or sets the policy to use when setting size with size negotiation.<br />
3993         /// Defaults to SizeScalePolicyType.UseSizeSet.<br />
3994         /// </summary>
3995         /// <since_tizen> 3 </since_tizen>
3996         public SizeScalePolicyType SizeScalePolicy
3997         {
3998             get
3999             {
4000                 string temp;
4001                 if (GetProperty(View.Property.SIZE_SCALE_POLICY).Get(out temp) == false)
4002                 {
4003                     NUILog.Error("SizeScalePolicy get error!");
4004                 }
4005                 switch (temp)
4006                 {
4007                     case "USE_SIZE_SET":
4008                         return SizeScalePolicyType.UseSizeSet;
4009                     case "FIT_WITH_ASPECT_RATIO":
4010                         return SizeScalePolicyType.FitWithAspectRatio;
4011                     case "FILL_WITH_ASPECT_RATIO":
4012                         return SizeScalePolicyType.FillWithAspectRatio;
4013                     default:
4014                         return SizeScalePolicyType.UseSizeSet;
4015                 }
4016             }
4017             set
4018             {
4019                 string valueToString = "";
4020                 switch (value)
4021                 {
4022                     case SizeScalePolicyType.UseSizeSet:
4023                         {
4024                             valueToString = "USE_SIZE_SET";
4025                             break;
4026                         }
4027                     case SizeScalePolicyType.FitWithAspectRatio:
4028                         {
4029                             valueToString = "FIT_WITH_ASPECT_RATIO";
4030                             break;
4031                         }
4032                     case SizeScalePolicyType.FillWithAspectRatio:
4033                         {
4034                             valueToString = "FILL_WITH_ASPECT_RATIO";
4035                             break;
4036                         }
4037                     default:
4038                         {
4039                             valueToString = "USE_SIZE_SET";
4040                             break;
4041                         }
4042                 }
4043                 SetProperty(View.Property.SIZE_SCALE_POLICY, new Tizen.NUI.PropertyValue(valueToString));
4044             }
4045         }
4046
4047         /// <summary>
4048         ///  Gets or sets the status of whether the width size is dependent on the height size.
4049         /// </summary>
4050         /// <since_tizen> 3 </since_tizen>
4051         public bool WidthForHeight
4052         {
4053             get
4054             {
4055                 bool temp = false;
4056                 GetProperty(View.Property.WIDTH_FOR_HEIGHT).Get(out temp);
4057                 return temp;
4058             }
4059             set
4060             {
4061                 SetProperty(View.Property.WIDTH_FOR_HEIGHT, new Tizen.NUI.PropertyValue(value));
4062             }
4063         }
4064
4065         /// <summary>
4066         /// Gets or sets the status of whether the height size is dependent on the width size.
4067         /// </summary>
4068         /// <since_tizen> 3 </since_tizen>
4069         public bool HeightForWidth
4070         {
4071             get
4072             {
4073                 bool temp = false;
4074                 GetProperty(View.Property.HEIGHT_FOR_WIDTH).Get(out temp);
4075                 return temp;
4076             }
4077             set
4078             {
4079                 SetProperty(View.Property.HEIGHT_FOR_WIDTH, new Tizen.NUI.PropertyValue(value));
4080             }
4081         }
4082
4083         /// <summary>
4084         /// Gets or sets the padding for use in layout.
4085         /// </summary>
4086         /// <since_tizen> 5 </since_tizen>
4087         public Extents Padding
4088         {
4089             get
4090             {
4091                 Extents temp = new Extents(0, 0, 0, 0);
4092                 GetProperty(View.Property.PADDING).Get(temp);
4093                 return temp;
4094             }
4095             set
4096             {
4097                 SetProperty(View.Property.PADDING, new Tizen.NUI.PropertyValue(value));
4098             }
4099         }
4100
4101         /// <summary>
4102         /// Gets or sets the minimum size the view can be assigned in size negotiation.
4103         /// </summary>
4104         /// <since_tizen> 3 </since_tizen>
4105         public Size2D MinimumSize
4106         {
4107             get
4108             {
4109                 Size2D temp = new Size2D(0, 0);
4110                 GetProperty(View.Property.MINIMUM_SIZE).Get(temp);
4111                 return temp;
4112             }
4113             set
4114             {
4115                 SetProperty(View.Property.MINIMUM_SIZE, new Tizen.NUI.PropertyValue(value));
4116             }
4117         }
4118
4119         /// <summary>
4120         /// Gets or sets the maximum size the view can be assigned in size negotiation.
4121         /// </summary>
4122         /// <since_tizen> 3 </since_tizen>
4123         public Size2D MaximumSize
4124         {
4125             get
4126             {
4127                 Size2D temp = new Size2D(0, 0);
4128                 GetProperty(View.Property.MAXIMUM_SIZE).Get(temp);
4129                 return temp;
4130             }
4131             set
4132             {
4133                 SetProperty(View.Property.MAXIMUM_SIZE, new Tizen.NUI.PropertyValue(value));
4134             }
4135         }
4136
4137         /// <summary>
4138         /// Gets or sets whether a child view inherits it's parent's position.<br />
4139         /// Default is to inherit.<br />
4140         /// Switching this off means that using position sets the view's world position, i.e., translates from the world origin (0,0,0) to the pivot point of the view.<br />
4141         /// </summary>
4142         /// <since_tizen> 3 </since_tizen>
4143         public bool InheritPosition
4144         {
4145             get
4146             {
4147                 bool temp = false;
4148                 GetProperty(View.Property.INHERIT_POSITION).Get(out temp);
4149                 return temp;
4150             }
4151             set
4152             {
4153                 SetProperty(View.Property.INHERIT_POSITION, new Tizen.NUI.PropertyValue(value));
4154             }
4155         }
4156
4157         /// <summary>
4158         /// Gets or sets the clipping behavior (mode) of it's children.
4159         /// </summary>
4160         /// <since_tizen> 3 </since_tizen>
4161         public ClippingModeType ClippingMode
4162         {
4163             get
4164             {
4165                 string temp;
4166                 if (GetProperty(View.Property.CLIPPING_MODE).Get(out temp) == false)
4167                 {
4168                     NUILog.Error("ClippingMode get error!");
4169                 }
4170                 switch (temp)
4171                 {
4172                     case "DISABLED":
4173                     return ClippingModeType.Disabled;
4174                     case "CLIP_CHILDREN":
4175                     return ClippingModeType.ClipChildren;
4176                     case "CLIP_TO_BOUNDING_BOX":
4177                     return ClippingModeType.ClipToBoundingBox;
4178                     default:
4179                     return ClippingModeType.Disabled;
4180                 }
4181             }
4182             set
4183             {
4184                 SetProperty(View.Property.CLIPPING_MODE, new Tizen.NUI.PropertyValue((int)value));
4185             }
4186         }
4187
4188         /// <summary>
4189         /// Gets the number of renderers held by the view.
4190         /// </summary>
4191         /// <since_tizen> 3 </since_tizen>
4192         public uint RendererCount
4193         {
4194             get
4195             {
4196                 return GetRendererCount();
4197             }
4198         }
4199
4200
4201
4202         /// <summary>
4203         /// [Obsolete("Please do not use! this will be deprecated")]
4204         /// </summary>
4205         /// <since_tizen> 3 </since_tizen>
4206         /// Please do not use! this will be deprecated!
4207         /// Instead please use TouchEvent.
4208         [Obsolete("Please do not use! This will be deprecated! Please use TouchEvent instead!")]
4209         [EditorBrowsable(EditorBrowsableState.Never)]
4210         public event EventHandlerWithReturnType<object, TouchEventArgs, bool> Touched
4211         {
4212             add
4213             {
4214                 if (_touchDataEventHandler == null)
4215                 {
4216                     _touchDataCallback = OnTouch;
4217                     this.TouchSignal().Connect(_touchDataCallback);
4218                 }
4219
4220                 _touchDataEventHandler += value;
4221             }
4222
4223             remove
4224             {
4225                 _touchDataEventHandler -= value;
4226
4227                 if (_touchDataEventHandler == null && TouchSignal().Empty() == false)
4228                 {
4229                     this.TouchSignal().Disconnect(_touchDataCallback);
4230                 }
4231
4232             }
4233         }
4234
4235         /// <summary>
4236         /// [Obsolete("Please do not use! this will be deprecated")]
4237         /// </summary>
4238         /// <since_tizen> 3 </since_tizen>
4239         /// Please do not use! this will be deprecated!
4240         /// Instead please use HoverEvent.
4241         [Obsolete("Please do not use! This will be deprecated! Please use HoverEvent instead!")]
4242         [EditorBrowsable(EditorBrowsableState.Never)]
4243         public event EventHandlerWithReturnType<object, HoverEventArgs, bool> Hovered
4244         {
4245             add
4246             {
4247                 if (_hoverEventHandler == null)
4248                 {
4249                     _hoverEventCallback = OnHoverEvent;
4250                     this.HoveredSignal().Connect(_hoverEventCallback);
4251                 }
4252
4253                 _hoverEventHandler += value;
4254             }
4255
4256             remove
4257             {
4258                 _hoverEventHandler -= value;
4259
4260                 if (_hoverEventHandler == null && HoveredSignal().Empty() == false)
4261                 {
4262                     this.HoveredSignal().Disconnect(_hoverEventCallback);
4263                 }
4264
4265             }
4266         }
4267
4268         /// <summary>
4269         /// Please do not use! this will be deprecated.
4270         /// </summary>
4271         /// <since_tizen> 3 </since_tizen>
4272         /// Please do not use! this will be deprecated!
4273         /// Instead please use WheelEvent.
4274         [Obsolete("Please do not use! This will be deprecated! Please use WheelEvent instead!")]
4275         [EditorBrowsable(EditorBrowsableState.Never)]
4276         public event EventHandlerWithReturnType<object, WheelEventArgs, bool> WheelMoved
4277         {
4278             add
4279             {
4280                 if (_wheelEventHandler == null)
4281                 {
4282                     _wheelEventCallback = OnWheelEvent;
4283                     this.WheelEventSignal().Connect(_wheelEventCallback);
4284                 }
4285
4286                 _wheelEventHandler += value;
4287             }
4288
4289             remove
4290             {
4291                 _wheelEventHandler -= value;
4292
4293                 if (_wheelEventHandler == null && WheelEventSignal().Empty() == false)
4294                 {
4295                     this.WheelEventSignal().Disconnect(_wheelEventCallback);
4296                 }
4297
4298             }
4299         }
4300
4301         /// <summary>
4302         /// [Obsolete("Please do not use! this will be deprecated")]
4303         /// </summary>
4304         /// <since_tizen> 3 </since_tizen>
4305         /// Please do not use! this will be deprecated!
4306         /// Instead please use PivotPoint.
4307         [Obsolete("Please do not use! This will be deprecated! Please use PivotPoint instead! " +
4308             "Like: " +
4309             "View view = new View(); " +
4310             "view.PivotPoint = PivotPoint.Center; " +
4311             "view.PositionUsesPivotPoint = true;")]
4312         [EditorBrowsable(EditorBrowsableState.Never)]
4313         public Position AnchorPoint
4314         {
4315             get
4316             {
4317                 Position temp = new Position(0.0f, 0.0f, 0.0f);
4318                 GetProperty(View.Property.ANCHOR_POINT).Get(temp);
4319                 return temp;
4320             }
4321             set
4322             {
4323                 SetProperty(View.Property.ANCHOR_POINT, new Tizen.NUI.PropertyValue(value));
4324             }
4325         }
4326
4327         /// <summary>
4328         /// [Obsolete("Please do not use! this will be deprecated")]
4329         /// </summary>
4330         /// <since_tizen> 3 </since_tizen>
4331         [Obsolete("Please do not use! This will be deprecated! Please use Size2D instead! " +
4332             "Like: " +
4333             "View view = new View(); " +
4334             "view.Size2D = new Size2D(100, 100);")]
4335         [EditorBrowsable(EditorBrowsableState.Never)]
4336         public Size Size
4337         {
4338             get
4339             {
4340                 Size temp = new Size(0.0f, 0.0f, 0.0f);
4341                 GetProperty(View.Property.SIZE).Get(temp);
4342                 return temp;
4343             }
4344             set
4345             {
4346                 SetProperty(View.Property.SIZE, new Tizen.NUI.PropertyValue(value));
4347             }
4348         }
4349
4350         /// <summary>
4351         /// [Obsolete("Please do not use! this will be deprecated")]
4352         /// </summary>
4353         /// <since_tizen> 3 </since_tizen>
4354         /// Please do not use! this will be deprecated!
4355         /// Instead please use AddedToWindow.
4356         [Obsolete("Please do not use! This will be deprecated! Please use AddedToWindow instead!")]
4357         [EditorBrowsable(EditorBrowsableState.Never)]
4358         public event EventHandler OnWindowEvent
4359         {
4360             add
4361             {
4362                 if (_onWindowEventHandler == null)
4363                 {
4364                     _onWindowEventCallback = OnWindow;
4365                     this.OnWindowSignal().Connect(_onWindowEventCallback);
4366                 }
4367
4368                 _onWindowEventHandler += value;
4369             }
4370
4371             remove
4372             {
4373                 _onWindowEventHandler -= value;
4374
4375                 if (_onWindowEventHandler == null && OnWindowSignal().Empty() == false)
4376                 {
4377                     this.OnWindowSignal().Disconnect(_onWindowEventCallback);
4378                 }
4379             }
4380         }
4381
4382         /// <summary>
4383         /// [Obsolete("Please do not use! this will be deprecated")]
4384         /// </summary>
4385         /// <since_tizen> 3 </since_tizen>
4386         /// Please do not use! this will be deprecated!
4387         /// Instead please use RemovedFromWindow.
4388         [Obsolete("Please do not use! This will be deprecated! Please use RemovedFromWindow instead!")]
4389         [EditorBrowsable(EditorBrowsableState.Never)]
4390         public event EventHandler OffWindowEvent
4391         {
4392             add
4393             {
4394                 if (_offWindowEventHandler == null)
4395                 {
4396                     _offWindowEventCallback = OffWindow;
4397                     this.OffWindowSignal().Connect(_offWindowEventCallback);
4398                 }
4399
4400                 _offWindowEventHandler += value;
4401             }
4402
4403             remove
4404             {
4405                 _offWindowEventHandler -= value;
4406
4407                 if (_offWindowEventHandler == null && OffWindowSignal().Empty() == false)
4408                 {
4409                     this.OffWindowSignal().Disconnect(_offWindowEventCallback);
4410                 }
4411             }
4412         }
4413
4414         /// <summary>
4415         /// [Obsolete("Please do not use! this will be deprecated")]
4416         /// </summary>
4417         /// <since_tizen> 3 </since_tizen>
4418         /// Please do not use! this will be deprecated!
4419         /// Instead please use Relayout.
4420         [Obsolete("Please do not use! This will be deprecated! Please use Relayout instead!")]
4421         [EditorBrowsable(EditorBrowsableState.Never)]
4422         public event EventHandler OnRelayoutEvent
4423         {
4424             add
4425             {
4426                 if (_onRelayoutEventHandler == null)
4427                 {
4428                     _onRelayoutEventCallback = OnRelayout;
4429                     this.OnRelayoutSignal().Connect(_onRelayoutEventCallback);
4430                 }
4431
4432                 _onRelayoutEventHandler += value;
4433             }
4434
4435             remove
4436             {
4437                 _onRelayoutEventHandler -= value;
4438
4439                 if (_onRelayoutEventHandler == null && OnRelayoutSignal().Empty() == false)
4440                 {
4441                     this.OnRelayoutSignal().Disconnect(_onRelayoutEventCallback);
4442                 }
4443
4444             }
4445         }
4446
4447         /// <summary>
4448         /// "Please DO NOT use! This will be deprecated! Please use 'Container GetParent() for derived class' instead!"
4449         /// </summary>
4450         /// <since_tizen> 3 </since_tizen>
4451         [Obsolete("Please do not use! This will be deprecated! Please use 'Container GetParent() for derived class' instead! " +
4452             "Like: " +
4453             "Container parent =  view.GetParent(); " +
4454             "View view = parent as View;")]
4455         [EditorBrowsable(EditorBrowsableState.Never)]
4456         public new View Parent
4457         {
4458             get
4459             {
4460                 View ret;
4461                 IntPtr cPtr = NDalicPINVOKE.Actor_GetParent(swigCPtr);
4462
4463                 BaseHandle basehandle = Registry.GetManagedBaseHandleFromNativePtr(cPtr);
4464
4465                 if (basehandle is Layer)
4466                 {
4467                     ret = new View(cPtr, false);
4468                 }
4469                 else
4470                 {
4471                     ret = basehandle as View;
4472                 }
4473
4474                 if (NDalicPINVOKE.SWIGPendingException.Pending)
4475                     throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4476                 return ret;
4477             }
4478         }
4479
4480         /// <summary>
4481         /// Gets/Sets whether inherit parent's the layout Direction.
4482         /// </summary>
4483         /// <since_tizen> 4 </since_tizen>
4484         public bool InheritLayoutDirection
4485         {
4486             get
4487             {
4488                 bool temp = false;
4489                 GetProperty(View.Property.INHERIT_LAYOUT_DIRECTION).Get(out temp);
4490                 return temp;
4491             }
4492             set
4493             {
4494                 SetProperty(View.Property.INHERIT_LAYOUT_DIRECTION, new Tizen.NUI.PropertyValue(value));
4495             }
4496         }
4497
4498         /// <summary>
4499         /// Gets/Sets the layout Direction.
4500         /// </summary>
4501         /// <since_tizen> 4 </since_tizen>
4502         public ViewLayoutDirectionType LayoutDirection
4503         {
4504             get
4505             {
4506                 int temp;
4507                 if (GetProperty(View.Property.LAYOUT_DIRECTION).Get(out temp) == false)
4508                 {
4509                     NUILog.Error("LAYOUT_DIRECTION get error!");
4510                 }
4511                 return (ViewLayoutDirectionType)temp;
4512             }
4513             set
4514             {
4515                 SetProperty(View.Property.LAYOUT_DIRECTION, new Tizen.NUI.PropertyValue((int)value));
4516             }
4517         }
4518
4519         /// <summary>
4520         /// Gets or sets the Margin for use in layout.
4521         /// </summary>
4522         /// <since_tizen> 4 </since_tizen>
4523         public Extents Margin
4524         {
4525             get
4526             {
4527                 Extents temp = new Extents(0, 0, 0, 0);
4528                 GetProperty(View.Property.MARGIN).Get(temp);
4529                 return temp;
4530             }
4531             set
4532             {
4533                 SetProperty(View.Property.MARGIN, new Tizen.NUI.PropertyValue(value));
4534             }
4535         }
4536
4537         /// <summary>
4538         /// [Obsolete("Please do not use! this will be deprecated")]
4539         /// </summary>
4540         /// Please do not use! this will be deprecated!
4541         /// Instead please use Padding.
4542         /// <since_tizen> 4 </since_tizen>
4543         [Obsolete("Please do not use! this will be deprecated, instead please use Padding.")]
4544         [EditorBrowsable(EditorBrowsableState.Never)]
4545         public Extents PaddingEX
4546         {
4547             get
4548             {
4549                 Extents temp = new Extents(0, 0, 0, 0);
4550                 GetProperty(View.Property.PADDING).Get(temp);
4551                 return temp;
4552             }
4553             set
4554             {
4555                 SetProperty(View.Property.PADDING, new Tizen.NUI.PropertyValue(value));
4556             }
4557         }
4558
4559         /// <summary>
4560         /// Perform an action on a visual registered to this view. <br />
4561         /// Visuals will have actions, this API is used to perform one of these actions with the given attributes.
4562         /// </summary>
4563         /// <param name="propertyIndexOfVisual">The Property index of the visual.</param>
4564         /// <param name="propertyIndexOfActionId">The action to perform.  See Visual to find supported actions.</param>
4565         /// <param name="attributes">Optional attributes for the action.</param>
4566         /// <since_tizen> 5 </since_tizen>
4567         public void DoAction(int propertyIndexOfVisual, int propertyIndexOfActionId, PropertyValue attributes)
4568         {
4569             NDalicManualPINVOKE.View_DoAction(swigCPtr, propertyIndexOfVisual, propertyIndexOfActionId, PropertyValue.getCPtr(attributes));
4570             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4571         }
4572
4573     }
4574
4575     /// <summary>
4576     /// The View layout Direction type.
4577     /// </summary>
4578     /// <since_tizen> 4 </since_tizen>
4579     public enum ViewLayoutDirectionType
4580     {
4581         /// <summary>
4582         /// Left to right.
4583         /// </summary>
4584         /// <since_tizen> 4 </since_tizen>
4585         LTR,
4586         /// <summary>
4587         /// Right to left.
4588         /// </summary>
4589         /// <since_tizen> 4 </since_tizen>
4590         RTL
4591     }
4592 }