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