[NUI] Split NUI Interop class (#804)
[platform/core/csapi/tizenfx.git] / src / Tizen.NUI / src / public / BaseComponents / View.cs
1 /*
2  * Copyright(c) 2019 Samsung Electronics Co., Ltd.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  *
16  */
17 using System;
18 using System.ComponentModel;
19 using System.Runtime.InteropServices;
20 using Tizen.NUI.Binding;
21
22 namespace Tizen.NUI.BaseComponents
23 {
24     /// <summary>
25     /// The View layout Direction type.
26     /// </summary>
27     /// <since_tizen> 4 </since_tizen>
28     public enum ViewLayoutDirectionType
29     {
30         /// <summary>
31         /// Left to right.
32         /// </summary>
33         /// <since_tizen> 4 </since_tizen>
34         LTR,
35         /// <summary>
36         /// Right to left.
37         /// </summary>
38         /// <since_tizen> 4 </since_tizen>
39         RTL
40     }
41
42     internal enum ChildLayoutData
43     {
44         /// <summary>
45         /// Constant which indicates child size should match parent size
46         /// </summary>
47         MatchParent = -1,
48         /// <summary>
49         /// Constant which indicates parent should take the smallest size possible to wrap it's children with their desired size
50         /// </summary>
51         WrapContent = -2,
52     }
53
54     internal enum ResourceLoadingStatusType
55     {
56         Invalid = -1,
57         Preparing = 0,
58         Ready,
59         Failed,
60     }
61
62     /// <summary>
63     /// View is the base class for all views.
64     /// </summary>
65     /// <since_tizen> 3 </since_tizen>
66     public class View : Container, IResourcesProvider
67     {
68         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
69         [EditorBrowsable(EditorBrowsableState.Never)]
70         public static readonly BindableProperty StyleNameProperty = BindableProperty.Create("StyleName", typeof(string), typeof(View), string.Empty, propertyChanged: (bindable, oldValue, newValue) =>
71         {
72             var view = (View)bindable;
73             if (newValue != null)
74             {
75                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.STYLE_NAME, new Tizen.NUI.PropertyValue((string)newValue));
76             }
77         },
78         defaultValueCreator: (bindable) =>
79         {
80             var view = (View)bindable;
81             string temp;
82             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.STYLE_NAME).Get(out temp);
83             return temp;
84         });
85         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
86         [EditorBrowsable(EditorBrowsableState.Never)]
87         public static readonly BindableProperty BackgroundColorProperty = BindableProperty.Create("BackgroundColor", typeof(Color), typeof(View), null, propertyChanged: (bindable, oldValue, newValue) =>
88         {
89             var view = (View)bindable;
90             if (newValue != null)
91             {
92                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.BACKGROUND, new Tizen.NUI.PropertyValue((Color)newValue));
93             }
94         },
95         defaultValueCreator: (bindable) =>
96         {
97             var view = (View)bindable;
98             Color backgroundColor = new Color(0.0f, 0.0f, 0.0f, 0.0f);
99
100             Tizen.NUI.PropertyMap background = view.Background;
101             int visualType = 0;
102             background.Find(Visual.Property.Type)?.Get(out visualType);
103             if (visualType == (int)Visual.Type.Color)
104             {
105                 background.Find(ColorVisualProperty.MixColor)?.Get(backgroundColor);
106             }
107
108             return backgroundColor;
109         });
110         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
111         [EditorBrowsable(EditorBrowsableState.Never)]
112         public static readonly BindableProperty BackgroundImageProperty = BindableProperty.Create("BackgroundImage", typeof(string), typeof(View), default(string), propertyChanged: (bindable, oldValue, newValue) =>
113         {
114             var view = (View)bindable;
115             if (newValue != null)
116             {
117                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.BACKGROUND, new Tizen.NUI.PropertyValue((string)newValue));
118             }
119         },
120         defaultValueCreator: (bindable) =>
121         {
122             var view = (View)bindable;
123             string backgroundImage = "";
124
125             Tizen.NUI.PropertyMap background = view.Background;
126             int visualType = 0;
127             background.Find(Visual.Property.Type)?.Get(out visualType);
128             if (visualType == (int)Visual.Type.Image)
129             {
130                 background.Find(ImageVisualProperty.URL)?.Get(out backgroundImage);
131             }
132
133             return backgroundImage;
134         });
135         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
136         [EditorBrowsable(EditorBrowsableState.Never)]
137         public static readonly BindableProperty BackgroundProperty = BindableProperty.Create("Background", typeof(PropertyMap), typeof(View), null, propertyChanged: (bindable, oldValue, newValue) =>
138         {
139             var view = (View)bindable;
140             if (newValue != null)
141             {
142                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.BACKGROUND, new Tizen.NUI.PropertyValue((PropertyMap)newValue));
143             }
144         },
145         defaultValueCreator: (bindable) =>
146         {
147             var view = (View)bindable;
148             Tizen.NUI.PropertyMap temp = new Tizen.NUI.PropertyMap();
149             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.BACKGROUND).Get(temp);
150             return temp;
151         });
152         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
153         [EditorBrowsable(EditorBrowsableState.Never)]
154         public static readonly BindableProperty StateProperty = BindableProperty.Create("State", typeof(States), typeof(View), States.Normal, propertyChanged: (bindable, oldValue, newValue) =>
155         {
156             var view = (View)bindable;
157             if (newValue != null)
158             {
159                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.STATE, new Tizen.NUI.PropertyValue((int)newValue));
160             }
161         },
162         defaultValueCreator: (bindable) =>
163         {
164             var view = (View)bindable;
165             int temp = 0;
166             if (Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.STATE).Get(out temp) == false)
167             {
168                 NUILog.Error("State get error!");
169             }
170             switch (temp)
171             {
172                 case 0: return States.Normal;
173                 case 1: return States.Focused;
174                 case 2: return States.Disabled;
175                 default: return States.Normal;
176             }
177         });
178         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
179         [EditorBrowsable(EditorBrowsableState.Never)]
180         public static readonly BindableProperty SubStateProperty = BindableProperty.Create("SubState", typeof(States), typeof(View), States.Normal, propertyChanged: (bindable, oldValue, newValue) =>
181         {
182             var view = (View)bindable;
183             string valueToString = "";
184             if (newValue != null)
185             {
186                 switch ((States)newValue)
187                 {
188                     case States.Normal: { valueToString = "NORMAL"; break; }
189                     case States.Focused: { valueToString = "FOCUSED"; break; }
190                     case States.Disabled: { valueToString = "DISABLED"; break; }
191                     default: { valueToString = "NORMAL"; break; }
192                 }
193                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.SUB_STATE, new Tizen.NUI.PropertyValue(valueToString));
194             }
195         },
196         defaultValueCreator: (bindable) =>
197         {
198             var view = (View)bindable;
199             string temp;
200             if (Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.SUB_STATE).Get(out temp) == false)
201             {
202                 NUILog.Error("subState get error!");
203             }
204             switch (temp)
205             {
206                 case "NORMAL": return States.Normal;
207                 case "FOCUSED": return States.Focused;
208                 case "DISABLED": return States.Disabled;
209                 default: return States.Normal;
210             }
211         });
212         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
213         [EditorBrowsable(EditorBrowsableState.Never)]
214         public static readonly BindableProperty TooltipProperty = BindableProperty.Create("Tooltip", typeof(PropertyMap), typeof(View), null, propertyChanged: (bindable, oldValue, newValue) =>
215         {
216             var view = (View)bindable;
217             if (newValue != null)
218             {
219                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.TOOLTIP, new Tizen.NUI.PropertyValue((PropertyMap)newValue));
220             }
221         },
222         defaultValueCreator: (bindable) =>
223         {
224             var view = (View)bindable;
225             Tizen.NUI.PropertyMap temp = new Tizen.NUI.PropertyMap();
226             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.TOOLTIP).Get(temp);
227             return temp;
228         });
229
230         /// Only for XAML property binding. This will be changed as Inhouse API by ACR later.
231         public static readonly BindableProperty FlexProperty = BindableProperty.Create("Flex", typeof(float), typeof(View), default(float), propertyChanged: (bindable, oldValue, newValue) =>
232         {
233             var view = (View)bindable;
234             if (newValue != null)
235             {
236                 Tizen.NUI.Object.SetProperty(view.swigCPtr, FlexContainer.ChildProperty.FLEX, new Tizen.NUI.PropertyValue((float)newValue));
237             }
238         },
239         defaultValueCreator: (bindable) =>
240         {
241             var view = (View)bindable;
242             float temp = 0.0f;
243             Tizen.NUI.Object.GetProperty(view.swigCPtr, FlexContainer.ChildProperty.FLEX).Get(out temp);
244             return temp;
245         });
246
247         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
248         [EditorBrowsable(EditorBrowsableState.Never)]
249         public static readonly BindableProperty AlignSelfProperty = BindableProperty.Create("AlignSelf", typeof(int), typeof(View), default(int), propertyChanged: (bindable, oldValue, newValue) =>
250         {
251             var view = (View)bindable;
252             if (newValue != null)
253             {
254                 Tizen.NUI.Object.SetProperty(view.swigCPtr, FlexContainer.ChildProperty.ALIGN_SELF, new Tizen.NUI.PropertyValue((int)newValue));
255             }
256         },
257         defaultValueCreator: (bindable) =>
258         {
259             var view = (View)bindable;
260             int temp = 0;
261             Tizen.NUI.Object.GetProperty(view.swigCPtr, FlexContainer.ChildProperty.ALIGN_SELF).Get(out temp);
262             return temp;
263         });
264         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
265         [EditorBrowsable(EditorBrowsableState.Never)]
266         public static readonly BindableProperty FlexMarginProperty = BindableProperty.Create("FlexMargin", typeof(Vector4), typeof(View), null, propertyChanged: (bindable, oldValue, newValue) =>
267         {
268             var view = (View)bindable;
269             if (newValue != null)
270             {
271                 Tizen.NUI.Object.SetProperty(view.swigCPtr, FlexContainer.ChildProperty.FLEX_MARGIN, new Tizen.NUI.PropertyValue((Vector4)newValue));
272             }
273         },
274         defaultValueCreator: (bindable) =>
275         {
276             var view = (View)bindable;
277             Vector4 temp = new Vector4(0.0f, 0.0f, 0.0f, 0.0f);
278             Tizen.NUI.Object.GetProperty(view.swigCPtr, FlexContainer.ChildProperty.FLEX_MARGIN).Get(temp);
279             return temp;
280         });
281         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
282         [EditorBrowsable(EditorBrowsableState.Never)]
283         public static readonly BindableProperty CellIndexProperty = BindableProperty.Create("CellIndex", typeof(Vector2), typeof(View), null, propertyChanged: (bindable, oldValue, newValue) =>
284         {
285             var view = (View)bindable;
286             if (newValue != null)
287             {
288                 Tizen.NUI.Object.SetProperty(view.swigCPtr, TableView.ChildProperty.CELL_INDEX, new Tizen.NUI.PropertyValue((Vector2)newValue));
289             }
290         },
291         defaultValueCreator: (bindable) =>
292         {
293             var view = (View)bindable;
294             Vector2 temp = new Vector2(0.0f, 0.0f);
295             Tizen.NUI.Object.GetProperty(view.swigCPtr, TableView.ChildProperty.CELL_INDEX).Get(temp);
296             return temp;
297         });
298         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
299         [EditorBrowsable(EditorBrowsableState.Never)]
300         public static readonly BindableProperty RowSpanProperty = BindableProperty.Create("RowSpan", typeof(float), typeof(View), default(float), propertyChanged: (bindable, oldValue, newValue) =>
301         {
302             var view = (View)bindable;
303             if (newValue != null)
304             {
305                 Tizen.NUI.Object.SetProperty(view.swigCPtr, TableView.ChildProperty.ROW_SPAN, new Tizen.NUI.PropertyValue((float)newValue));
306             }
307         },
308         defaultValueCreator: (bindable) =>
309         {
310             var view = (View)bindable;
311             float temp = 0.0f;
312             Tizen.NUI.Object.GetProperty(view.swigCPtr, TableView.ChildProperty.ROW_SPAN).Get(out temp);
313             return temp;
314         });
315         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
316         [EditorBrowsable(EditorBrowsableState.Never)]
317         public static readonly BindableProperty ColumnSpanProperty = BindableProperty.Create("ColumnSpan", typeof(float), typeof(View), default(float), propertyChanged: (bindable, oldValue, newValue) =>
318         {
319             var view = (View)bindable;
320             if (newValue != null)
321             {
322                 Tizen.NUI.Object.SetProperty(view.swigCPtr, TableView.ChildProperty.COLUMN_SPAN, new Tizen.NUI.PropertyValue((float)newValue));
323             }
324         },
325         defaultValueCreator: (bindable) =>
326         {
327             var view = (View)bindable;
328             float temp = 0.0f;
329             Tizen.NUI.Object.GetProperty(view.swigCPtr, TableView.ChildProperty.COLUMN_SPAN).Get(out temp);
330             return temp;
331         });
332         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
333         [EditorBrowsable(EditorBrowsableState.Never)]
334         public static readonly BindableProperty CellHorizontalAlignmentProperty = BindableProperty.Create("CellHorizontalAlignment", typeof(HorizontalAlignmentType), typeof(View), HorizontalAlignmentType.Left, propertyChanged: (bindable, oldValue, newValue) =>
335         {
336             var view = (View)bindable;
337             string valueToString = "";
338
339             if (newValue != null)
340             {
341                 switch ((HorizontalAlignmentType)newValue)
342                 {
343                     case Tizen.NUI.HorizontalAlignmentType.Left: { valueToString = "left"; break; }
344                     case Tizen.NUI.HorizontalAlignmentType.Center: { valueToString = "center"; break; }
345                     case Tizen.NUI.HorizontalAlignmentType.Right: { valueToString = "right"; break; }
346                     default: { valueToString = "left"; break; }
347                 }
348                 Tizen.NUI.Object.SetProperty(view.swigCPtr, TableView.ChildProperty.CELL_HORIZONTAL_ALIGNMENT, new Tizen.NUI.PropertyValue(valueToString));
349             }
350         },
351         defaultValueCreator: (bindable) =>
352         {
353             var view = (View)bindable;
354             string temp;
355             if (Tizen.NUI.Object.GetProperty(view.swigCPtr, TableView.ChildProperty.CELL_HORIZONTAL_ALIGNMENT).Get(out temp) == false)
356             {
357                 NUILog.Error("CellHorizontalAlignment get error!");
358             }
359
360             switch (temp)
361             {
362                 case "left": return Tizen.NUI.HorizontalAlignmentType.Left;
363                 case "center": return Tizen.NUI.HorizontalAlignmentType.Center;
364                 case "right": return Tizen.NUI.HorizontalAlignmentType.Right;
365                 default: return Tizen.NUI.HorizontalAlignmentType.Left;
366             }
367         });
368         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
369         [EditorBrowsable(EditorBrowsableState.Never)]
370         public static readonly BindableProperty CellVerticalAlignmentProperty = BindableProperty.Create("CellVerticalAlignment", typeof(VerticalAlignmentType), typeof(View), VerticalAlignmentType.Top, propertyChanged: (bindable, oldValue, newValue) =>
371         {
372             var view = (View)bindable;
373             string valueToString = "";
374
375             if (newValue != null)
376             {
377                 switch ((VerticalAlignmentType)newValue)
378                 {
379                     case Tizen.NUI.VerticalAlignmentType.Top: { valueToString = "top"; break; }
380                     case Tizen.NUI.VerticalAlignmentType.Center: { valueToString = "center"; break; }
381                     case Tizen.NUI.VerticalAlignmentType.Bottom: { valueToString = "bottom"; break; }
382                     default: { valueToString = "top"; break; }
383                 }
384                 Tizen.NUI.Object.SetProperty(view.swigCPtr, TableView.ChildProperty.CELL_VERTICAL_ALIGNMENT, new Tizen.NUI.PropertyValue(valueToString));
385             }
386         },
387         defaultValueCreator: (bindable) =>
388         {
389             var view = (View)bindable;
390             string temp;
391             Tizen.NUI.Object.GetProperty(view.swigCPtr, TableView.ChildProperty.CELL_VERTICAL_ALIGNMENT).Get(out temp);
392             {
393                 NUILog.Error("CellVerticalAlignment get error!");
394             }
395
396             switch (temp)
397             {
398                 case "top": return Tizen.NUI.VerticalAlignmentType.Top;
399                 case "center": return Tizen.NUI.VerticalAlignmentType.Center;
400                 case "bottom": return Tizen.NUI.VerticalAlignmentType.Bottom;
401                 default: return Tizen.NUI.VerticalAlignmentType.Top;
402             }
403         });
404         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
405         [EditorBrowsable(EditorBrowsableState.Never)]
406         public static readonly BindableProperty WeightProperty = BindableProperty.Create("Weight", typeof(float), typeof(View), default(float), propertyChanged: (bindable, oldValue, newValue) =>
407         {
408             var view = (View)bindable;
409             if (newValue != null)
410             {
411                 Tizen.NUI.Object.SetProperty(view.swigCPtr, LinearLayout.ChildProperty.WEIGHT, new Tizen.NUI.PropertyValue((float)newValue));
412             }
413         },
414         defaultValueCreator: (bindable) =>
415         {
416             var view = (View)bindable;
417             float temp = 0.0f;
418             Tizen.NUI.Object.GetProperty(view.swigCPtr, LinearLayout.ChildProperty.WEIGHT).Get(out temp);
419             return temp;
420         });
421         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
422         [EditorBrowsable(EditorBrowsableState.Never)]
423         public static readonly BindableProperty LeftFocusableViewProperty = BindableProperty.Create(nameof(View.LeftFocusableView), typeof(View), typeof(View), null, propertyChanged: (bindable, oldValue, newValue) =>
424         {
425             var view = (View)bindable;
426             if (newValue != null) { view.LeftFocusableViewId = (int)(newValue as View)?.GetId(); }
427             else { view.LeftFocusableViewId = -1; }
428         },
429         defaultValueCreator: (bindable) =>
430         {
431             var view = (View)bindable;
432             if (view.LeftFocusableViewId >= 0) { return view.ConvertIdToView((uint)view.LeftFocusableViewId); }
433             return null;
434         });
435         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
436         [EditorBrowsable(EditorBrowsableState.Never)]
437         public static readonly BindableProperty RightFocusableViewProperty = BindableProperty.Create(nameof(View.RightFocusableView), typeof(View), typeof(View), null, propertyChanged: (bindable, oldValue, newValue) =>
438         {
439             var view = (View)bindable;
440             if (newValue != null) { view.RightFocusableViewId = (int)(newValue as View)?.GetId(); }
441             else { view.RightFocusableViewId = -1; }
442         },
443         defaultValueCreator: (bindable) =>
444         {
445             var view = (View)bindable;
446             if (view.RightFocusableViewId >= 0) { return view.ConvertIdToView((uint)view.RightFocusableViewId); }
447             return null;
448         });
449         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
450         [EditorBrowsable(EditorBrowsableState.Never)]
451         public static readonly BindableProperty UpFocusableViewProperty = BindableProperty.Create(nameof(View.UpFocusableView), typeof(View), typeof(View), null, propertyChanged: (bindable, oldValue, newValue) =>
452         {
453             var view = (View)bindable;
454             if (newValue != null) { view.UpFocusableViewId = (int)(newValue as View)?.GetId(); }
455             else { view.UpFocusableViewId = -1; }
456         },
457         defaultValueCreator: (bindable) =>
458         {
459             var view = (View)bindable;
460             if (view.UpFocusableViewId >= 0) { return view.ConvertIdToView((uint)view.UpFocusableViewId); }
461             return null;
462         });
463         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
464         [EditorBrowsable(EditorBrowsableState.Never)]
465         public static readonly BindableProperty DownFocusableViewProperty = BindableProperty.Create(nameof(View.DownFocusableView), typeof(View), typeof(View), null, propertyChanged: (bindable, oldValue, newValue) =>
466         {
467             var view = (View)bindable;
468             if (newValue != null) { view.DownFocusableViewId = (int)(newValue as View)?.GetId(); }
469             else { view.DownFocusableViewId = -1; }
470         },
471         defaultValueCreator: (bindable) =>
472         {
473             var view = (View)bindable;
474             if (view.DownFocusableViewId >= 0) { return view.ConvertIdToView((uint)view.DownFocusableViewId); }
475             return null;
476         });
477         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
478         [EditorBrowsable(EditorBrowsableState.Never)]
479         public static readonly BindableProperty FocusableProperty = BindableProperty.Create("Focusable", typeof(bool), typeof(View), false, propertyChanged: (bindable, oldValue, newValue) =>
480         {
481             var view = (View)bindable;
482             if (newValue != null) { view.SetKeyboardFocusable((bool)newValue); }
483         },
484         defaultValueCreator: (bindable) =>
485         {
486             var view = (View)bindable;
487             return view.IsKeyboardFocusable();
488         });
489         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
490         [EditorBrowsable(EditorBrowsableState.Never)]
491         public static readonly BindableProperty Size2DProperty = BindableProperty.Create("Size2D", typeof(Size2D), typeof(View), null, propertyChanged: (bindable, oldValue, newValue) =>
492         {
493             var view = (View)bindable;
494             if (newValue != null)
495             {
496                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.SIZE, new Tizen.NUI.PropertyValue(new Size((Size2D)newValue)));
497             }
498         },
499         defaultValueCreator: (bindable) =>
500         {
501             var view = (View)bindable;
502             Size temp = new Size(0.0f, 0.0f, 0.0f);
503             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.SIZE).Get(temp);
504             Size2D size = new Size2D((int)temp.Width, (int)temp.Height);
505             return size;
506         });
507         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
508         [EditorBrowsable(EditorBrowsableState.Never)]
509         public static readonly BindableProperty OpacityProperty = BindableProperty.Create("Opacity", typeof(float), typeof(View), default(float), propertyChanged: (bindable, oldValue, newValue) =>
510         {
511             var view = (View)bindable;
512             if (newValue != null)
513             {
514                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.OPACITY, new Tizen.NUI.PropertyValue((float)newValue));
515             }
516         },
517         defaultValueCreator: (bindable) =>
518         {
519             var view = (View)bindable;
520             float temp = 0.0f;
521             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.OPACITY).Get(out temp);
522             return temp;
523         });
524         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
525         [EditorBrowsable(EditorBrowsableState.Never)]
526         public static readonly BindableProperty Position2DProperty = BindableProperty.Create("Position2D", typeof(Position2D), typeof(View), null, propertyChanged: (bindable, oldValue, newValue) =>
527         {
528             var view = (View)bindable;
529             if (newValue != null)
530             {
531                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.POSITION, new Tizen.NUI.PropertyValue(new Position((Position2D)newValue)));
532             }
533         },
534         defaultValueCreator: (bindable) =>
535         {
536             var view = (View)bindable;
537             Position temp = new Position(0.0f, 0.0f, 0.0f);
538             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.POSITION).Get(temp);
539             return new Position2D(temp);
540         });
541         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
542         [EditorBrowsable(EditorBrowsableState.Never)]
543         public static readonly BindableProperty PositionUsesPivotPointProperty = BindableProperty.Create("PositionUsesPivotPoint", typeof(bool), typeof(View), true, propertyChanged: (bindable, oldValue, newValue) =>
544         {
545             var view = (View)bindable;
546             if (newValue != null)
547             {
548                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.POSITION_USES_ANCHOR_POINT, new Tizen.NUI.PropertyValue((bool)newValue));
549             }
550         },
551         defaultValueCreator: (bindable) =>
552         {
553             var view = (View)bindable;
554             bool temp = false;
555             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.POSITION_USES_ANCHOR_POINT).Get(out temp);
556             return temp;
557         });
558         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
559         [EditorBrowsable(EditorBrowsableState.Never)]
560         public static readonly BindableProperty SiblingOrderProperty = BindableProperty.Create("SiblingOrder", typeof(int), typeof(View), default(int), propertyChanged: (bindable, oldValue, newValue) =>
561         {
562             var view = (View)bindable;
563             int value;
564             if (newValue != null)
565             {
566                 value = (int)newValue;
567                 if (value < 0)
568                 {
569                     NUILog.Error("SiblingOrder should be bigger than 0 or equal to 0.");
570                     return;
571                 }
572                 var siblings = view.GetParent()?.Children;
573                 if (siblings != null)
574                 {
575                     int currentOrder = siblings.IndexOf(view);
576                     if (value != currentOrder)
577                     {
578                         if (value == 0) { view.LowerToBottom(); }
579                         else if (value < siblings.Count - 1)
580                         {
581                             if (value > currentOrder) { view.RaiseAbove(siblings[value]); }
582                             else { view.LowerBelow(siblings[value]); }
583                         }
584                         else { view.RaiseToTop(); }
585                     }
586                 }
587             }
588         },
589         defaultValueCreator: (bindable) =>
590         {
591             var view = (View)bindable;
592             var parentChildren = view.GetParent()?.Children;
593             int currentOrder = 0;
594             if (parentChildren != null)
595             {
596                 currentOrder = parentChildren.IndexOf(view);
597
598                 if (currentOrder < 0) { return 0; }
599                 else if (currentOrder < parentChildren.Count) { return currentOrder; }
600             }
601
602             return 0;
603         });
604         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
605         [EditorBrowsable(EditorBrowsableState.Never)]
606         public static readonly BindableProperty ParentOriginProperty = BindableProperty.Create("ParentOrigin", typeof(Position), typeof(View), null, propertyChanged: (bindable, oldValue, newValue) =>
607         {
608             var view = (View)bindable;
609             if (newValue != null)
610             {
611                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.PARENT_ORIGIN, new Tizen.NUI.PropertyValue((Position)newValue));
612             }
613         },
614         defaultValueCreator: (bindable) =>
615         {
616             var view = (View)bindable;
617             Position temp = new Position(0.0f, 0.0f, 0.0f);
618             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.PARENT_ORIGIN).Get(temp);
619             return temp;
620         }
621         );
622         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
623         [EditorBrowsable(EditorBrowsableState.Never)]
624         public static readonly BindableProperty PivotPointProperty = BindableProperty.Create("PivotPoint", typeof(Position), typeof(View), null, propertyChanged: (bindable, oldValue, newValue) =>
625         {
626             var view = (View)bindable;
627             if (newValue != null)
628             {
629                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.ANCHOR_POINT, new Tizen.NUI.PropertyValue((Position)newValue));
630             }
631         },
632         defaultValueCreator: (bindable) =>
633         {
634             var view = (View)bindable;
635             Position temp = new Position(0.0f, 0.0f, 0.0f);
636             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.ANCHOR_POINT).Get(temp);
637             return temp;
638         });
639         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
640         [EditorBrowsable(EditorBrowsableState.Never)]
641         public static readonly BindableProperty SizeWidthProperty = BindableProperty.Create("SizeWidth", typeof(float), typeof(View), default(float), propertyChanged: (bindable, oldValue, newValue) =>
642         {
643             var view = (View)bindable;
644             if (newValue != null)
645             {
646                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.SIZE_WIDTH, new Tizen.NUI.PropertyValue((float)newValue));
647             }
648         },
649         defaultValueCreator: (bindable) =>
650         {
651             var view = (View)bindable;
652             float temp = 0.0f;
653             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.SIZE_WIDTH).Get(out temp);
654             return temp;
655         });
656         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
657         [EditorBrowsable(EditorBrowsableState.Never)]
658         public static readonly BindableProperty SizeHeightProperty = BindableProperty.Create("SizeHeight", typeof(float), typeof(View), default(float), propertyChanged: (bindable, oldValue, newValue) =>
659         {
660             var view = (View)bindable;
661             if (newValue != null)
662             {
663                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.SIZE_HEIGHT, new Tizen.NUI.PropertyValue((float)newValue));
664             }
665         },
666         defaultValueCreator: (bindable) =>
667         {
668             var view = (View)bindable;
669             float temp = 0.0f;
670             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.SIZE_HEIGHT).Get(out temp);
671             return temp;
672         });
673         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
674         [EditorBrowsable(EditorBrowsableState.Never)]
675         public static readonly BindableProperty PositionProperty = BindableProperty.Create("Position", typeof(Position), typeof(View), null, propertyChanged: (bindable, oldValue, newValue) =>
676         {
677             var view = (View)bindable;
678             if (newValue != null)
679             {
680                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.POSITION, new Tizen.NUI.PropertyValue((Position)newValue));
681             }
682         },
683         defaultValueCreator: (bindable) =>
684         {
685             var view = (View)bindable;
686             Position temp = new Position(0.0f, 0.0f, 0.0f);
687             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.POSITION).Get(temp);
688             return temp;
689         });
690         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
691         [EditorBrowsable(EditorBrowsableState.Never)]
692         public static readonly BindableProperty PositionXProperty = BindableProperty.Create("PositionX", typeof(float), typeof(View), default(float), propertyChanged: (bindable, oldValue, newValue) =>
693         {
694             var view = (View)bindable;
695             if (newValue != null)
696             {
697                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.POSITION_X, new Tizen.NUI.PropertyValue((float)newValue));
698             }
699         },
700         defaultValueCreator: (bindable) =>
701         {
702             var view = (View)bindable;
703             float temp = 0.0f;
704             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.POSITION_X).Get(out temp);
705             return temp;
706         });
707         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
708         [EditorBrowsable(EditorBrowsableState.Never)]
709         public static readonly BindableProperty PositionYProperty = BindableProperty.Create("PositionY", typeof(float), typeof(View), default(float), propertyChanged: (bindable, oldValue, newValue) =>
710         {
711             var view = (View)bindable;
712             if (newValue != null)
713             {
714                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.POSITION_Y, new Tizen.NUI.PropertyValue((float)newValue));
715             }
716         },
717         defaultValueCreator: (bindable) =>
718         {
719             var view = (View)bindable;
720             float temp = 0.0f;
721             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.POSITION_Y).Get(out temp);
722             return temp;
723         });
724         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
725         [EditorBrowsable(EditorBrowsableState.Never)]
726         public static readonly BindableProperty PositionZProperty = BindableProperty.Create("PositionZ", typeof(float), typeof(View), default(float), propertyChanged: (bindable, oldValue, newValue) =>
727         {
728             var view = (View)bindable;
729             if (newValue != null)
730             {
731                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.POSITION_Z, new Tizen.NUI.PropertyValue((float)newValue));
732             }
733         },
734         defaultValueCreator: (bindable) =>
735         {
736             var view = (View)bindable;
737             float temp = 0.0f;
738             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.POSITION_Z).Get(out temp);
739             return temp;
740         });
741         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
742         [EditorBrowsable(EditorBrowsableState.Never)]
743         public static readonly BindableProperty OrientationProperty = BindableProperty.Create("Orientation", typeof(Rotation), typeof(View), null, propertyChanged: (bindable, oldValue, newValue) =>
744         {
745             var view = (View)bindable;
746             if (newValue != null)
747             {
748                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.ORIENTATION, new Tizen.NUI.PropertyValue((Rotation)newValue));
749             }
750         },
751         defaultValueCreator: (bindable) =>
752         {
753             var view = (View)bindable;
754             Rotation temp = new Rotation();
755             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.ORIENTATION).Get(temp);
756             return temp;
757         });
758         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
759         [EditorBrowsable(EditorBrowsableState.Never)]
760         public static readonly BindableProperty ScaleProperty = BindableProperty.Create("Scale", typeof(Vector3), typeof(View), null, propertyChanged: (bindable, oldValue, newValue) =>
761         {
762             var view = (View)bindable;
763             if (newValue != null)
764             {
765                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.SCALE, new Tizen.NUI.PropertyValue((Vector3)newValue));
766             }
767         },
768         defaultValueCreator: (bindable) =>
769         {
770             var view = (View)bindable;
771             Vector3 temp = new Vector3(0.0f, 0.0f, 0.0f);
772             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.SCALE).Get(temp);
773             return temp;
774         });
775         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
776         [EditorBrowsable(EditorBrowsableState.Never)]
777         public static readonly BindableProperty ScaleXProperty = BindableProperty.Create("ScaleX", typeof(float), typeof(View), default(float), propertyChanged: (bindable, oldValue, newValue) =>
778         {
779             var view = (View)bindable;
780             if (newValue != null)
781             {
782                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.SCALE_X, new Tizen.NUI.PropertyValue((float)newValue));
783             }
784         },
785         defaultValueCreator: (bindable) =>
786         {
787             var view = (View)bindable;
788             float temp = 0.0f;
789             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.SCALE_X).Get(out temp);
790             return temp;
791         });
792         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
793         [EditorBrowsable(EditorBrowsableState.Never)]
794         public static readonly BindableProperty ScaleYProperty = BindableProperty.Create("ScaleY", typeof(float), typeof(View), default(float), propertyChanged: (bindable, oldValue, newValue) =>
795         {
796             var view = (View)bindable;
797             if (newValue != null)
798             {
799                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.SCALE_Y, new Tizen.NUI.PropertyValue((float)newValue));
800             }
801         },
802         defaultValueCreator: (bindable) =>
803         {
804             var view = (View)bindable;
805             float temp = 0.0f;
806             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.SCALE_Y).Get(out temp);
807             return temp;
808         });
809         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
810         [EditorBrowsable(EditorBrowsableState.Never)]
811         public static readonly BindableProperty ScaleZProperty = BindableProperty.Create("ScaleZ", typeof(float), typeof(View), default(float), propertyChanged: (bindable, oldValue, newValue) =>
812         {
813             var view = (View)bindable;
814             if (newValue != null)
815             {
816                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.SCALE_Z, new Tizen.NUI.PropertyValue((float)newValue));
817             }
818         },
819         defaultValueCreator: (bindable) =>
820         {
821             var view = (View)bindable;
822             float temp = 0.0f;
823             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.SCALE_Z).Get(out temp);
824             return temp;
825         });
826         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
827         [EditorBrowsable(EditorBrowsableState.Never)]
828         public static readonly BindableProperty NameProperty = BindableProperty.Create("Name", typeof(string), typeof(View), string.Empty, propertyChanged: (bindable, oldValue, newValue) =>
829         {
830             var view = (View)bindable;
831             if (newValue != null)
832             {
833                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.NAME, new Tizen.NUI.PropertyValue((string)newValue));
834             }
835         },
836         defaultValueCreator: (bindable) =>
837         {
838             var view = (View)bindable;
839             string temp;
840             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.NAME).Get(out temp);
841             return temp;
842         });
843         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
844         [EditorBrowsable(EditorBrowsableState.Never)]
845         public static readonly BindableProperty SensitiveProperty = BindableProperty.Create("Sensitive", typeof(bool), typeof(View), false, propertyChanged: (bindable, oldValue, newValue) =>
846         {
847             var view = (View)bindable;
848             if (newValue != null)
849             {
850                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.SENSITIVE, new Tizen.NUI.PropertyValue((bool)newValue));
851             }
852         },
853         defaultValueCreator: (bindable) =>
854         {
855             var view = (View)bindable;
856             bool temp = false;
857             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.SENSITIVE).Get(out temp);
858             return temp;
859         });
860         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
861         [EditorBrowsable(EditorBrowsableState.Never)]
862         public static readonly BindableProperty LeaveRequiredProperty = BindableProperty.Create("LeaveRequired", typeof(bool), typeof(View), false, propertyChanged: (bindable, oldValue, newValue) =>
863         {
864             var view = (View)bindable;
865             if (newValue != null)
866             {
867                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.LEAVE_REQUIRED, new Tizen.NUI.PropertyValue((bool)newValue));
868             }
869         },
870         defaultValueCreator: (bindable) =>
871         {
872             var view = (View)bindable;
873             bool temp = false;
874             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.LEAVE_REQUIRED).Get(out temp);
875             return temp;
876         });
877         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
878         [EditorBrowsable(EditorBrowsableState.Never)]
879         public static readonly BindableProperty InheritOrientationProperty = BindableProperty.Create("InheritOrientation", typeof(bool), typeof(View), false, propertyChanged: (bindable, oldValue, newValue) =>
880         {
881             var view = (View)bindable;
882             if (newValue != null)
883             {
884                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.INHERIT_ORIENTATION, new Tizen.NUI.PropertyValue((bool)newValue));
885             }
886         },
887         defaultValueCreator: (bindable) =>
888         {
889             var view = (View)bindable;
890             bool temp = false;
891             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.INHERIT_ORIENTATION).Get(out temp);
892             return temp;
893         });
894         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
895         [EditorBrowsable(EditorBrowsableState.Never)]
896         public static readonly BindableProperty InheritScaleProperty = BindableProperty.Create("InheritScale", typeof(bool), typeof(View), false, propertyChanged: (bindable, oldValue, newValue) =>
897         {
898             var view = (View)bindable;
899             if (newValue != null)
900             {
901                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.INHERIT_SCALE, new Tizen.NUI.PropertyValue((bool)newValue));
902             }
903         },
904         defaultValueCreator: (bindable) =>
905         {
906             var view = (View)bindable;
907             bool temp = false;
908             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.INHERIT_SCALE).Get(out temp);
909             return temp;
910         });
911         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
912         [EditorBrowsable(EditorBrowsableState.Never)]
913         public static readonly BindableProperty DrawModeProperty = BindableProperty.Create("DrawMode", typeof(DrawModeType), typeof(View), DrawModeType.Normal, propertyChanged: (bindable, oldValue, newValue) =>
914         {
915             var view = (View)bindable;
916             if (newValue != null)
917             {
918                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.DRAW_MODE, new Tizen.NUI.PropertyValue((int)newValue));
919             }
920         },
921         defaultValueCreator: (bindable) =>
922         {
923             var view = (View)bindable;
924             string temp;
925             if (Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.DRAW_MODE).Get(out temp) == false)
926             {
927                 NUILog.Error("DrawMode get error!");
928             }
929             switch (temp)
930             {
931                 case "NORMAL": return DrawModeType.Normal;
932                 case "OVERLAY_2D": return DrawModeType.Overlay2D;
933 #pragma warning disable CS0618 // Disable deprecated warning as we do need to use the deprecated API here.
934                 case "STENCIL": return DrawModeType.Stencil;
935 #pragma warning restore CS0618
936                 default: return DrawModeType.Normal;
937             }
938         });
939         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
940         [EditorBrowsable(EditorBrowsableState.Never)]
941         public static readonly BindableProperty SizeModeFactorProperty = BindableProperty.Create("SizeModeFactor", typeof(Vector3), typeof(View), null, propertyChanged: (bindable, oldValue, newValue) =>
942         {
943             var view = (View)bindable;
944             if (newValue != null)
945             {
946                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.SIZE_MODE_FACTOR, new Tizen.NUI.PropertyValue((Vector3)newValue));
947             }
948         },
949         defaultValueCreator: (bindable) =>
950         {
951             var view = (View)bindable;
952             Vector3 temp = new Vector3(0.0f, 0.0f, 0.0f);
953             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.SIZE_MODE_FACTOR).Get(temp);
954             return temp;
955         });
956         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
957         [EditorBrowsable(EditorBrowsableState.Never)]
958         public static readonly BindableProperty WidthResizePolicyProperty = BindableProperty.Create("WidthResizePolicy", typeof(ResizePolicyType), typeof(View), ResizePolicyType.Fixed, propertyChanged: (bindable, oldValue, newValue) =>
959         {
960             var view = (View)bindable;
961             if (newValue != null)
962             {
963                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.WIDTH_RESIZE_POLICY, new Tizen.NUI.PropertyValue((int)newValue));
964             }
965         },
966         defaultValueCreator: (bindable) =>
967         {
968             var view = (View)bindable;
969             string temp;
970             if (Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.WIDTH_RESIZE_POLICY).Get(out temp) == false)
971             {
972                 NUILog.Error("WidthResizePolicy get error!");
973             }
974             switch (temp)
975             {
976                 case "FIXED": return ResizePolicyType.Fixed;
977                 case "USE_NATURAL_SIZE": return ResizePolicyType.UseNaturalSize;
978                 case "FILL_TO_PARENT": return ResizePolicyType.FillToParent;
979                 case "SIZE_RELATIVE_TO_PARENT": return ResizePolicyType.SizeRelativeToParent;
980                 case "SIZE_FIXED_OFFSET_FROM_PARENT": return ResizePolicyType.SizeFixedOffsetFromParent;
981                 case "FIT_TO_CHILDREN": return ResizePolicyType.FitToChildren;
982                 case "DIMENSION_DEPENDENCY": return ResizePolicyType.DimensionDependency;
983                 case "USE_ASSIGNED_SIZE": return ResizePolicyType.UseAssignedSize;
984                 default: return ResizePolicyType.Fixed;
985             }
986         });
987         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
988         [EditorBrowsable(EditorBrowsableState.Never)]
989         public static readonly BindableProperty HeightResizePolicyProperty = BindableProperty.Create("HeightResizePolicy", typeof(ResizePolicyType), typeof(View), ResizePolicyType.Fixed, propertyChanged: (bindable, oldValue, newValue) =>
990         {
991             var view = (View)bindable;
992             if (newValue != null)
993             {
994                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.HEIGHT_RESIZE_POLICY, new Tizen.NUI.PropertyValue((int)newValue));
995             }
996         },
997         defaultValueCreator: (bindable) =>
998         {
999             var view = (View)bindable;
1000             string temp;
1001             if (Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.HEIGHT_RESIZE_POLICY).Get(out temp) == false)
1002             {
1003                 NUILog.Error("HeightResizePolicy get error!");
1004             }
1005             switch (temp)
1006             {
1007                 case "FIXED": return ResizePolicyType.Fixed;
1008                 case "USE_NATURAL_SIZE": return ResizePolicyType.UseNaturalSize;
1009                 case "FILL_TO_PARENT": return ResizePolicyType.FillToParent;
1010                 case "SIZE_RELATIVE_TO_PARENT": return ResizePolicyType.SizeRelativeToParent;
1011                 case "SIZE_FIXED_OFFSET_FROM_PARENT": return ResizePolicyType.SizeFixedOffsetFromParent;
1012                 case "FIT_TO_CHILDREN": return ResizePolicyType.FitToChildren;
1013                 case "DIMENSION_DEPENDENCY": return ResizePolicyType.DimensionDependency;
1014                 case "USE_ASSIGNED_SIZE": return ResizePolicyType.UseAssignedSize;
1015                 default: return ResizePolicyType.Fixed;
1016             }
1017         });
1018         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1019         [EditorBrowsable(EditorBrowsableState.Never)]
1020         public static readonly BindableProperty SizeScalePolicyProperty = BindableProperty.Create("SizeScalePolicy", typeof(SizeScalePolicyType), typeof(View), SizeScalePolicyType.UseSizeSet, propertyChanged: (bindable, oldValue, newValue) =>
1021         {
1022             var view = (View)bindable;
1023             string valueToString = "";
1024             if (newValue != null)
1025             {
1026                 switch ((SizeScalePolicyType)newValue)
1027                 {
1028                     case SizeScalePolicyType.UseSizeSet: { valueToString = "USE_SIZE_SET"; break; }
1029                     case SizeScalePolicyType.FitWithAspectRatio: { valueToString = "FIT_WITH_ASPECT_RATIO"; break; }
1030                     case SizeScalePolicyType.FillWithAspectRatio: { valueToString = "FILL_WITH_ASPECT_RATIO"; break; }
1031                     default: { valueToString = "USE_SIZE_SET"; break; }
1032                 }
1033                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.SIZE_SCALE_POLICY, new Tizen.NUI.PropertyValue(valueToString));
1034             }
1035         },
1036         defaultValueCreator: (bindable) =>
1037         {
1038             var view = (View)bindable;
1039             string temp;
1040             if (Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.SIZE_SCALE_POLICY).Get(out temp) == false)
1041             {
1042                 NUILog.Error("SizeScalePolicy get error!");
1043             }
1044             switch (temp)
1045             {
1046                 case "USE_SIZE_SET": return SizeScalePolicyType.UseSizeSet;
1047                 case "FIT_WITH_ASPECT_RATIO": return SizeScalePolicyType.FitWithAspectRatio;
1048                 case "FILL_WITH_ASPECT_RATIO": return SizeScalePolicyType.FillWithAspectRatio;
1049                 default: return SizeScalePolicyType.UseSizeSet;
1050             }
1051         });
1052         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1053         [EditorBrowsable(EditorBrowsableState.Never)]
1054         public static readonly BindableProperty WidthForHeightProperty = BindableProperty.Create("WidthForHeight", typeof(bool), typeof(View), false, propertyChanged: (bindable, oldValue, newValue) =>
1055         {
1056             var view = (View)bindable;
1057             if (newValue != null)
1058             {
1059                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.WIDTH_FOR_HEIGHT, new Tizen.NUI.PropertyValue((bool)newValue));
1060             }
1061         },
1062         defaultValueCreator: (bindable) =>
1063         {
1064             var view = (View)bindable;
1065             bool temp = false;
1066             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.WIDTH_FOR_HEIGHT).Get(out temp);
1067             return temp;
1068         });
1069         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1070         [EditorBrowsable(EditorBrowsableState.Never)]
1071         public static readonly BindableProperty HeightForWidthProperty = BindableProperty.Create("HeightForWidth", typeof(bool), typeof(View), false, propertyChanged: (bindable, oldValue, newValue) =>
1072         {
1073             var view = (View)bindable;
1074             if (newValue != null)
1075             {
1076                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.HEIGHT_FOR_WIDTH, new Tizen.NUI.PropertyValue((bool)newValue));
1077             }
1078         },
1079         defaultValueCreator: (bindable) =>
1080         {
1081             var view = (View)bindable;
1082             bool temp = false;
1083             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.HEIGHT_FOR_WIDTH).Get(out temp);
1084             return temp;
1085         });
1086         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1087         [EditorBrowsable(EditorBrowsableState.Never)]
1088         public static readonly BindableProperty PaddingProperty = BindableProperty.Create("Padding", typeof(Extents), typeof(View), null, propertyChanged: (bindable, oldValue, newValue) =>
1089         {
1090             var view = (View)bindable;
1091             if (newValue != null)
1092             {
1093                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.PADDING, new Tizen.NUI.PropertyValue((Extents)newValue));
1094             }
1095         },
1096         defaultValueCreator: (bindable) =>
1097         {
1098             var view = (View)bindable;
1099             Extents temp = new Extents(0, 0, 0, 0);
1100             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.PADDING).Get(temp);
1101             return temp;
1102         });
1103         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1104         [EditorBrowsable(EditorBrowsableState.Never)]
1105         public static readonly BindableProperty SizeProperty = BindableProperty.Create("Size", typeof(Size), typeof(View), null, propertyChanged: (bindable, oldValue, newValue) =>
1106         {
1107             var view = (View)bindable;
1108             if (newValue != null)
1109             {
1110                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.SIZE, new Tizen.NUI.PropertyValue((Size)newValue));
1111             }
1112         },
1113         defaultValueCreator: (bindable) =>
1114         {
1115             var view = (View)bindable;
1116             Size temp = new Size(0, 0, 0);
1117             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.SIZE).Get(temp);
1118             return temp;
1119         });
1120         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1121         [EditorBrowsable(EditorBrowsableState.Never)]
1122         public static readonly BindableProperty MinimumSizeProperty = BindableProperty.Create("MinimumSize", typeof(Size2D), typeof(View), null, propertyChanged: (bindable, oldValue, newValue) =>
1123         {
1124             var view = (View)bindable;
1125             if (newValue != null)
1126             {
1127                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.MINIMUM_SIZE, new Tizen.NUI.PropertyValue((Size2D)newValue));
1128             }
1129         },
1130         defaultValueCreator: (bindable) =>
1131         {
1132             var view = (View)bindable;
1133             Size2D temp = new Size2D(0, 0);
1134             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.MINIMUM_SIZE).Get(temp);
1135             return temp;
1136         });
1137         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1138         [EditorBrowsable(EditorBrowsableState.Never)]
1139         public static readonly BindableProperty MaximumSizeProperty = BindableProperty.Create("MaximumSize", typeof(Size2D), typeof(View), null, propertyChanged: (bindable, oldValue, newValue) =>
1140         {
1141             var view = (View)bindable;
1142             if (newValue != null)
1143             {
1144                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.MAXIMUM_SIZE, new Tizen.NUI.PropertyValue((Size2D)newValue));
1145             }
1146         },
1147         defaultValueCreator: (bindable) =>
1148         {
1149             var view = (View)bindable;
1150             Size2D temp = new Size2D(0, 0);
1151             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.MAXIMUM_SIZE).Get(temp);
1152             return temp;
1153         });
1154         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1155         [EditorBrowsable(EditorBrowsableState.Never)]
1156         public static readonly BindableProperty InheritPositionProperty = BindableProperty.Create("InheritPosition", typeof(bool), typeof(View), false, propertyChanged: (bindable, oldValue, newValue) =>
1157         {
1158             var view = (View)bindable;
1159             if (newValue != null)
1160             {
1161                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.INHERIT_POSITION, new Tizen.NUI.PropertyValue((bool)newValue));
1162             }
1163         },
1164         defaultValueCreator: (bindable) =>
1165         {
1166             var view = (View)bindable;
1167             bool temp = false;
1168             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.INHERIT_POSITION).Get(out temp);
1169             return temp;
1170         });
1171         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1172         [EditorBrowsable(EditorBrowsableState.Never)]
1173         public static readonly BindableProperty ClippingModeProperty = BindableProperty.Create("ClippingMode", typeof(ClippingModeType), typeof(View), ClippingModeType.Disabled, propertyChanged: (bindable, oldValue, newValue) =>
1174         {
1175             var view = (View)bindable;
1176             if (newValue != null)
1177             {
1178                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.CLIPPING_MODE, new Tizen.NUI.PropertyValue((int)newValue));
1179             }
1180         },
1181         defaultValueCreator: (bindable) =>
1182         {
1183             var view = (View)bindable;
1184             int temp = 0;
1185             if (Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.CLIPPING_MODE).Get(out temp) == false)
1186             {
1187                 NUILog.Error("ClippingMode get error!");
1188             }
1189             return (ClippingModeType)temp;
1190         });
1191         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1192         [EditorBrowsable(EditorBrowsableState.Never)]
1193         public static readonly BindableProperty InheritLayoutDirectionProperty = BindableProperty.Create("InheritLayoutDirection", typeof(bool), typeof(View), false, propertyChanged: (bindable, oldValue, newValue) =>
1194         {
1195             var view = (View)bindable;
1196             if (newValue != null)
1197             {
1198                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.INHERIT_LAYOUT_DIRECTION, new Tizen.NUI.PropertyValue((bool)newValue));
1199             }
1200         },
1201         defaultValueCreator: (bindable) =>
1202         {
1203             var view = (View)bindable;
1204             bool temp = false;
1205             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.INHERIT_LAYOUT_DIRECTION).Get(out temp);
1206             return temp;
1207         });
1208         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1209         [EditorBrowsable(EditorBrowsableState.Never)]
1210         public static readonly BindableProperty LayoutDirectionProperty = BindableProperty.Create("LayoutDirection", typeof(ViewLayoutDirectionType), typeof(View), ViewLayoutDirectionType.LTR, propertyChanged: (bindable, oldValue, newValue) =>
1211         {
1212             var view = (View)bindable;
1213             if (newValue != null)
1214             {
1215                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.LAYOUT_DIRECTION, new Tizen.NUI.PropertyValue((int)newValue));
1216             }
1217         },
1218         defaultValueCreator: (bindable) =>
1219         {
1220             var view = (View)bindable;
1221             int temp;
1222             if (false == Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.LAYOUT_DIRECTION).Get(out temp))
1223             {
1224                 NUILog.Error("LAYOUT_DIRECTION get error!");
1225             }
1226             return (ViewLayoutDirectionType)temp;
1227         });
1228         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1229         [EditorBrowsable(EditorBrowsableState.Never)]
1230         public static readonly BindableProperty MarginProperty = BindableProperty.Create("Margin", typeof(Extents), typeof(View), null, propertyChanged: (bindable, oldValue, newValue) =>
1231         {
1232             var view = (View)bindable;
1233             if (newValue != null)
1234             {
1235                 Tizen.NUI.Object.SetProperty(view.swigCPtr, View.Property.MARGIN, new Tizen.NUI.PropertyValue((Extents)newValue));
1236             }
1237         },
1238         defaultValueCreator: (bindable) =>
1239         {
1240             var view = (View)bindable;
1241             Extents temp = new Extents(0, 0, 0, 0);
1242             Tizen.NUI.Object.GetProperty(view.swigCPtr, View.Property.MARGIN).Get(temp);
1243             return temp;
1244         });
1245         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1246         [EditorBrowsable(EditorBrowsableState.Never)]
1247         public static readonly BindableProperty StyleProperty = BindableProperty.Create("Style", typeof(Style), typeof(View), default(Style), propertyChanged: (bindable, oldvalue, newvalue) => ((View)bindable)._mergedStyle.Style = (Style)newvalue);
1248
1249         internal readonly MergedStyle _mergedStyle;
1250         /// <summary>
1251         /// Flag to allow Layouting to be disabled for Views.
1252         /// Once a View has a Layout set then any children added to Views from then on will receive
1253         /// automatic Layouts.
1254         /// </summary>
1255         private static bool layoutingDisabled = true;
1256         private global::System.Runtime.InteropServices.HandleRef swigCPtr;
1257
1258         private bool layoutSet = false; // Flag to indicate if SetLayout was called or View was automatically given a Layout
1259         private bool _backgroundImageSynchronosLoading = false;
1260         private EventHandler _offWindowEventHandler;
1261         private OffWindowEventCallbackType _offWindowEventCallback;
1262         private EventHandlerWithReturnType<object, WheelEventArgs, bool> _wheelEventHandler;
1263         private WheelEventCallbackType _wheelEventCallback;
1264         private EventHandlerWithReturnType<object, KeyEventArgs, bool> _keyEventHandler;
1265         private KeyCallbackType _keyCallback;
1266         private EventHandlerWithReturnType<object, TouchEventArgs, bool> _touchDataEventHandler;
1267         private TouchDataCallbackType _touchDataCallback;
1268         private EventHandlerWithReturnType<object, HoverEventArgs, bool> _hoverEventHandler;
1269         private HoverEventCallbackType _hoverEventCallback;
1270         private EventHandler<VisibilityChangedEventArgs> _visibilityChangedEventHandler;
1271         private VisibilityChangedEventCallbackType _visibilityChangedEventCallback;
1272         private EventHandler _keyInputFocusGainedEventHandler;
1273         private KeyInputFocusGainedCallbackType _keyInputFocusGainedCallback;
1274         private EventHandler _keyInputFocusLostEventHandler;
1275         private KeyInputFocusLostCallbackType _keyInputFocusLostCallback;
1276         private EventHandler _onRelayoutEventHandler;
1277         private OnRelayoutEventCallbackType _onRelayoutEventCallback;
1278         private EventHandler _onWindowEventHandler;
1279         private OnWindowEventCallbackType _onWindowEventCallback;
1280         private EventHandler<LayoutDirectionChangedEventArgs> _layoutDirectionChangedEventHandler;
1281         private LayoutDirectionChangedEventCallbackType _layoutDirectionChangedEventCallback;
1282         // Resource Ready Signal
1283         private EventHandler _resourcesLoadedEventHandler;
1284         private ResourcesLoadedCallbackType _ResourcesLoadedCallback;
1285         private EventHandler<BackgroundResourceLoadedEventArgs> _backgroundResourceLoadedEventHandler;
1286         private _backgroundResourceLoadedCallbackType _backgroundResourceLoadedCallback;
1287
1288         private OnWindowEventCallbackType _onWindowSendEventCallback;
1289
1290         private void SendViewAddedEventToWindow(IntPtr data)
1291         {
1292             Window.Instance?.SendViewAdded(this);
1293         }
1294
1295         /// <summary>
1296         /// Creates a new instance of a view.
1297         /// </summary>
1298         /// <since_tizen> 3 </since_tizen>
1299         public View() : this(Interop.View.View_New(), true)
1300         {
1301             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1302         }
1303         internal View(View uiControl) : this(Interop.View.new_View__SWIG_1(View.getCPtr(uiControl)), true)
1304         {
1305             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1306         }
1307
1308         internal View(global::System.IntPtr cPtr, bool cMemoryOwn) : base(Interop.View.View_SWIGUpcast(cPtr), cMemoryOwn)
1309         {
1310             swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
1311             if (HasBody())
1312             {
1313                 PositionUsesPivotPoint = false;
1314             }
1315             _mergedStyle = new MergedStyle(GetType(), this);
1316
1317             _onWindowSendEventCallback = SendViewAddedEventToWindow;
1318             this.OnWindowSignal().Connect(_onWindowSendEventCallback);
1319         }
1320
1321         internal View(ViewImpl implementation) : this(Interop.View.new_View__SWIG_2(ViewImpl.getCPtr(implementation)), true)
1322         {
1323             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
1324         }
1325
1326         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
1327         private delegate void OffWindowEventCallbackType(IntPtr control);
1328         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
1329         private delegate bool WheelEventCallbackType(IntPtr view, IntPtr wheelEvent);
1330         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
1331         private delegate bool KeyCallbackType(IntPtr control, IntPtr keyEvent);
1332         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
1333         private delegate bool TouchDataCallbackType(IntPtr view, IntPtr touchData);
1334         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
1335         private delegate bool HoverEventCallbackType(IntPtr view, IntPtr hoverEvent);
1336         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
1337         private delegate void VisibilityChangedEventCallbackType(IntPtr data, bool visibility, VisibilityChangeType type);
1338         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
1339         private delegate void ResourcesLoadedCallbackType(IntPtr control);
1340         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
1341         private delegate void _backgroundResourceLoadedCallbackType(IntPtr view);
1342         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
1343         private delegate void KeyInputFocusGainedCallbackType(IntPtr control);
1344         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
1345         private delegate void KeyInputFocusLostCallbackType(IntPtr control);
1346         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
1347         private delegate void OnRelayoutEventCallbackType(IntPtr control);
1348         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
1349         private delegate void OnWindowEventCallbackType(IntPtr control);
1350         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
1351         private delegate void LayoutDirectionChangedEventCallbackType(IntPtr data, ViewLayoutDirectionType type);
1352
1353         /// <summary>
1354         /// Event when a child is removed.
1355         /// </summary>
1356         /// <since_tizen> 5 </since_tizen>
1357         public new event EventHandler<ChildRemovedEventArgs> ChildRemoved;
1358         /// <summary>
1359         /// Event when a child is added.
1360         /// </summary>
1361         /// <since_tizen> 5 </since_tizen>
1362         public new event EventHandler<ChildAddedEventArgs> ChildAdded;
1363
1364         /// <summary>
1365         /// An event for the KeyInputFocusGained signal which can be used to subscribe or unsubscribe the event handler provided by the user.<br />
1366         /// The KeyInputFocusGained signal is emitted when the control gets the key input focus.<br />
1367         /// </summary>
1368         /// <since_tizen> 3 </since_tizen>
1369         public event EventHandler FocusGained
1370         {
1371             add
1372             {
1373                 if (_keyInputFocusGainedEventHandler == null)
1374                 {
1375                     _keyInputFocusGainedCallback = OnKeyInputFocusGained;
1376                     this.KeyInputFocusGainedSignal().Connect(_keyInputFocusGainedCallback);
1377                 }
1378
1379                 _keyInputFocusGainedEventHandler += value;
1380             }
1381
1382             remove
1383             {
1384                 _keyInputFocusGainedEventHandler -= value;
1385
1386                 if (_keyInputFocusGainedEventHandler == null && KeyInputFocusGainedSignal().Empty() == false)
1387                 {
1388                     this.KeyInputFocusGainedSignal().Disconnect(_keyInputFocusGainedCallback);
1389                 }
1390             }
1391         }
1392
1393         /// <summary>
1394         /// An event for the KeyInputFocusLost signal which can be used to subscribe or unsubscribe the event handler provided by the user.<br />
1395         /// The KeyInputFocusLost signal is emitted when the control loses the key input focus.<br />
1396         /// </summary>
1397         /// <since_tizen> 3 </since_tizen>
1398         public event EventHandler FocusLost
1399         {
1400             add
1401             {
1402                 if (_keyInputFocusLostEventHandler == null)
1403                 {
1404                     _keyInputFocusLostCallback = OnKeyInputFocusLost;
1405                     this.KeyInputFocusLostSignal().Connect(_keyInputFocusLostCallback);
1406                 }
1407
1408                 _keyInputFocusLostEventHandler += value;
1409             }
1410
1411             remove
1412             {
1413                 _keyInputFocusLostEventHandler -= value;
1414
1415                 if (_keyInputFocusLostEventHandler == null && KeyInputFocusLostSignal().Empty() == false)
1416                 {
1417                     this.KeyInputFocusLostSignal().Disconnect(_keyInputFocusLostCallback);
1418                 }
1419             }
1420         }
1421
1422         /// <summary>
1423         /// An event for the KeyPressed signal which can be used to subscribe or unsubscribe the event handler provided by the user.<br />
1424         /// The KeyPressed signal is emitted when the key event is received.<br />
1425         /// </summary>
1426         /// <since_tizen> 3 </since_tizen>
1427         public event EventHandlerWithReturnType<object, KeyEventArgs, bool> KeyEvent
1428         {
1429             add
1430             {
1431                 if (_keyEventHandler == null)
1432                 {
1433                     _keyCallback = OnKeyEvent;
1434                     this.KeyEventSignal().Connect(_keyCallback);
1435                 }
1436
1437                 _keyEventHandler += value;
1438             }
1439
1440             remove
1441             {
1442                 _keyEventHandler -= value;
1443
1444                 if (_keyEventHandler == null && KeyEventSignal().Empty() == false)
1445                 {
1446                     this.KeyEventSignal().Disconnect(_keyCallback);
1447                 }
1448             }
1449         }
1450
1451         /// <summary>
1452         /// An event for the OnRelayout signal which can be used to subscribe or unsubscribe the event handler.<br />
1453         /// The OnRelayout signal is emitted after the size has been set on the view during relayout.<br />
1454         /// </summary>
1455         /// <since_tizen> 3 </since_tizen>
1456         public event EventHandler Relayout
1457         {
1458             add
1459             {
1460                 if (_onRelayoutEventHandler == null)
1461                 {
1462                     _onRelayoutEventCallback = OnRelayout;
1463                     this.OnRelayoutSignal().Connect(_onRelayoutEventCallback);
1464                 }
1465
1466                 _onRelayoutEventHandler += value;
1467             }
1468
1469             remove
1470             {
1471                 _onRelayoutEventHandler -= value;
1472
1473                 if (_onRelayoutEventHandler == null && OnRelayoutSignal().Empty() == false)
1474                 {
1475                     this.OnRelayoutSignal().Disconnect(_onRelayoutEventCallback);
1476                 }
1477
1478             }
1479         }
1480
1481         /// <summary>
1482         /// An event for the touched signal which can be used to subscribe or unsubscribe the event handler provided by the user.<br />
1483         /// The touched signal is emitted when the touch input is received.<br />
1484         /// </summary>
1485         /// <since_tizen> 3 </since_tizen>
1486         public event EventHandlerWithReturnType<object, TouchEventArgs, bool> TouchEvent
1487         {
1488             add
1489             {
1490                 if (_touchDataEventHandler == null)
1491                 {
1492                     _touchDataCallback = OnTouch;
1493                     this.TouchSignal().Connect(_touchDataCallback);
1494                 }
1495
1496                 _touchDataEventHandler += value;
1497             }
1498
1499             remove
1500             {
1501                 _touchDataEventHandler -= value;
1502
1503                 if (_touchDataEventHandler == null && TouchSignal().Empty() == false)
1504                 {
1505                     this.TouchSignal().Disconnect(_touchDataCallback);
1506                 }
1507
1508             }
1509         }
1510
1511         /// <summary>
1512         /// An event for the hovered signal which can be used to subscribe or unsubscribe the event handler provided by the user.<br />
1513         /// The hovered signal is emitted when the hover input is received.<br />
1514         /// </summary>
1515         /// <since_tizen> 3 </since_tizen>
1516         public event EventHandlerWithReturnType<object, HoverEventArgs, bool> HoverEvent
1517         {
1518             add
1519             {
1520                 if (_hoverEventHandler == null)
1521                 {
1522                     _hoverEventCallback = OnHoverEvent;
1523                     this.HoveredSignal().Connect(_hoverEventCallback);
1524                 }
1525
1526                 _hoverEventHandler += value;
1527             }
1528
1529             remove
1530             {
1531                 _hoverEventHandler -= value;
1532
1533                 if (_hoverEventHandler == null && HoveredSignal().Empty() == false)
1534                 {
1535                     this.HoveredSignal().Disconnect(_hoverEventCallback);
1536                 }
1537
1538             }
1539         }
1540
1541         /// <summary>
1542         /// An event for the WheelMoved signal which can be used to subscribe or unsubscribe the event handler provided by the user.<br />
1543         /// The WheelMoved signal is emitted when the wheel event is received.<br />
1544         /// </summary>
1545         /// <since_tizen> 3 </since_tizen>
1546         public event EventHandlerWithReturnType<object, WheelEventArgs, bool> WheelEvent
1547         {
1548             add
1549             {
1550                 if (_wheelEventHandler == null)
1551                 {
1552                     _wheelEventCallback = OnWheelEvent;
1553                     this.WheelEventSignal().Connect(_wheelEventCallback);
1554                 }
1555
1556                 _wheelEventHandler += value;
1557             }
1558
1559             remove
1560             {
1561                 _wheelEventHandler -= value;
1562
1563                 if (_wheelEventHandler == null && WheelEventSignal().Empty() == false)
1564                 {
1565                     this.WheelEventSignal().Disconnect(_wheelEventCallback);
1566                 }
1567
1568             }
1569         }
1570
1571         /// <summary>
1572         /// An event for the OnWindow signal which can be used to subscribe or unsubscribe the event handler.<br />
1573         /// The OnWindow signal is emitted after the view has been connected to the window.<br />
1574         /// </summary>
1575         /// <since_tizen> 3 </since_tizen>
1576         public event EventHandler AddedToWindow
1577         {
1578             add
1579             {
1580                 if (_onWindowEventHandler == null)
1581                 {
1582                     _onWindowEventCallback = OnWindow;
1583                     this.OnWindowSignal().Connect(_onWindowEventCallback);
1584                 }
1585
1586                 _onWindowEventHandler += value;
1587             }
1588
1589             remove
1590             {
1591                 _onWindowEventHandler -= value;
1592
1593                 if (_onWindowEventHandler == null && OnWindowSignal().Empty() == false)
1594                 {
1595                     this.OnWindowSignal().Disconnect(_onWindowEventCallback);
1596                 }
1597             }
1598         }
1599
1600         /// <summary>
1601         /// An event for the OffWindow signal, which can be used to subscribe or unsubscribe the event handler.<br />
1602         /// OffWindow signal is emitted after the view has been disconnected from the window.<br />
1603         /// </summary>
1604         /// <since_tizen> 3 </since_tizen>
1605         public event EventHandler RemovedFromWindow
1606         {
1607             add
1608             {
1609                 if (_offWindowEventHandler == null)
1610                 {
1611                     _offWindowEventCallback = OffWindow;
1612                     this.OffWindowSignal().Connect(_offWindowEventCallback);
1613                 }
1614
1615                 _offWindowEventHandler += value;
1616             }
1617
1618             remove
1619             {
1620                 _offWindowEventHandler -= value;
1621
1622                 if (_offWindowEventHandler == null && OffWindowSignal().Empty() == false)
1623                 {
1624                     this.OffWindowSignal().Disconnect(_offWindowEventCallback);
1625                 }
1626             }
1627         }
1628
1629         /// <summary>
1630         /// An event for visibility change which can be used to subscribe or unsubscribe the event handler.<br />
1631         /// This signal is emitted when the visible property of this or a parent view is changed.<br />
1632         /// </summary>
1633         /// <since_tizen> 3 </since_tizen>
1634         public event EventHandler<VisibilityChangedEventArgs> VisibilityChanged
1635         {
1636             add
1637             {
1638                 if (_visibilityChangedEventHandler == null)
1639                 {
1640                     _visibilityChangedEventCallback = OnVisibilityChanged;
1641                     VisibilityChangedSignal(this).Connect(_visibilityChangedEventCallback);
1642                 }
1643
1644                 _visibilityChangedEventHandler += value;
1645             }
1646
1647             remove
1648             {
1649                 _visibilityChangedEventHandler -= value;
1650
1651                 if (_visibilityChangedEventHandler == null && VisibilityChangedSignal(this).Empty() == false)
1652                 {
1653                     VisibilityChangedSignal(this).Disconnect(_visibilityChangedEventCallback);
1654                 }
1655             }
1656         }
1657
1658         /// <summary>
1659         /// Event for layout direction change which can be used to subscribe/unsubscribe the event handler.<br />
1660         /// This signal is emitted when the layout direction property of this or a parent view is changed.<br />
1661         /// </summary>
1662         /// <since_tizen> 4 </since_tizen>
1663         public event EventHandler<LayoutDirectionChangedEventArgs> LayoutDirectionChanged
1664         {
1665             add
1666             {
1667                 if (_layoutDirectionChangedEventHandler == null)
1668                 {
1669                     _layoutDirectionChangedEventCallback = OnLayoutDirectionChanged;
1670                     LayoutDirectionChangedSignal(this).Connect(_layoutDirectionChangedEventCallback);
1671                 }
1672
1673                 _layoutDirectionChangedEventHandler += value;
1674             }
1675
1676             remove
1677             {
1678                 _layoutDirectionChangedEventHandler -= value;
1679
1680                 if (_layoutDirectionChangedEventHandler == null && LayoutDirectionChangedSignal(this).Empty() == false)
1681                 {
1682                     LayoutDirectionChangedSignal(this).Disconnect(_layoutDirectionChangedEventCallback);
1683                 }
1684             }
1685         }
1686
1687         /// <summary>
1688         /// An event for the ResourcesLoadedSignal signal which can be used to subscribe or unsubscribe the event handler provided by the user.<br />
1689         /// This signal is emitted after all resources required by a view are loaded and ready.<br />
1690         /// </summary>
1691         /// <since_tizen> 3 </since_tizen>
1692         public event EventHandler ResourcesLoaded
1693         {
1694             add
1695             {
1696                 if (_resourcesLoadedEventHandler == null)
1697                 {
1698                     _ResourcesLoadedCallback = OnResourcesLoaded;
1699                     this.ResourcesLoadedSignal().Connect(_ResourcesLoadedCallback);
1700                 }
1701
1702                 _resourcesLoadedEventHandler += value;
1703             }
1704
1705             remove
1706             {
1707                 _resourcesLoadedEventHandler -= value;
1708
1709                 if (_resourcesLoadedEventHandler == null && ResourcesLoadedSignal().Empty() == false)
1710                 {
1711                     this.ResourcesLoadedSignal().Disconnect(_ResourcesLoadedCallback);
1712                 }
1713             }
1714         }
1715
1716         internal event EventHandler<BackgroundResourceLoadedEventArgs> BackgroundResourceLoaded
1717         {
1718             add
1719             {
1720                 if (_backgroundResourceLoadedEventHandler == null)
1721                 {
1722                     _backgroundResourceLoadedCallback = OnBackgroundResourceLoaded;
1723                     this.ResourcesLoadedSignal().Connect(_backgroundResourceLoadedCallback);
1724                 }
1725
1726                 _backgroundResourceLoadedEventHandler += value;
1727             }
1728             remove
1729             {
1730                 _backgroundResourceLoadedEventHandler -= value;
1731
1732                 if (_backgroundResourceLoadedEventHandler == null && ResourcesLoadedSignal().Empty() == false)
1733                 {
1734                     this.ResourcesLoadedSignal().Disconnect(_backgroundResourceLoadedCallback);
1735                 }
1736             }
1737         }
1738
1739         /// <summary>
1740         /// Enumeration for describing the states of the view.
1741         /// </summary>
1742         /// <since_tizen> 3 </since_tizen>
1743         public enum States
1744         {
1745             /// <summary>
1746             /// The normal state.
1747             /// </summary>
1748             Normal,
1749             /// <summary>
1750             /// The focused state.
1751             /// </summary>
1752             Focused,
1753             /// <summary>
1754             /// The disabled state.
1755             /// </summary>
1756             Disabled
1757         }
1758
1759         /// <summary>
1760         /// Describes the direction to move the focus towards.
1761         /// </summary>
1762         /// <since_tizen> 3 </since_tizen>
1763         public enum FocusDirection
1764         {
1765             /// <summary>
1766             /// Move keyboard focus towards the left direction.
1767             /// </summary>
1768             /// <since_tizen> 3 </since_tizen>
1769             Left,
1770             /// <summary>
1771             /// Move keyboard focus towards the right direction.
1772             /// </summary>
1773             /// <since_tizen> 3 </since_tizen>
1774             Right,
1775             /// <summary>
1776             /// Move keyboard focus towards the up direction.
1777             /// </summary>
1778             /// <since_tizen> 3 </since_tizen>
1779             Up,
1780             /// <summary>
1781             /// Move keyboard focus towards the down direction.
1782             /// </summary>
1783             /// <since_tizen> 3 </since_tizen>
1784             Down,
1785             /// <summary>
1786             /// Move keyboard focus towards the previous page direction.
1787             /// </summary>
1788             /// <since_tizen> 3 </since_tizen>
1789             PageUp,
1790             /// <summary>
1791             /// Move keyboard focus towards the next page direction.
1792             /// </summary>
1793             /// <since_tizen> 3 </since_tizen>
1794             PageDown
1795         }
1796
1797         internal enum PropertyRange
1798         {
1799             PROPERTY_START_INDEX = PropertyRanges.PROPERTY_REGISTRATION_START_INDEX,
1800             CONTROL_PROPERTY_START_INDEX = PROPERTY_START_INDEX,
1801             CONTROL_PROPERTY_END_INDEX = CONTROL_PROPERTY_START_INDEX + 1000
1802         }
1803
1804         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1805         [EditorBrowsable(EditorBrowsableState.Never)]
1806         public bool IsResourcesCreated
1807         {
1808             get
1809             {
1810                 return Application.Current.IsResourcesCreated;
1811             }
1812         }
1813
1814         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1815         [EditorBrowsable(EditorBrowsableState.Never)]
1816         public ResourceDictionary XamlResources
1817         {
1818             get
1819             {
1820                 return Application.Current.XamlResources;
1821             }
1822             set
1823             {
1824                 Application.Current.XamlResources = value;
1825             }
1826         }
1827
1828         /// <summary>
1829         /// The StyleName, type string.
1830         /// </summary>
1831         /// <since_tizen> 3 </since_tizen>
1832         public string StyleName
1833         {
1834             get
1835             {
1836                 return (string)GetValue(StyleNameProperty);
1837             }
1838             set
1839             {
1840                 SetValue(StyleNameProperty, value);
1841                 NotifyPropertyChanged();
1842             }
1843         }
1844
1845         /// <summary>
1846         /// The mutually exclusive with BACKGROUND_IMAGE and BACKGROUND type Vector4.
1847         /// </summary>
1848         /// <since_tizen> 3 </since_tizen>
1849         public Color BackgroundColor
1850         {
1851             get
1852             {
1853                 return (Color)GetValue(BackgroundColorProperty);
1854             }
1855             set
1856             {
1857                 SetValue(BackgroundColorProperty, value);
1858                 NotifyPropertyChanged();
1859             }
1860         }
1861
1862         /// <summary>
1863         /// The mutually exclusive with BACKGROUND_COLOR and BACKGROUND type Map.
1864         /// </summary>
1865         /// <since_tizen> 3 </since_tizen>
1866         public string BackgroundImage
1867         {
1868             get
1869             {
1870                 return (string)GetValue(BackgroundImageProperty);
1871             }
1872             set
1873             {
1874                 SetValue(BackgroundImageProperty, value);
1875                 NotifyPropertyChanged();
1876             }
1877         }
1878
1879         /// <summary>
1880         /// The background of view.
1881         /// </summary>
1882         /// <since_tizen> 3 </since_tizen>
1883         public Tizen.NUI.PropertyMap Background
1884         {
1885             get
1886             {
1887                 return (PropertyMap)GetValue(BackgroundProperty);
1888             }
1889             set
1890             {
1891                 SetValue(BackgroundProperty, value);
1892                 NotifyPropertyChanged();
1893             }
1894         }
1895
1896
1897         /// <summary>
1898         /// The current state of the view.
1899         /// </summary>
1900         /// <since_tizen> 3 </since_tizen>
1901         public States State
1902         {
1903             get
1904             {
1905                 return (States)GetValue(StateProperty);
1906             }
1907             set
1908             {
1909                 SetValue(StateProperty, value);
1910                 NotifyPropertyChanged();
1911             }
1912         }
1913
1914         /// <summary>
1915         /// The current sub state of the view.
1916         /// </summary>
1917         /// <since_tizen> 3 </since_tizen>
1918         public States SubState
1919         {
1920             get
1921             {
1922                 return (States)GetValue(SubStateProperty);
1923             }
1924             set
1925             {
1926                 SetValue(SubStateProperty, value);
1927                 NotifyPropertyChanged();
1928             }
1929         }
1930
1931         /// <summary>
1932         /// Displays a tooltip
1933         /// </summary>
1934         /// <since_tizen> 3 </since_tizen>
1935         public Tizen.NUI.PropertyMap Tooltip
1936         {
1937             get
1938             {
1939                 return (PropertyMap)GetValue(TooltipProperty);
1940             }
1941             set
1942             {
1943                 SetValue(TooltipProperty, value);
1944                 NotifyPropertyChanged();
1945             }
1946         }
1947
1948         /// <summary>
1949         /// Displays a tooltip as a text.
1950         /// </summary>
1951         /// <since_tizen> 3 </since_tizen>
1952         public string TooltipText
1953         {
1954             set
1955             {
1956                 SetProperty(View.Property.TOOLTIP, new Tizen.NUI.PropertyValue(value));
1957                 NotifyPropertyChanged();
1958             }
1959         }
1960
1961         /// <summary>
1962         /// The Child property of FlexContainer.<br />
1963         /// The proportion of the free space in the container, the flex item will receive.<br />
1964         /// If all items in the container set this property, their sizes will be proportional to the specified flex factor.<br />
1965         /// </summary>
1966         /// <since_tizen> 3 </since_tizen>
1967         public float Flex
1968         {
1969             get
1970             {
1971                 return (float)GetValue(FlexProperty);
1972             }
1973             set
1974             {
1975                 SetValue(FlexProperty, value);
1976                 NotifyPropertyChanged();
1977             }
1978         }
1979
1980         /// <summary>
1981         /// The Child property of FlexContainer.<br />
1982         /// The alignment of the flex item along the cross axis, which, if set, overides the default alignment for all items in the container.<br />
1983         /// </summary>
1984         /// <since_tizen> 3 </since_tizen>
1985         public int AlignSelf
1986         {
1987             get
1988             {
1989                 return (int)GetValue(AlignSelfProperty);
1990             }
1991             set
1992             {
1993                 SetValue(AlignSelfProperty, value);
1994                 NotifyPropertyChanged();
1995             }
1996         }
1997
1998         /// <summary>
1999         /// The Child property of FlexContainer.<br />
2000         /// The space around the flex item.<br />
2001         /// </summary>
2002         /// <since_tizen> 3 </since_tizen>
2003         public Vector4 FlexMargin
2004         {
2005             get
2006             {
2007                 return (Vector4)GetValue(FlexMarginProperty);
2008             }
2009             set
2010             {
2011                 SetValue(FlexMarginProperty, value);
2012                 NotifyPropertyChanged();
2013             }
2014         }
2015
2016         /// <summary>
2017         /// The top-left cell this child occupies, if not set, the first available cell is used.
2018         /// </summary>
2019         /// <since_tizen> 3 </since_tizen>
2020         public Vector2 CellIndex
2021         {
2022             get
2023             {
2024                 return (Vector2)GetValue(CellIndexProperty);
2025             }
2026             set
2027             {
2028                 SetValue(CellIndexProperty, value);
2029                 NotifyPropertyChanged();
2030             }
2031         }
2032
2033         /// <summary>
2034         /// The number of rows this child occupies, if not set, the default value is 1.
2035         /// </summary>
2036         /// <since_tizen> 3 </since_tizen>
2037         public float RowSpan
2038         {
2039             get
2040             {
2041                 return (float)GetValue(RowSpanProperty);
2042             }
2043             set
2044             {
2045                 SetValue(RowSpanProperty, value);
2046                 NotifyPropertyChanged();
2047             }
2048         }
2049
2050         /// <summary>
2051         /// The number of columns this child occupies, if not set, the default value is 1.
2052         /// </summary>
2053         /// <since_tizen> 3 </since_tizen>
2054         public float ColumnSpan
2055         {
2056             get
2057             {
2058                 return (float)GetValue(ColumnSpanProperty);
2059             }
2060             set
2061             {
2062                 SetValue(ColumnSpanProperty, value);
2063                 NotifyPropertyChanged();
2064             }
2065         }
2066
2067         /// <summary>
2068         /// The horizontal alignment of this child inside the cells, if not set, the default value is 'left'.
2069         /// </summary>
2070         /// <since_tizen> 3 </since_tizen>
2071         public Tizen.NUI.HorizontalAlignmentType CellHorizontalAlignment
2072         {
2073             get
2074             {
2075                 return (HorizontalAlignmentType)GetValue(CellHorizontalAlignmentProperty);
2076             }
2077             set
2078             {
2079                 SetValue(CellHorizontalAlignmentProperty, value);
2080                 NotifyPropertyChanged();
2081             }
2082         }
2083
2084         /// <summary>
2085         /// The vertical alignment of this child inside the cells, if not set, the default value is 'top'.
2086         /// </summary>
2087         /// <since_tizen> 3 </since_tizen>
2088         public Tizen.NUI.VerticalAlignmentType CellVerticalAlignment
2089         {
2090             get
2091             {
2092                 return (VerticalAlignmentType)GetValue(CellVerticalAlignmentProperty);
2093             }
2094             set
2095             {
2096                 SetValue(CellVerticalAlignmentProperty, value);
2097                 NotifyPropertyChanged();
2098             }
2099         }
2100
2101         /// <summary>
2102         /// The left focusable view.<br />
2103         /// This will return null if not set.<br />
2104         /// This will also return null if the specified left focusable view is not on a window.<br />
2105         /// </summary>
2106         /// <since_tizen> 3 </since_tizen>
2107         public View LeftFocusableView
2108         {
2109             // As native side will be only storing IDs so need a logic to convert View to ID and vice-versa.
2110             get
2111             {
2112                 return (View)GetValue(LeftFocusableViewProperty);
2113             }
2114             set
2115             {
2116                 SetValue(LeftFocusableViewProperty, value);
2117                 NotifyPropertyChanged();
2118             }
2119         }
2120
2121         /// <summary>
2122         /// The right focusable view.<br />
2123         /// This will return null if not set.<br />
2124         /// This will also return null if the specified right focusable view is not on a window.<br />
2125         /// </summary>
2126         /// <since_tizen> 3 </since_tizen>
2127         public View RightFocusableView
2128         {
2129             // As native side will be only storing IDs so need a logic to convert View to ID and vice-versa.
2130             get
2131             {
2132                 return (View)GetValue(RightFocusableViewProperty);
2133             }
2134             set
2135             {
2136                 SetValue(RightFocusableViewProperty, value);
2137                 NotifyPropertyChanged();
2138             }
2139         }
2140
2141         /// <summary>
2142         /// The up focusable view.<br />
2143         /// This will return null if not set.<br />
2144         /// This will also return null if the specified up focusable view is not on a window.<br />
2145         /// </summary>
2146         /// <since_tizen> 3 </since_tizen>
2147         public View UpFocusableView
2148         {
2149             // As native side will be only storing IDs so need a logic to convert View to ID and vice-versa.
2150             get
2151             {
2152                 return (View)GetValue(UpFocusableViewProperty);
2153             }
2154             set
2155             {
2156                 SetValue(UpFocusableViewProperty, value);
2157                 NotifyPropertyChanged();
2158             }
2159         }
2160
2161         /// <summary>
2162         /// The down focusable view.<br />
2163         /// This will return null if not set.<br />
2164         /// This will also return null if the specified down focusable view is not on a window.<br />
2165         /// </summary>
2166         /// <since_tizen> 3 </since_tizen>
2167         public View DownFocusableView
2168         {
2169             // As native side will be only storing IDs so need a logic to convert View to ID and vice-versa.
2170             get
2171             {
2172                 return (View)GetValue(DownFocusableViewProperty);
2173             }
2174             set
2175             {
2176                 SetValue(DownFocusableViewProperty, value);
2177                 NotifyPropertyChanged();
2178             }
2179         }
2180
2181         /// <summary>
2182         /// Whether the view should be focusable by keyboard navigation.
2183         /// </summary>
2184         /// <since_tizen> 3 </since_tizen>
2185         public bool Focusable
2186         {
2187             set
2188             {
2189                 SetValue(FocusableProperty, value);
2190                 NotifyPropertyChanged();
2191             }
2192             get
2193             {
2194                 return (bool)GetValue(FocusableProperty);
2195             }
2196         }
2197
2198         /// <summary>
2199         ///  Retrieves the position of the view.<br />
2200         ///  The coordinates are relative to the view's parent.<br />
2201         /// </summary>
2202         /// <since_tizen> 3 </since_tizen>
2203         public Position CurrentPosition
2204         {
2205             get
2206             {
2207                 return GetCurrentPosition();
2208             }
2209         }
2210
2211         /// <summary>
2212         /// Sets the size of a view for the width and the height.<br />
2213         /// Geometry can be scaled to fit within this area.<br />
2214         /// This does not interfere with the view's scale factor.<br />
2215         /// The views default depth is the minimum of width and height.<br />
2216         /// </summary>
2217         /// <remarks>
2218         /// This NUI object (Size2D) typed property can be configured by multiple cascade setting. <br />
2219         /// For example, this code ( view.Size2D.Width = 100; view.Size2D.Height = 100; ) is equivalent to this ( view.Size2D = new Size2D(100, 100); ). <br />
2220         /// Please note that this multi-cascade setting is especially possible for this NUI object (Size2D). <br />
2221         /// This means by default others are impossible so it is recommended that NUI object typed properties are configured by their constructor with parameters. <br />
2222         /// For example, this code is working fine : view.Scale = new Vector3( 2.0f, 1.5f, 0.0f); <br />
2223         /// but this will not work! : view.Scale.X = 2.0f; view.Scale.Y = 1.5f; <br />
2224         /// It may not match the current value in some cases, i.e. when the animation is progressing or the maximum or minimu size is set. <br />
2225         /// </remarks>
2226         /// <since_tizen> 3 </since_tizen>
2227         public Size2D Size2D
2228         {
2229             get
2230             {
2231                 Size2D temp = (Size2D)GetValue(Size2DProperty);
2232                 return new Size2D(OnSize2DChanged, temp.Width, temp.Height);
2233             }
2234             set
2235             {
2236                 SetValue(Size2DProperty, value);
2237                 // Set Specification so when layouts measure this View it matches the value set here.
2238                 // All Views are currently Layouts.
2239                 SetProperty(LayoutItemWrapper.ChildProperty.WIDTH_SPECIFICATION, new Tizen.NUI.PropertyValue(value.Width));
2240                 SetProperty(LayoutItemWrapper.ChildProperty.HEIGHT_SPECIFICATION, new Tizen.NUI.PropertyValue(value.Height));
2241                 NotifyPropertyChanged();
2242             }
2243         }
2244
2245         /// <summary>
2246         ///  Retrieves the size of the view.<br />
2247         ///  The coordinates are relative to the view's parent.<br />
2248         /// </summary>
2249         /// <since_tizen> 3 </since_tizen>
2250         public Size2D CurrentSize
2251         {
2252             get
2253             {
2254                 return GetCurrentSize();
2255             }
2256         }
2257
2258         /// <summary>
2259         /// Retrieves and sets the view's opacity.<br />
2260         /// </summary>
2261         /// <since_tizen> 3 </since_tizen>
2262         public float Opacity
2263         {
2264             get
2265             {
2266                 return (float)GetValue(OpacityProperty);
2267             }
2268             set
2269             {
2270                 SetValue(OpacityProperty, value);
2271                 NotifyPropertyChanged();
2272             }
2273         }
2274
2275         /// <summary>
2276         /// Sets the position of the view for X and Y.<br />
2277         /// By default, sets the position vector between the parent origin and the pivot point (default).<br />
2278         /// If the position inheritance is disabled, sets the world position.<br />
2279         /// </summary>
2280         /// <remarks>
2281         /// This NUI object (Position2D) typed property can be configured by multiple cascade setting. <br />
2282         /// For example, this code ( view.Position2D.X = 100; view.Position2D.Y = 100; ) is equivalent to this ( view.Position2D = new Position2D(100, 100); ). <br />
2283         /// Please note that this multi-cascade setting is especially possible for this NUI object (Position2D). <br />
2284         /// This means by default others are impossible so it is recommended that NUI object typed properties are configured by their constructor with parameters. <br />
2285         /// For example, this code is working fine : view.Scale = new Vector3( 2.0f, 1.5f, 0.0f); <br />
2286         /// but this will not work! : view.Scale.X = 2.0f; view.Scale.Y = 1.5f; <br />
2287         /// </remarks>
2288         /// <since_tizen> 3 </since_tizen>
2289         public Position2D Position2D
2290         {
2291             get
2292             {
2293                 Position2D temp = (Position2D)GetValue(Position2DProperty);
2294                 return new Position2D(OnPosition2DChanged, temp.X, temp.Y);
2295             }
2296             set
2297             {
2298                 SetValue(Position2DProperty, value);
2299                 NotifyPropertyChanged();
2300             }
2301         }
2302
2303         /// <summary>
2304         /// Retrieves the screen postion of the view.<br />
2305         /// </summary>
2306         /// <since_tizen> 3 </since_tizen>
2307         public Vector2 ScreenPosition
2308         {
2309             get
2310             {
2311                 Vector2 temp = new Vector2(0.0f, 0.0f);
2312                 GetProperty(View.Property.SCREEN_POSITION).Get(temp);
2313                 return temp;
2314             }
2315         }
2316
2317         /// <summary>
2318         /// Determines whether the pivot point should be used to determine the position of the view.
2319         /// This is true by default.
2320         /// </summary>
2321         /// <remarks>If false, then the top-left of the view is used for the position.
2322         /// Setting this to false will allow scaling or rotation around the anchor-point without affecting the view's position.
2323         /// </remarks>
2324         /// <since_tizen> 3 </since_tizen>
2325         public bool PositionUsesPivotPoint
2326         {
2327             get
2328             {
2329                 return (bool)GetValue(PositionUsesPivotPointProperty);
2330             }
2331             set
2332             {
2333                 SetValue(PositionUsesPivotPointProperty, value);
2334                 NotifyPropertyChanged();
2335             }
2336         }
2337
2338         /// <summary>
2339         /// Please do not use! this will be deprecated.
2340         /// </summary>
2341         /// Please do not use! this will be deprecated!
2342         /// Instead please use PositionUsesPivotPoint.
2343         /// <since_tizen> 3 </since_tizen>
2344         [Obsolete("Please do not use! This will be deprecated! Please use PositionUsesPivotPoint instead! " +
2345             "Like: " +
2346             "View view = new View(); " +
2347             "view.PivotPoint = PivotPoint.Center; " +
2348             "view.PositionUsesPivotPoint = true;")]
2349         [EditorBrowsable(EditorBrowsableState.Never)]
2350         public bool PositionUsesAnchorPoint
2351         {
2352             get
2353             {
2354                 bool temp = false;
2355                 GetProperty(View.Property.POSITION_USES_ANCHOR_POINT).Get(out temp);
2356                 return temp;
2357             }
2358             set
2359             {
2360                 SetProperty(View.Property.POSITION_USES_ANCHOR_POINT, new Tizen.NUI.PropertyValue(value));
2361                 NotifyPropertyChanged();
2362             }
2363         }
2364
2365         /// <summary>
2366         /// Queries whether the view is connected to the stage.<br />
2367         /// When a view is connected, it will be directly or indirectly parented to the root view.<br />
2368         /// </summary>
2369         /// <since_tizen> 3 </since_tizen>
2370         public bool IsOnWindow
2371         {
2372             get
2373             {
2374                 return OnWindow();
2375             }
2376         }
2377
2378         /// <summary>
2379         /// Gets the depth in the hierarchy for the view.
2380         /// </summary>
2381         /// <since_tizen> 3 </since_tizen>
2382         public int HierarchyDepth
2383         {
2384             get
2385             {
2386                 return GetHierarchyDepth();
2387             }
2388         }
2389
2390         /// <summary>
2391         /// Sets the sibling order of the view so the depth position can be defined within the same parent.
2392         /// </summary>
2393         /// <remarks>
2394         /// Note the initial value is 0. SiblingOrder should be bigger than 0 or equal to 0.
2395         /// Raise, Lower, RaiseToTop, LowerToBottom, RaiseAbove, and LowerBelow will override the sibling order.
2396         /// The values set by this property will likely change.
2397         /// </remarks>
2398         /// <since_tizen> 3 </since_tizen>
2399         public int SiblingOrder
2400         {
2401             get
2402             {
2403                 return (int)GetValue(SiblingOrderProperty);
2404             }
2405             set
2406             {
2407                 SetValue(SiblingOrderProperty, value);
2408                 NotifyPropertyChanged();
2409             }
2410         }
2411
2412         /// <summary>
2413         /// Returns the natural size of the view.
2414         /// </summary>
2415         /// <remarks>
2416         /// Deriving classes stipulate the natural size and by default a view has a zero natural size.
2417         /// </remarks>
2418         /// <since_tizen> 5 </since_tizen>
2419         public Vector3 NaturalSize
2420         {
2421             get
2422             {
2423                 Vector3 ret = new Vector3(Interop.Actor.Actor_GetNaturalSize(swigCPtr), true);
2424                 if (NDalicPINVOKE.SWIGPendingException.Pending)
2425                     throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2426                 return ret;
2427             }
2428         }
2429
2430         /// <summary>
2431         /// Returns the natural size (Size2D) of the view.
2432         /// </summary>
2433         /// <remarks>
2434         /// Deriving classes stipulate the natural size and by default a view has a zero natural size.
2435         /// </remarks>
2436         /// <since_tizen> 4 </since_tizen>
2437         public Size2D NaturalSize2D
2438         {
2439             get
2440             {
2441                 Vector3 temp = new Vector3(Interop.Actor.Actor_GetNaturalSize(swigCPtr), true);
2442                 if (NDalicPINVOKE.SWIGPendingException.Pending)
2443                     throw NDalicPINVOKE.SWIGPendingException.Retrieve();
2444
2445                 return new Size2D((int)temp.Width, (int)temp.Height);
2446             }
2447         }
2448
2449         /// <summary>
2450         /// Gets or sets the origin of a view within its parent's area.<br />
2451         /// 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 />
2452         /// The default parent-origin is ParentOrigin.TopLeft (0.0, 0.0, 0.5).<br />
2453         /// A view's position is the distance between this origin and the view's anchor-point.<br />
2454         /// </summary>
2455         /// <pre>The view has been initialized.</pre>
2456         /// <since_tizen> 3 </since_tizen>
2457         public Position ParentOrigin
2458         {
2459             get
2460             {
2461                 return (Position)GetValue(ParentOriginProperty);
2462             }
2463             set
2464             {
2465                 SetValue(ParentOriginProperty, value);
2466                 NotifyPropertyChanged();
2467             }
2468         }
2469
2470         /// <summary>
2471         /// Gets or sets the anchor-point of a view.<br />
2472         /// 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 />
2473         /// The default pivot point is PivotPoint.Center (0.5, 0.5, 0.5).<br />
2474         /// A view position is the distance between its parent-origin and this anchor-point.<br />
2475         /// A view's orientation is the rotation from its default orientation, the rotation is centered around its anchor-point.<br />
2476         /// <pre>The view has been initialized.</pre>
2477         /// </summary>
2478         /// <since_tizen> 3 </since_tizen>
2479         public Position PivotPoint
2480         {
2481             get
2482             {
2483                 return (Position)GetValue(PivotPointProperty);
2484             }
2485             set
2486             {
2487                 SetValue(PivotPointProperty, value);
2488                 NotifyPropertyChanged();
2489             }
2490         }
2491
2492         /// <summary>
2493         /// Gets or sets the size width of the view.
2494         /// </summary>
2495         /// <since_tizen> 3 </since_tizen>
2496         public float SizeWidth
2497         {
2498             get
2499             {
2500                 return (float)GetValue(SizeWidthProperty);
2501             }
2502             set
2503             {
2504                 SetValue(SizeWidthProperty, value);
2505                 SetProperty(LayoutItemWrapper.ChildProperty.WIDTH_SPECIFICATION, new Tizen.NUI.PropertyValue(value));
2506                 NotifyPropertyChanged();
2507             }
2508         }
2509
2510         /// <summary>
2511         /// Gets or sets the size height of the view.
2512         /// </summary>
2513         /// <since_tizen> 3 </since_tizen>
2514         public float SizeHeight
2515         {
2516             get
2517             {
2518                 return (float)GetValue(SizeHeightProperty);
2519             }
2520             set
2521             {
2522                 SetValue(SizeHeightProperty, value);
2523                 SetProperty(LayoutItemWrapper.ChildProperty.HEIGHT_SPECIFICATION, new Tizen.NUI.PropertyValue(value));
2524                 NotifyPropertyChanged();
2525             }
2526         }
2527
2528         /// <summary>
2529         /// Gets or sets the position of the view.<br />
2530         /// By default, sets the position vector between the parent origin and pivot point (default).<br />
2531         /// If the position inheritance is disabled, sets the world position.<br />
2532         /// </summary>
2533         /// <since_tizen> 3 </since_tizen>
2534         public Position Position
2535         {
2536             get
2537             {
2538                 return (Position)GetValue(PositionProperty);
2539             }
2540             set
2541             {
2542                 SetValue(PositionProperty, value);
2543                 NotifyPropertyChanged();
2544             }
2545         }
2546
2547         /// <summary>
2548         /// Gets or sets the position X of the view.
2549         /// </summary>
2550         /// <since_tizen> 3 </since_tizen>
2551         public float PositionX
2552         {
2553             get
2554             {
2555                 return (float)GetValue(PositionXProperty);
2556             }
2557             set
2558             {
2559                 SetValue(PositionXProperty, value);
2560                 NotifyPropertyChanged();
2561             }
2562         }
2563
2564         /// <summary>
2565         /// Gets or sets the position Y of the view.
2566         /// </summary>
2567         /// <since_tizen> 3 </since_tizen>
2568         public float PositionY
2569         {
2570             get
2571             {
2572                 return (float)GetValue(PositionYProperty);
2573             }
2574             set
2575             {
2576                 SetValue(PositionYProperty, value);
2577                 NotifyPropertyChanged();
2578             }
2579         }
2580
2581         /// <summary>
2582         /// Gets or sets the position Z of the view.
2583         /// </summary>
2584         /// <since_tizen> 3 </since_tizen>
2585         public float PositionZ
2586         {
2587             get
2588             {
2589                 return (float)GetValue(PositionZProperty);
2590             }
2591             set
2592             {
2593                 SetValue(PositionZProperty, value);
2594                 NotifyPropertyChanged();
2595             }
2596         }
2597
2598         /// <summary>
2599         /// Gets or sets the world position of the view.
2600         /// </summary>
2601         /// <since_tizen> 3 </since_tizen>
2602         public Vector3 WorldPosition
2603         {
2604             get
2605             {
2606                 Vector3 temp = new Vector3(0.0f, 0.0f, 0.0f);
2607                 GetProperty(View.Property.WORLD_POSITION).Get(temp);
2608                 return temp;
2609             }
2610         }
2611
2612         /// <summary>
2613         /// Gets or sets the orientation of the view.<br />
2614         /// The view's orientation is the rotation from its default orientation, and the rotation is centered around its anchor-point.<br />
2615         /// </summary>
2616         /// <remarks>This is an asynchronous method.</remarks>
2617         /// <since_tizen> 3 </since_tizen>
2618         public Rotation Orientation
2619         {
2620             get
2621             {
2622                 return (Rotation)GetValue(OrientationProperty);
2623             }
2624             set
2625             {
2626                 SetValue(OrientationProperty, value);
2627                 NotifyPropertyChanged();
2628             }
2629         }
2630
2631         /// <summary>
2632         /// Gets or sets the world orientation of the view.<br />
2633         /// </summary>
2634         /// <since_tizen> 3 </since_tizen>
2635         public Rotation WorldOrientation
2636         {
2637             get
2638             {
2639                 Rotation temp = new Rotation();
2640                 GetProperty(View.Property.WORLD_ORIENTATION).Get(temp);
2641                 return temp;
2642             }
2643         }
2644
2645         /// <summary>
2646         /// Gets or sets the scale factor applied to the view.<br />
2647         /// </summary>
2648         /// <since_tizen> 3 </since_tizen>
2649         public Vector3 Scale
2650         {
2651             get
2652             {
2653                 return (Vector3)GetValue(ScaleProperty);
2654             }
2655             set
2656             {
2657                 SetValue(ScaleProperty, value);
2658                 NotifyPropertyChanged();
2659             }
2660         }
2661
2662         /// <summary>
2663         /// Gets or sets the scale X factor applied to the view.
2664         /// </summary>
2665         /// <since_tizen> 3 </since_tizen>
2666         public float ScaleX
2667         {
2668             get
2669             {
2670                 return (float)GetValue(ScaleXProperty);
2671             }
2672             set
2673             {
2674                 SetValue(ScaleXProperty, value);
2675                 NotifyPropertyChanged();
2676             }
2677         }
2678
2679         /// <summary>
2680         /// Gets or sets the scale Y factor applied to the view.
2681         /// </summary>
2682         /// <since_tizen> 3 </since_tizen>
2683         public float ScaleY
2684         {
2685             get
2686             {
2687                 return (float)GetValue(ScaleYProperty);
2688             }
2689             set
2690             {
2691                 SetValue(ScaleYProperty, value);
2692                 NotifyPropertyChanged();
2693             }
2694         }
2695
2696         /// <summary>
2697         /// Gets or sets the scale Z factor applied to the view.
2698         /// </summary>
2699         /// <since_tizen> 3 </since_tizen>
2700         public float ScaleZ
2701         {
2702             get
2703             {
2704                 return (float)GetValue(ScaleZProperty);
2705             }
2706             set
2707             {
2708                 SetValue(ScaleZProperty, value);
2709                 NotifyPropertyChanged();
2710             }
2711         }
2712
2713         /// <summary>
2714         /// Gets the world scale of the view.
2715         /// </summary>
2716         /// <since_tizen> 3 </since_tizen>
2717         public Vector3 WorldScale
2718         {
2719             get
2720             {
2721                 Vector3 temp = new Vector3(0.0f, 0.0f, 0.0f);
2722                 GetProperty(View.Property.WORLD_SCALE).Get(temp);
2723                 return temp;
2724             }
2725         }
2726
2727         /// <summary>
2728         /// Retrieves the visibility flag of the view.
2729         /// </summary>
2730         /// <remarks>
2731         /// If the view is not visible, then the view and its children will not be rendered.
2732         /// This is regardless of the individual visibility values of the children, i.e., the view will only be rendered if all of its parents have visibility set to true.
2733         /// </remarks>
2734         /// <since_tizen> 3 </since_tizen>
2735         public bool Visibility
2736         {
2737             get
2738             {
2739                 bool temp = false;
2740                 GetProperty(View.Property.VISIBLE).Get(out temp);
2741                 return temp;
2742             }
2743         }
2744
2745         /// <summary>
2746         /// Gets the view's world color.
2747         /// </summary>
2748         /// <since_tizen> 3 </since_tizen>
2749         public Vector4 WorldColor
2750         {
2751             get
2752             {
2753                 Vector4 temp = new Vector4(0.0f, 0.0f, 0.0f, 0.0f);
2754                 GetProperty(View.Property.WORLD_COLOR).Get(temp);
2755                 return temp;
2756             }
2757         }
2758
2759         /// <summary>
2760         /// Gets or sets the view's name.
2761         /// </summary>
2762         /// <since_tizen> 3 </since_tizen>
2763         public string Name
2764         {
2765             get
2766             {
2767                 return (string)GetValue(NameProperty);
2768             }
2769             set
2770             {
2771                 SetValue(NameProperty, value);
2772                 NotifyPropertyChanged();
2773             }
2774         }
2775
2776         /// <summary>
2777         /// Get the number of children held by the view.
2778         /// </summary>
2779         /// <since_tizen> 3 </since_tizen>
2780         public new uint ChildCount
2781         {
2782             get
2783             {
2784                 return GetChildCount();
2785             }
2786         }
2787
2788         /// <summary>
2789         /// Gets the view's ID.
2790         /// Readonly
2791         /// </summary>
2792         /// <since_tizen> 3 </since_tizen>
2793         public uint ID
2794         {
2795             get
2796             {
2797                 return GetId();
2798             }
2799         }
2800
2801         /// <summary>
2802         /// Gets or sets the status of whether the view should emit touch or hover signals.
2803         /// </summary>
2804         /// <since_tizen> 3 </since_tizen>
2805         public bool Sensitive
2806         {
2807             get
2808             {
2809                 return (bool)GetValue(SensitiveProperty);
2810             }
2811             set
2812             {
2813                 SetValue(SensitiveProperty, value);
2814                 NotifyPropertyChanged();
2815             }
2816         }
2817
2818         /// <summary>
2819         /// Gets or sets the status of whether the view should receive a notification when touch or hover motion events leave the boundary of the view.
2820         /// </summary>
2821         /// <since_tizen> 3 </since_tizen>
2822         public bool LeaveRequired
2823         {
2824             get
2825             {
2826                 return (bool)GetValue(LeaveRequiredProperty);
2827             }
2828             set
2829             {
2830                 SetValue(LeaveRequiredProperty, value);
2831                 NotifyPropertyChanged();
2832             }
2833         }
2834
2835         /// <summary>
2836         /// Gets or sets the status of whether a child view inherits it's parent's orientation.
2837         /// </summary>
2838         /// <since_tizen> 3 </since_tizen>
2839         public bool InheritOrientation
2840         {
2841             get
2842             {
2843                 return (bool)GetValue(InheritOrientationProperty);
2844             }
2845             set
2846             {
2847                 SetValue(InheritOrientationProperty, value);
2848                 NotifyPropertyChanged();
2849             }
2850         }
2851
2852         /// <summary>
2853         /// Gets or sets the status of whether a child view inherits it's parent's scale.
2854         /// </summary>
2855         /// <since_tizen> 3 </since_tizen>
2856         public bool InheritScale
2857         {
2858             get
2859             {
2860                 return (bool)GetValue(InheritScaleProperty);
2861             }
2862             set
2863             {
2864                 SetValue(InheritScaleProperty, value);
2865                 NotifyPropertyChanged();
2866             }
2867         }
2868
2869         /// <summary>
2870         /// Gets or sets the status of how the view and its children should be drawn.<br />
2871         /// Not all views are renderable, but DrawMode can be inherited from any view.<br />
2872         /// 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 />
2873         /// If DrawMode.Overlay2D is used, the view and its children will be drawn as a 2D overlay.<br />
2874         /// Overlay views are drawn in a separate pass, after all non-overlay views within the layer.<br />
2875         /// For overlay views, the drawing order is with respect to tree levels of views, and depth-testing will not be used.<br />
2876         /// </summary>
2877         /// <since_tizen> 3 </since_tizen>
2878         public DrawModeType DrawMode
2879         {
2880             get
2881             {
2882                 return (DrawModeType)GetValue(DrawModeProperty);
2883             }
2884             set
2885             {
2886                 SetValue(DrawModeProperty, value);
2887                 NotifyPropertyChanged();
2888             }
2889         }
2890
2891         /// <summary>
2892         /// Gets or sets the relative to parent size factor of the view.<br />
2893         /// This factor is only used when ResizePolicyType is set to either: ResizePolicyType.SizeRelativeToParent or ResizePolicyType.SizeFixedOffsetFromParent.<br />
2894         /// This view's size is set to the view's size multiplied by or added to this factor, depending on ResizePolicyType.<br />
2895         /// </summary>
2896         /// <since_tizen> 3 </since_tizen>
2897         public Vector3 SizeModeFactor
2898         {
2899             get
2900             {
2901                 return (Vector3)GetValue(SizeModeFactorProperty);
2902             }
2903             set
2904             {
2905                 SetValue(SizeModeFactorProperty, value);
2906                 NotifyPropertyChanged();
2907             }
2908         }
2909
2910         /// <summary>
2911         /// Gets or sets the width resize policy to be used.
2912         /// </summary>
2913         /// <since_tizen> 3 </since_tizen>
2914         public ResizePolicyType WidthResizePolicy
2915         {
2916             get
2917             {
2918                 return (ResizePolicyType)GetValue(WidthResizePolicyProperty);
2919             }
2920             set
2921             {
2922                 SetValue(WidthResizePolicyProperty, value);
2923                 // Match ResizePolicy to new Layouting.
2924                 // Parent relative policies can not be mapped at this point as parent size unknown.
2925                 switch (value)
2926                 {
2927                     case ResizePolicyType.UseNaturalSize:
2928                     {
2929                         SetProperty(LayoutItemWrapper.ChildProperty.WIDTH_SPECIFICATION, new Tizen.NUI.PropertyValue( (int)ChildLayoutData.WrapContent ) );
2930                         break;
2931                     }
2932                     case ResizePolicyType.FillToParent:
2933                     {
2934                         SetProperty(LayoutItemWrapper.ChildProperty.WIDTH_SPECIFICATION, new Tizen.NUI.PropertyValue((int)ChildLayoutData.MatchParent));
2935                         break;
2936                     }
2937                     case ResizePolicyType.FitToChildren:
2938                     {
2939                         SetProperty(LayoutItemWrapper.ChildProperty.WIDTH_SPECIFICATION, new Tizen.NUI.PropertyValue((int)ChildLayoutData.WrapContent));
2940                         break;
2941                     }
2942                     default:
2943                         break;
2944                 }
2945                 NotifyPropertyChanged();
2946             }
2947         }
2948
2949         /// <summary>
2950         /// Gets or sets the height resize policy to be used.
2951         /// </summary>
2952         /// <since_tizen> 3 </since_tizen>
2953         public ResizePolicyType HeightResizePolicy
2954         {
2955             get
2956             {
2957                 return (ResizePolicyType)GetValue(HeightResizePolicyProperty);
2958             }
2959             set
2960             {
2961                 SetValue(HeightResizePolicyProperty, value);
2962                 // Match ResizePolicy to new Layouting.
2963                 // Parent relative policies can not be mapped at this point as parent size unknown.
2964                 switch (value)
2965                 {
2966                     case ResizePolicyType.UseNaturalSize:
2967                     {
2968                         SetProperty(LayoutItemWrapper.ChildProperty.HEIGHT_SPECIFICATION, new Tizen.NUI.PropertyValue( (int)ChildLayoutData.WrapContent ) );
2969                         break;
2970                     }
2971                     case ResizePolicyType.FillToParent:
2972                     {
2973                         SetProperty(LayoutItemWrapper.ChildProperty.HEIGHT_SPECIFICATION, new Tizen.NUI.PropertyValue((int)ChildLayoutData.MatchParent));
2974                         break;
2975                     }
2976                     case ResizePolicyType.FitToChildren:
2977                     {
2978                         SetProperty(LayoutItemWrapper.ChildProperty.HEIGHT_SPECIFICATION, new Tizen.NUI.PropertyValue((int)ChildLayoutData.WrapContent));
2979                         break;
2980                     }
2981                     default:
2982                         break;
2983                 }
2984                 NotifyPropertyChanged();
2985             }
2986         }
2987
2988         /// <summary>
2989         /// Gets or sets the policy to use when setting size with size negotiation.<br />
2990         /// Defaults to SizeScalePolicyType.UseSizeSet.<br />
2991         /// </summary>
2992         /// <since_tizen> 3 </since_tizen>
2993         public SizeScalePolicyType SizeScalePolicy
2994         {
2995             get
2996             {
2997                 return (SizeScalePolicyType)GetValue(SizeScalePolicyProperty);
2998             }
2999             set
3000             {
3001                 SetValue(SizeScalePolicyProperty, value);
3002                 NotifyPropertyChanged();
3003             }
3004         }
3005
3006         /// <summary>
3007         ///  Gets or sets the status of whether the width size is dependent on the height size.
3008         /// </summary>
3009         /// <since_tizen> 3 </since_tizen>
3010         public bool WidthForHeight
3011         {
3012             get
3013             {
3014                 return (bool)GetValue(WidthForHeightProperty);
3015             }
3016             set
3017             {
3018                 SetValue(WidthForHeightProperty, value);
3019                 NotifyPropertyChanged();
3020             }
3021         }
3022
3023         /// <summary>
3024         /// Gets or sets the status of whether the height size is dependent on the width size.
3025         /// </summary>
3026         /// <since_tizen> 3 </since_tizen>
3027         public bool HeightForWidth
3028         {
3029             get
3030             {
3031                 return (bool)GetValue(HeightForWidthProperty);
3032             }
3033             set
3034             {
3035                 SetValue(HeightForWidthProperty, value);
3036                 NotifyPropertyChanged();
3037             }
3038         }
3039
3040         /// <summary>
3041         /// Gets or sets the padding for use in layout.
3042         /// </summary>
3043         /// <since_tizen> 5 </since_tizen>
3044         public Extents Padding
3045         {
3046             get
3047             {
3048                 return (Extents)GetValue(PaddingProperty);
3049             }
3050             set
3051             {
3052                 SetValue(PaddingProperty, value);
3053                 NotifyPropertyChanged();
3054             }
3055         }
3056
3057         /// <summary>
3058         /// Gets or sets the minimum size the view can be assigned in size negotiation.
3059         /// </summary>
3060         /// <since_tizen> 3 </since_tizen>
3061         public Size2D MinimumSize
3062         {
3063             get
3064             {
3065                 return (Size2D)GetValue(MinimumSizeProperty);
3066             }
3067             set
3068             {
3069                 if (Layout != null)
3070                 {
3071                     // Note: it only works if minimum size is >= than natural size.
3072                     // To force the size it should be done through the width&height spec or Size2D.
3073                     Layout.MinimumWidth = new Tizen.NUI.LayoutLength(value.Width);
3074                     Layout.MinimumHeight = new Tizen.NUI.LayoutLength(value.Height);
3075                 }
3076                 SetValue(MinimumSizeProperty, value);
3077                 NotifyPropertyChanged();
3078             }
3079         }
3080
3081         /// <summary>
3082         /// Gets or sets the maximum size the view can be assigned in size negotiation.
3083         /// </summary>
3084         /// <since_tizen> 3 </since_tizen>
3085         public Size2D MaximumSize
3086         {
3087             get
3088             {
3089                 return (Size2D)GetValue(MaximumSizeProperty);
3090             }
3091             set
3092             {
3093                 // We don't have Layout.Maximum(Width|Height) so we cannot apply it to layout.
3094                 // MATCH_PARENT spec + parent container size can be used to limit
3095                 SetValue(MaximumSizeProperty, value);
3096                 NotifyPropertyChanged();
3097             }
3098         }
3099
3100         /// <summary>
3101         /// Gets or sets whether a child view inherits it's parent's position.<br />
3102         /// Default is to inherit.<br />
3103         /// 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 />
3104         /// </summary>
3105         /// <since_tizen> 3 </since_tizen>
3106         public bool InheritPosition
3107         {
3108             get
3109             {
3110                 return (bool)GetValue(InheritPositionProperty);
3111             }
3112             set
3113             {
3114                 SetValue(InheritPositionProperty, value);
3115                 NotifyPropertyChanged();
3116             }
3117         }
3118
3119         /// <summary>
3120         /// Gets or sets the clipping behavior (mode) of it's children.
3121         /// </summary>
3122         /// <since_tizen> 3 </since_tizen>
3123         public ClippingModeType ClippingMode
3124         {
3125             get
3126             {
3127                 return (ClippingModeType)GetValue(ClippingModeProperty);
3128             }
3129             set
3130             {
3131                 SetValue(ClippingModeProperty, value);
3132                 NotifyPropertyChanged();
3133             }
3134         }
3135
3136         /// <summary>
3137         /// Gets the number of renderers held by the view.
3138         /// </summary>
3139         /// <since_tizen> 3 </since_tizen>
3140         public uint RendererCount
3141         {
3142             get
3143             {
3144                 return GetRendererCount();
3145             }
3146         }
3147
3148         /// <summary>
3149         /// [Obsolete("Please do not use! this will be deprecated")]
3150         /// </summary>
3151         /// <since_tizen> 3 </since_tizen>
3152         /// Please do not use! this will be deprecated!
3153         /// Instead please use PivotPoint.
3154         [Obsolete("Please do not use! This will be deprecated! Please use PivotPoint instead! " +
3155             "Like: " +
3156             "View view = new View(); " +
3157             "view.PivotPoint = PivotPoint.Center; " +
3158             "view.PositionUsesPivotPoint = true;")]
3159         [EditorBrowsable(EditorBrowsableState.Never)]
3160         public Position AnchorPoint
3161         {
3162             get
3163             {
3164                 Position temp = new Position(0.0f, 0.0f, 0.0f);
3165                 GetProperty(View.Property.ANCHOR_POINT).Get(temp);
3166                 return temp;
3167             }
3168             set
3169             {
3170                 SetProperty(View.Property.ANCHOR_POINT, new Tizen.NUI.PropertyValue(value));
3171                 NotifyPropertyChanged();
3172             }
3173         }
3174
3175         /// <summary>
3176         /// Sets the size of a view for the width, the height and the depth.<br />
3177         /// Geometry can be scaled to fit within this area.<br />
3178         /// This does not interfere with the view's scale factor.<br />
3179         /// The views default depth is the minimum of width and height.<br />
3180         /// </summary>
3181         /// <remarks>
3182         /// Please note that multi-cascade setting is not possible for this NUI object. <br />
3183         /// It is recommended that NUI object typed properties are configured by their constructor with parameters. <br />
3184         /// For example, this code is working fine : view.Size = new Size( 1.0f, 1.0f, 0.0f); <br />
3185         /// but this will not work! : view.Size.Width = 2.0f; view.Size.Height = 2.0f; <br />
3186         /// It may not match the current value in some cases, i.e. when the animation is progressing or the maximum or minimu size is set. <br />
3187         /// </remarks>
3188         /// <since_tizen> 5 </since_tizen>
3189         public Size Size
3190         {
3191             get
3192             {
3193                 return (Size)GetValue(SizeProperty);
3194             }
3195             set
3196             {
3197                 SetValue(SizeProperty, value);
3198                 // Set Specification so when layouts measure this View it matches the value set here.
3199                 // All Views are currently Layouts.
3200                 SetProperty(LayoutItemWrapper.ChildProperty.WIDTH_SPECIFICATION, new Tizen.NUI.PropertyValue(value.Width));
3201                 SetProperty(LayoutItemWrapper.ChildProperty.HEIGHT_SPECIFICATION, new Tizen.NUI.PropertyValue(value.Height));
3202                 NotifyPropertyChanged();
3203             }
3204         }
3205
3206         /// <summary>
3207         /// "Please DO NOT use! This will be deprecated! Please use 'Container GetParent() for derived class' instead!"
3208         /// </summary>
3209         /// <since_tizen> 3 </since_tizen>
3210         [Obsolete("Please do not use! This will be deprecated! Please use 'Container GetParent() for derived class' instead! " +
3211             "Like: " +
3212             "Container parent =  view.GetParent(); " +
3213             "View view = parent as View;")]
3214         [EditorBrowsable(EditorBrowsableState.Never)]
3215         public new View Parent
3216         {
3217             get
3218             {
3219                 View ret;
3220                 IntPtr cPtr = Interop.Actor.Actor_GetParent(swigCPtr);
3221                 HandleRef CPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
3222                 BaseHandle basehandle = Registry.GetManagedBaseHandleFromNativePtr(CPtr.Handle);
3223
3224                 if (basehandle is Layer layer)
3225                 {
3226                     ret = new View(Layer.getCPtr(layer).Handle, false);
3227                     NUILog.Error("This Parent property is deprecated, shoud do not be used");
3228                 }
3229                 else
3230                 {
3231                     ret = basehandle as View;
3232                 }
3233
3234                 Interop.BaseHandle.delete_BaseHandle(CPtr);
3235                 CPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
3236
3237                 if (NDalicPINVOKE.SWIGPendingException.Pending)
3238                     throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3239                 return ret;
3240             }
3241         }
3242
3243         /// <summary>
3244         /// Gets/Sets whether inherit parent's the layout Direction.
3245         /// </summary>
3246         /// <since_tizen> 4 </since_tizen>
3247         public bool InheritLayoutDirection
3248         {
3249             get
3250             {
3251                 return (bool)GetValue(InheritLayoutDirectionProperty);
3252             }
3253             set
3254             {
3255                 SetValue(InheritLayoutDirectionProperty, value);
3256                 NotifyPropertyChanged();
3257             }
3258         }
3259
3260         /// <summary>
3261         /// Gets/Sets the layout Direction.
3262         /// </summary>
3263         /// <since_tizen> 4 </since_tizen>
3264         public ViewLayoutDirectionType LayoutDirection
3265         {
3266             get
3267             {
3268                 return (ViewLayoutDirectionType)GetValue(LayoutDirectionProperty);
3269             }
3270             set
3271             {
3272                 SetValue(LayoutDirectionProperty, value);
3273                 NotifyPropertyChanged();
3274             }
3275         }
3276
3277         /// <summary>
3278         /// Gets or sets the Margin for use in layout.
3279         /// </summary>
3280         /// <remarks>
3281         /// Margin property is supported by Layout algorithms and containers.
3282         /// Please Set Layout if you want to use Margin property.
3283         /// </remarks>
3284         /// <since_tizen> 4 </since_tizen>
3285         public Extents Margin
3286         {
3287             get
3288             {
3289                 return (Extents)GetValue(MarginProperty);
3290             }
3291             set
3292             {
3293                 SetValue(MarginProperty, value);
3294                 NotifyPropertyChanged();
3295             }
3296         }
3297
3298         /// <summary>
3299         /// [Obsolete("Please do not use! this will be deprecated")]
3300         /// </summary>
3301         /// Please do not use! this will be deprecated!
3302         /// Instead please use Padding.
3303         /// <since_tizen> 4 </since_tizen>
3304         [Obsolete("Please do not use! this will be deprecated, instead please use Padding.")]
3305         [EditorBrowsable(EditorBrowsableState.Never)]
3306         public Extents PaddingEX
3307         {
3308             get
3309             {
3310                 Extents temp = new Extents(0, 0, 0, 0);
3311                 GetProperty(View.Property.PADDING).Get(temp);
3312                 return temp;
3313             }
3314             set
3315             {
3316                 SetProperty(View.Property.PADDING, new Tizen.NUI.PropertyValue(value));
3317                 NotifyPropertyChanged();
3318             }
3319         }
3320
3321         internal Style Style
3322         {
3323             get
3324             {
3325                 return (Style)GetValue(StyleProperty);
3326             }
3327             set
3328             {
3329                 SetValue(StyleProperty, value);
3330             }
3331         }
3332
3333         /// <summary>
3334         /// Child property to specify desired width
3335         /// </summary>
3336         internal int LayoutWidthSpecificationFixed
3337         {
3338             get
3339             {
3340                 int tmp = 0;
3341                 if (GetProperty(LayoutItemWrapper.ChildProperty.WIDTH_SPECIFICATION).Get(out tmp) == false)
3342                 {
3343                     NUILog.Error("WidthSpecificationFixed get error!");
3344                 }
3345                 return tmp;
3346             }
3347             set
3348             {
3349                 SetProperty(LayoutItemWrapper.ChildProperty.WIDTH_SPECIFICATION, new Tizen.NUI.PropertyValue(value));
3350             }
3351         }
3352
3353         /// <summary>
3354         /// Child property to specify desired height
3355         /// </summary>
3356         internal int LayoutHeightSpecificationFixed
3357         {
3358             get
3359             {
3360                 int tmp = 0;
3361                 if (GetProperty(LayoutItemWrapper.ChildProperty.HEIGHT_SPECIFICATION).Get(out tmp) == false)
3362                 {
3363                     NUILog.Error("HeightSpecificationFixed get error!");
3364                 }
3365                 return tmp;
3366             }
3367             set
3368             {
3369                 SetProperty(LayoutItemWrapper.ChildProperty.HEIGHT_SPECIFICATION, new Tizen.NUI.PropertyValue(value));
3370             }
3371         }
3372
3373         /// <summary>
3374         /// Child property to specify desired width, use MatchParent/WrapContent)
3375         /// </summary>
3376         internal ChildLayoutData LayoutWidthSpecification
3377         {
3378             get
3379             {
3380                 int tmp = 0;
3381                 if (GetProperty(LayoutItemWrapper.ChildProperty.WIDTH_SPECIFICATION).Get(out tmp) == false)
3382                 {
3383                     NUILog.Error("WidthSpecificationFixed get error!");
3384                 }
3385                 return (ChildLayoutData)tmp;
3386             }
3387             set
3388             {
3389                 SetProperty(LayoutItemWrapper.ChildProperty.WIDTH_SPECIFICATION, new Tizen.NUI.PropertyValue((int)value));
3390             }
3391         }
3392
3393         /// <summary>
3394         /// Child property to specify desired height, use MatchParent/WrapContent)
3395         /// </summary>
3396         internal ChildLayoutData LayoutHeightSpecification
3397         {
3398             get
3399             {
3400                 int tmp = 0;
3401                 if (GetProperty(LayoutItemWrapper.ChildProperty.HEIGHT_SPECIFICATION).Get(out tmp) == false)
3402                 {
3403                     NUILog.Error("HeightSpecificationFixed get error!");
3404                 }
3405                 return (ChildLayoutData)tmp;
3406             }
3407             set
3408             {
3409                 SetProperty(LayoutItemWrapper.ChildProperty.HEIGHT_SPECIFICATION, new Tizen.NUI.PropertyValue((int)value));
3410             }
3411         }
3412
3413         internal float Weight
3414         {
3415             get
3416             {
3417                 return (float)GetValue(WeightProperty);
3418             }
3419             set
3420             {
3421                 SetValue(WeightProperty, value);
3422                 NotifyPropertyChanged();
3423             }
3424         }
3425
3426         internal bool BackgroundImageSynchronosLoading
3427         {
3428             get
3429             {
3430                 return _backgroundImageSynchronosLoading;
3431             }
3432             set
3433             {
3434                 if (value != _backgroundImageSynchronosLoading)
3435                 {
3436                     string bgUrl = "";
3437                     PropertyMap bgMap = this.Background;
3438                     int visualType = 0;
3439                     bgMap.Find(Visual.Property.Type)?.Get(out visualType);
3440                     if (visualType == (int)Visual.Type.Image)
3441                     {
3442                         bgMap.Find(ImageVisualProperty.URL)?.Get(out bgUrl);
3443                     }
3444                     if (bgUrl.Length != 0)
3445                     {
3446                         _backgroundImageSynchronosLoading = value;
3447                         bgMap.Add("synchronousLoading", new PropertyValue(_backgroundImageSynchronosLoading));
3448                         this.Background = bgMap;
3449                     }
3450                 }
3451             }
3452         }
3453
3454         internal float WorldPositionX
3455         {
3456             get
3457             {
3458                 float temp = 0.0f;
3459                 GetProperty(View.Property.WORLD_POSITION_X).Get(out temp);
3460                 return temp;
3461             }
3462         }
3463
3464         internal float WorldPositionY
3465         {
3466             get
3467             {
3468                 float temp = 0.0f;
3469                 GetProperty(View.Property.WORLD_POSITION_Y).Get(out temp);
3470                 return temp;
3471             }
3472         }
3473
3474         internal float WorldPositionZ
3475         {
3476             get
3477             {
3478                 float temp = 0.0f;
3479                 GetProperty(View.Property.WORLD_POSITION_Z).Get(out temp);
3480                 return temp;
3481             }
3482         }
3483
3484         internal bool FocusState
3485         {
3486             get
3487             {
3488                 return IsKeyboardFocusable();
3489             }
3490             set
3491             {
3492                 SetKeyboardFocusable(value);
3493             }
3494         }
3495
3496         /// <summary>
3497         /// Set the layout on this control.
3498         /// </summary>
3499         /// <remarks>
3500         /// </remarks>
3501         internal LayoutItem Layout
3502         {
3503             get
3504             {
3505                 IntPtr cPtr = Interop.Layout.GetLayout__SWIG_1(View.getCPtr(this));
3506
3507                 HandleRef CPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
3508                 BaseHandle basehandle = Registry.GetManagedBaseHandleFromNativePtr(CPtr.Handle);
3509                 Interop.BaseHandle.delete_BaseHandle(CPtr);
3510                 CPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
3511
3512                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3513
3514                 return basehandle as LayoutItem;
3515             }
3516             set
3517             {
3518                 Log.Info("NUI", "Set Layout on:" + Name + "\n");
3519                 layoutingDisabled = false;
3520                 layoutSet = true;
3521                 SetLayout(value);
3522             }
3523         }
3524
3525         /// <summary>
3526         /// Set that layouting is required on this View. It will automatically receive a Layout.
3527         /// </summary>
3528         /// <remarks>
3529         /// </remarks>
3530         internal bool LayoutingRequired
3531         {
3532             get
3533             {
3534                 bool result = Interop.View.View_IsLayoutingRequired(View.getCPtr(this));
3535                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3536                 return result;
3537             }
3538             set
3539             {
3540                 Tizen.NUI.Interop.View.View_SetLayoutingRequired(View.getCPtr(this), value);
3541             }
3542         }
3543
3544         internal float ParentOriginX
3545         {
3546             get
3547             {
3548                 float temp = 0.0f;
3549                 GetProperty(View.Property.PARENT_ORIGIN_X).Get(out temp);
3550                 return temp;
3551             }
3552             set
3553             {
3554                 SetProperty(View.Property.PARENT_ORIGIN_X, new Tizen.NUI.PropertyValue(value));
3555                 NotifyPropertyChanged();
3556             }
3557         }
3558
3559         internal float ParentOriginY
3560         {
3561             get
3562             {
3563                 float temp = 0.0f;
3564                 GetProperty(View.Property.PARENT_ORIGIN_Y).Get(out temp);
3565                 return temp;
3566             }
3567             set
3568             {
3569                 SetProperty(View.Property.PARENT_ORIGIN_Y, new Tizen.NUI.PropertyValue(value));
3570                 NotifyPropertyChanged();
3571             }
3572         }
3573
3574         internal float ParentOriginZ
3575         {
3576             get
3577             {
3578                 float temp = 0.0f;
3579                 GetProperty(View.Property.PARENT_ORIGIN_Z).Get(out temp);
3580                 return temp;
3581             }
3582             set
3583             {
3584                 SetProperty(View.Property.PARENT_ORIGIN_Z, new Tizen.NUI.PropertyValue(value));
3585                 NotifyPropertyChanged();
3586             }
3587         }
3588
3589         internal float PivotPointX
3590         {
3591             get
3592             {
3593                 float temp = 0.0f;
3594                 GetProperty(View.Property.ANCHOR_POINT_X).Get(out temp);
3595                 return temp;
3596             }
3597             set
3598             {
3599                 SetProperty(View.Property.ANCHOR_POINT_X, new Tizen.NUI.PropertyValue(value));
3600             }
3601         }
3602
3603         internal float PivotPointY
3604         {
3605             get
3606             {
3607                 float temp = 0.0f;
3608                 GetProperty(View.Property.ANCHOR_POINT_Y).Get(out temp);
3609                 return temp;
3610             }
3611             set
3612             {
3613                 SetProperty(View.Property.ANCHOR_POINT_Y, new Tizen.NUI.PropertyValue(value));
3614             }
3615         }
3616
3617         internal float PivotPointZ
3618         {
3619             get
3620             {
3621                 float temp = 0.0f;
3622                 GetProperty(View.Property.ANCHOR_POINT_Z).Get(out temp);
3623                 return temp;
3624             }
3625             set
3626             {
3627                 SetProperty(View.Property.ANCHOR_POINT_Z, new Tizen.NUI.PropertyValue(value));
3628             }
3629         }
3630
3631         internal Matrix WorldMatrix
3632         {
3633             get
3634             {
3635                 Matrix temp = new Matrix();
3636                 GetProperty(View.Property.WORLD_MATRIX).Get(temp);
3637                 return temp;
3638             }
3639         }
3640
3641         private int LeftFocusableViewId
3642         {
3643             get
3644             {
3645                 int temp = 0;
3646                 GetProperty(View.Property.LEFT_FOCUSABLE_VIEW_ID).Get(out temp);
3647                 return temp;
3648             }
3649             set
3650             {
3651                 SetProperty(View.Property.LEFT_FOCUSABLE_VIEW_ID, new Tizen.NUI.PropertyValue(value));
3652             }
3653         }
3654
3655         private int RightFocusableViewId
3656         {
3657             get
3658             {
3659                 int temp = 0;
3660                 GetProperty(View.Property.RIGHT_FOCUSABLE_VIEW_ID).Get(out temp);
3661                 return temp;
3662             }
3663             set
3664             {
3665                 SetProperty(View.Property.RIGHT_FOCUSABLE_VIEW_ID, new Tizen.NUI.PropertyValue(value));
3666             }
3667         }
3668
3669         private int UpFocusableViewId
3670         {
3671             get
3672             {
3673                 int temp = 0;
3674                 GetProperty(View.Property.UP_FOCUSABLE_VIEW_ID).Get(out temp);
3675                 return temp;
3676             }
3677             set
3678             {
3679                 SetProperty(View.Property.UP_FOCUSABLE_VIEW_ID, new Tizen.NUI.PropertyValue(value));
3680             }
3681         }
3682
3683         private int DownFocusableViewId
3684         {
3685             get
3686             {
3687                 int temp = 0;
3688                 GetProperty(View.Property.DOWN_FOCUSABLE_VIEW_ID).Get(out temp);
3689                 return temp;
3690             }
3691             set
3692             {
3693                 SetProperty(View.Property.DOWN_FOCUSABLE_VIEW_ID, new Tizen.NUI.PropertyValue(value));
3694             }
3695         }
3696
3697         /// <summary>
3698         /// Perform an action on a visual registered to this view. <br />
3699         /// Visuals will have actions. This API is used to perform one of these actions with the given attributes.
3700         /// </summary>
3701         /// <param name="propertyIndexOfVisual">The Property index of the visual.</param>
3702         /// <param name="propertyIndexOfActionId">The action to perform. See Visual to find the supported actions.</param>
3703         /// <param name="attributes">Optional attributes for the action.</param>
3704         /// <since_tizen> 5 </since_tizen>
3705         public void DoAction(int propertyIndexOfVisual, int propertyIndexOfActionId, PropertyValue attributes)
3706         {
3707             Interop.View.View_DoAction(swigCPtr, propertyIndexOfVisual, propertyIndexOfActionId, PropertyValue.getCPtr(attributes));
3708             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3709         }
3710
3711         /// <summary>
3712         /// Creates an animation to animate the background color visual. If there is no
3713         /// background visual, creates one with transparent black as it's mixColor.
3714         /// </summary>
3715         /// <since_tizen> 3 </since_tizen>
3716         public Animation AnimateBackgroundColor(object destinationValue,
3717                                                  int startTime,
3718                                                  int endTime,
3719                                                  AlphaFunction.BuiltinFunctions? alphaFunction = null,
3720                                                  object initialValue = null)
3721         {
3722             Tizen.NUI.PropertyMap background = Background;
3723
3724             if (background.Empty())
3725             {
3726                 // If there is no background yet, ensure there is a transparent
3727                 // color visual
3728                 BackgroundColor = new Color(0.0f, 0.0f, 0.0f, 0.0f);
3729                 background = Background;
3730             }
3731             return AnimateColor("background", destinationValue, startTime, endTime, alphaFunction, initialValue);
3732         }
3733
3734         /// <summary>
3735         /// Creates an animation to animate the mixColor of the named visual.
3736         /// </summary>
3737         /// <since_tizen> 3 </since_tizen>
3738         public Animation AnimateColor(string targetVisual, object destinationColor, int startTime, int endTime, AlphaFunction.BuiltinFunctions? alphaFunction = null, object initialColor = null)
3739         {
3740             Animation animation = null;
3741             {
3742                 PropertyMap _animator = new PropertyMap();
3743                 if (alphaFunction != null)
3744                 {
3745                     _animator.Add("alphaFunction", new PropertyValue(AlphaFunction.BuiltinToPropertyKey(alphaFunction)));
3746                 }
3747
3748                 PropertyMap _timePeriod = new PropertyMap();
3749                 _timePeriod.Add("duration", new PropertyValue((endTime - startTime) / 1000.0f));
3750                 _timePeriod.Add("delay", new PropertyValue(startTime / 1000.0f));
3751                 _animator.Add("timePeriod", new PropertyValue(_timePeriod));
3752
3753                 PropertyMap _transition = new PropertyMap();
3754                 _transition.Add("animator", new PropertyValue(_animator));
3755                 _transition.Add("target", new PropertyValue(targetVisual));
3756                 _transition.Add("property", new PropertyValue("mixColor"));
3757
3758                 if (initialColor != null)
3759                 {
3760                     PropertyValue initValue = PropertyValue.CreateFromObject(initialColor);
3761                     _transition.Add("initialValue", initValue);
3762                 }
3763
3764                 PropertyValue destValue = PropertyValue.CreateFromObject(destinationColor);
3765                 _transition.Add("targetValue", destValue);
3766                 TransitionData _transitionData = new TransitionData(_transition);
3767
3768                 animation = new Animation(Interop.View.View_CreateTransition(swigCPtr, TransitionData.getCPtr(_transitionData)), true);
3769                 if (NDalicPINVOKE.SWIGPendingException.Pending)
3770                     throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3771             }
3772             return animation;
3773         }
3774
3775         // From Container Base class
3776         /// <summary>
3777         /// Adds a child view to this view.
3778         /// </summary>
3779         /// <seealso cref="Container.Add" />
3780         /// <since_tizen> 4 </since_tizen>
3781         public override void Add(View child)
3782         {
3783             if (null == child)
3784             {
3785                 Tizen.Log.Fatal("NUI", "Child is null");
3786                 return;
3787             }
3788
3789             Log.Info("NUI", "Adding Child:" + child.Name + " to " + Name + "\n");
3790
3791             Container oldParent = child.GetParent();
3792             if (oldParent != this)
3793             {
3794                 if (oldParent != null)
3795                 {
3796                     oldParent.Remove(child);
3797                 }
3798                 child.InternalParent = this;
3799
3800                 // Only give children a layout if their parent is an explicit container or a pure View.
3801                 // Pure View meaning not derived from a View, e.g a Legacy container.
3802                 // layoutSet flag is true when the View became a layout using the set Layout API opposed to automatically due to it's parent.
3803                 // First time the set Layout API is used by any View the Window no longer has layoutingDisabled.
3804                 if ((true == layoutSet || GetType() == typeof(View)) && null == child.Layout && false == layoutingDisabled)
3805                 {
3806                     Log.Info("NUI", "Parent[" + Name + "] Layout set[" + layoutSet.ToString() + "] Pure View[" + (!layoutSet).ToString() + "]\n");
3807                     // If child is a View or explicitly set to require layouting then set child as a LayoutGroup.
3808                     // If the child is derived from a View then it may be a legacy or existing container hence will do layouting itself.
3809                     if (child.GetType() == typeof(View) || true == child.LayoutingRequired)
3810                     {
3811                         Log.Info("NUI", "Creating LayoutGroup for " + child.Name + " LayoutingRequired[" + child.LayoutingRequired.ToString() + "]\n");
3812                         child.SetLayout(new LayoutGroup());
3813                     }
3814                     else
3815                     {
3816                         // Adding child as a leaf, layouting will not propagate past this child.
3817                         // Legacy containers will be a LayoutItems too and layout their children how they wish.
3818                         Log.Info("NUI", "Creating LayoutItem for " + child.Name + "\n");
3819                         child.SetLayout(new LayoutItem());
3820                     }
3821                 }
3822
3823                 if (Layout)
3824                 {
3825                     Layout.LayoutChildren.Add(child.Layout);
3826                 }
3827
3828                 Interop.Actor.Actor_Add(swigCPtr, View.getCPtr(child));
3829                 if (NDalicPINVOKE.SWIGPendingException.Pending)
3830                     throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3831                 Children.Add(child);
3832
3833                 if (ChildAdded != null)
3834                 {
3835                     ChildAddedEventArgs e = new ChildAddedEventArgs
3836                     {
3837                         Added = child
3838                     };
3839                     ChildAdded(this, e);
3840                 }
3841             }
3842         }
3843
3844         /// <summary>
3845         /// Removes a child view from this View. If the view was not a child of this view, this is a no-op.
3846         /// </summary>
3847         /// <seealso cref="Container.Remove" />
3848         /// <since_tizen> 4 </since_tizen>
3849         public override void Remove(View child)
3850         {
3851             Interop.Actor.Actor_Remove(swigCPtr, View.getCPtr(child));
3852             if (NDalicPINVOKE.SWIGPendingException.Pending)
3853                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3854
3855             Children.Remove(child);
3856             child.InternalParent = null;
3857
3858             if (Layout)
3859             {
3860                 if (child.Layout)
3861                 {
3862                     Layout.LayoutChildren.Remove(child.Layout);
3863                 }
3864             }
3865
3866             if (ChildRemoved != null)
3867             {
3868                 ChildRemovedEventArgs e = new ChildRemovedEventArgs
3869                 {
3870                     Removed = child
3871                 };
3872                 ChildRemoved(this, e);
3873             }
3874         }
3875
3876         /// <summary>
3877         /// Retrieves a child view by index.
3878         /// </summary>
3879         /// <seealso cref="Container.GetChildAt" />
3880         /// <since_tizen> 4 </since_tizen>
3881         public override View GetChildAt(uint index)
3882         {
3883             if (index < Children.Count)
3884             {
3885                 return Children[Convert.ToInt32(index)];
3886             }
3887             else
3888             {
3889                 return null;
3890             }
3891         }
3892
3893         /// <summary>
3894         /// Retrieves the number of children held by the view.
3895         /// </summary>
3896         /// <seealso cref="Container.GetChildCount" />
3897         /// <since_tizen> 4 </since_tizen>
3898         public override uint GetChildCount()
3899         {
3900             return Convert.ToUInt32(Children.Count);
3901         }
3902
3903         /// <summary>
3904         /// Gets the views parent.
3905         /// </summary>
3906         /// <seealso cref="Container.GetParent()" />
3907         /// <since_tizen> 4 </since_tizen>
3908         public override Container GetParent()
3909         {
3910             return this.InternalParent as Container;
3911         }
3912
3913         /// <summary>
3914         /// Queries whether the view has a focus.
3915         /// </summary>
3916         /// <returns>True if this view has a focus.</returns>
3917         /// <since_tizen> 3 </since_tizen>
3918         public bool HasFocus()
3919         {
3920             bool ret = Interop.View.View_HasKeyInputFocus(swigCPtr);
3921             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3922             return ret;
3923         }
3924
3925         /// <summary>
3926         /// Sets the name of the style to be applied to the view.
3927         /// </summary>
3928         /// <param name="styleName">A string matching a style described in a stylesheet.</param>
3929         /// <since_tizen> 3 </since_tizen>
3930         public void SetStyleName(string styleName)
3931         {
3932             Interop.View.View_SetStyleName(swigCPtr, styleName);
3933             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3934         }
3935
3936         /// <summary>
3937         /// Retrieves the name of the style to be applied to the view (if any).
3938         /// </summary>
3939         /// <returns>A string matching a style, or an empty string.</returns>
3940         /// <since_tizen> 3 </since_tizen>
3941         public string GetStyleName()
3942         {
3943             string ret = Interop.View.View_GetStyleName(swigCPtr);
3944             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3945             return ret;
3946         }
3947
3948         /// <summary>
3949         /// Clears the background.
3950         /// </summary>
3951         /// <since_tizen> 3 </since_tizen>
3952         public void ClearBackground()
3953         {
3954             Interop.View.View_ClearBackground(swigCPtr);
3955             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
3956         }
3957
3958         /// <summary>
3959         /// Shows the view.
3960         /// </summary>
3961         /// <remarks>
3962         /// This is an asynchronous method.
3963         /// </remarks>
3964         /// <since_tizen> 3 </since_tizen>
3965         public void Show()
3966         {
3967             SetVisible(true);
3968         }
3969
3970         /// <summary>
3971         /// Hides the view.
3972         /// </summary>
3973         /// <remarks>
3974         /// This is an asynchronous method.
3975         /// If the view is hidden, then the view and its children will not be rendered.
3976         /// This is regardless of the individual visibility of the children, i.e., the view will only be rendered if all of its parents are shown.
3977         /// </remarks>
3978         /// <since_tizen> 3 </since_tizen>
3979         public void Hide()
3980         {
3981             SetVisible(false);
3982         }
3983
3984         /// <summary>
3985         /// Raises the view above all other views.
3986         /// </summary>
3987         /// <remarks>
3988         /// Sibling order of views within the parent will be updated automatically.
3989         /// Once a raise or lower API is used, that view will then have an exclusive sibling order independent of insertion.
3990         /// </remarks>
3991         /// <since_tizen> 3 </since_tizen>
3992         public void RaiseToTop()
3993         {
3994             var parentChildren = GetParent()?.Children;
3995
3996             if (parentChildren != null)
3997             {
3998                 parentChildren.Remove(this);
3999                 parentChildren.Add(this);
4000
4001                 Interop.NDalic.RaiseToTop(swigCPtr);
4002                 if (NDalicPINVOKE.SWIGPendingException.Pending)
4003                     throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4004             }
4005
4006         }
4007
4008         /// <summary>
4009         /// Lowers the view to the bottom of all views.
4010         /// </summary>
4011         /// <remarks>
4012         /// The sibling order of views within the parent will be updated automatically.
4013         /// Once a raise or lower API is used that view will then have an exclusive sibling order independent of insertion.
4014         /// </remarks>
4015         /// <since_tizen> 3 </since_tizen>
4016         public void LowerToBottom()
4017         {
4018             var parentChildren = GetParent()?.Children;
4019
4020             if (parentChildren != null)
4021             {
4022                 parentChildren.Remove(this);
4023                 parentChildren.Insert(0, this);
4024
4025                 Interop.NDalic.LowerToBottom(swigCPtr);
4026                 if (NDalicPINVOKE.SWIGPendingException.Pending)
4027                     throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4028             }
4029         }
4030
4031         /// <summary>
4032         /// Queries if all resources required by a view are loaded and ready.
4033         /// </summary>
4034         /// <remarks>Most resources are only loaded when the control is placed on the stage.
4035         /// </remarks>
4036         /// <since_tizen> 3 </since_tizen>
4037         public bool IsResourceReady()
4038         {
4039             bool ret = Interop.View.IsResourceReady(swigCPtr);
4040             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4041             return ret;
4042         }
4043
4044         /// <summary>
4045         /// Gets the parent layer of this view.If a view has no parent, this method does not do anything.
4046         /// </summary>
4047         /// <pre>The view has been initialized. </pre>
4048         /// <returns>The parent layer of view </returns>
4049         /// <since_tizen> 5 </since_tizen>
4050         public Layer GetLayer()
4051         {
4052             //to fix memory leak issue, match the handle count with native side.
4053             IntPtr cPtr = Interop.Actor.Actor_GetLayer(swigCPtr);
4054             HandleRef CPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
4055             Layer ret = Registry.GetManagedBaseHandleFromNativePtr(CPtr.Handle) as Layer;
4056             Interop.BaseHandle.delete_BaseHandle(CPtr);
4057             CPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
4058
4059             if (NDalicPINVOKE.SWIGPendingException.Pending)
4060                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4061             return ret;
4062         }
4063
4064         /// <summary>
4065         /// Removes a view from its parent view or layer. If a view has no parent, this method does nothing.
4066         /// </summary>
4067         /// <pre>The (child) view has been initialized. </pre>
4068         /// <since_tizen> 4 </since_tizen>
4069         public void Unparent()
4070         {
4071             GetParent()?.Remove(this);
4072         }
4073
4074         /// <summary>
4075         /// Search through this view's hierarchy for a view with the given name.
4076         /// The view itself is also considered in the search.
4077         /// </summary>
4078         /// <pre>The view has been initialized.</pre>
4079         /// <param name="viewName">The name of the view to find.</param>
4080         /// <returns>A handle to the view if found, or an empty handle if not.</returns>
4081         /// <since_tizen> 3 </since_tizen>
4082         public View FindChildByName(string viewName)
4083         {
4084             //to fix memory leak issue, match the handle count with native side.
4085             IntPtr cPtr = Interop.Actor.Actor_FindChildByName(swigCPtr, viewName);
4086             HandleRef CPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
4087             View ret = Registry.GetManagedBaseHandleFromNativePtr(CPtr.Handle) as View;
4088             Interop.BaseHandle.delete_BaseHandle(CPtr);
4089             CPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
4090
4091             if (NDalicPINVOKE.SWIGPendingException.Pending)
4092                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4093             return ret;
4094         }
4095
4096         /// <summary>
4097         /// Converts screen coordinates into the view's coordinate system using the default camera.
4098         /// </summary>
4099         /// <pre>The view has been initialized.</pre>
4100         /// <remarks>The view coordinates are relative to the top-left(0.0, 0.0, 0.5).</remarks>
4101         /// <param name="localX">On return, the X-coordinate relative to the view.</param>
4102         /// <param name="localY">On return, the Y-coordinate relative to the view.</param>
4103         /// <param name="screenX">The screen X-coordinate.</param>
4104         /// <param name="screenY">The screen Y-coordinate.</param>
4105         /// <returns>True if the conversion succeeded.</returns>
4106         /// <since_tizen> 3 </since_tizen>
4107         public bool ScreenToLocal(out float localX, out float localY, float screenX, float screenY)
4108         {
4109             bool ret = Interop.Actor.Actor_ScreenToLocal(swigCPtr, out localX, out localY, screenX, screenY);
4110             if (NDalicPINVOKE.SWIGPendingException.Pending)
4111                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4112             return ret;
4113         }
4114
4115         /// <summary>
4116         /// Sets the relative to parent size factor of the view.<br />
4117         /// This factor is only used when ResizePolicy is set to either:
4118         /// ResizePolicy::SIZE_RELATIVE_TO_PARENT or ResizePolicy::SIZE_FIXED_OFFSET_FROM_PARENT.<br />
4119         /// This view's size is set to the view's size multiplied by or added to this factor, depending on ResizePolicy.<br />
4120         /// </summary>
4121         /// <pre>The view has been initialized.</pre>
4122         /// <param name="factor">A Vector3 representing the relative factor to be applied to each axis.</param>
4123         /// <since_tizen> 3 </since_tizen>
4124         public void SetSizeModeFactor(Vector3 factor)
4125         {
4126             Interop.Actor.Actor_SetSizeModeFactor(swigCPtr, Vector3.getCPtr(factor));
4127             if (NDalicPINVOKE.SWIGPendingException.Pending)
4128                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4129         }
4130         /// <summary>
4131         /// Calculates the height of the view given a width.<br />
4132         /// The natural size is used for default calculation.<br />
4133         /// Size 0 is treated as aspect ratio 1:1.<br />
4134         /// </summary>
4135         /// <param name="width">The width to use.</param>
4136         /// <returns>The height based on the width.</returns>
4137         /// <since_tizen> 3 </since_tizen>
4138         public float GetHeightForWidth(float width)
4139         {
4140             float ret = Interop.Actor.Actor_GetHeightForWidth(swigCPtr, width);
4141             if (NDalicPINVOKE.SWIGPendingException.Pending)
4142                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4143             return ret;
4144         }
4145
4146         /// <summary>
4147         /// Calculates the width of the view given a height.<br />
4148         /// The natural size is used for default calculation.<br />
4149         /// Size 0 is treated as aspect ratio 1:1.<br />
4150         /// </summary>
4151         /// <param name="height">The height to use.</param>
4152         /// <returns>The width based on the height.</returns>
4153         /// <since_tizen> 3 </since_tizen>
4154         public float GetWidthForHeight(float height)
4155         {
4156             float ret = Interop.Actor.Actor_GetWidthForHeight(swigCPtr, height);
4157             if (NDalicPINVOKE.SWIGPendingException.Pending)
4158                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4159             return ret;
4160         }
4161
4162         /// <summary>
4163         /// Return the amount of size allocated for relayout.
4164         /// </summary>
4165         /// <param name="dimension">The dimension to retrieve.</param>
4166         /// <returns>Return the size.</returns>
4167         /// <since_tizen> 3 </since_tizen>
4168         public float GetRelayoutSize(DimensionType dimension)
4169         {
4170             float ret = Interop.Actor.Actor_GetRelayoutSize(swigCPtr, (int)dimension);
4171             if (NDalicPINVOKE.SWIGPendingException.Pending)
4172                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4173             return ret;
4174         }
4175
4176         /// <summary>
4177         /// Set the padding for the view.
4178         /// </summary>
4179         /// <param name="padding">Padding for the view.</param>
4180         /// <since_tizen> 3 </since_tizen>
4181         public void SetPadding(PaddingType padding)
4182         {
4183             Interop.Actor.Actor_SetPadding(swigCPtr, PaddingType.getCPtr(padding));
4184             if (NDalicPINVOKE.SWIGPendingException.Pending)
4185                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4186         }
4187
4188         /// <summary>
4189         /// Return the value of padding for the view.
4190         /// </summary>
4191         /// <param name="paddingOut">the value of padding for the view</param>
4192         /// <since_tizen> 3 </since_tizen>
4193         public void GetPadding(PaddingType paddingOut)
4194         {
4195             Interop.Actor.Actor_GetPadding(swigCPtr, PaddingType.getCPtr(paddingOut));
4196             if (NDalicPINVOKE.SWIGPendingException.Pending)
4197                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4198         }
4199
4200         /// <since_tizen> 3 </since_tizen>
4201         public uint AddRenderer(Renderer renderer)
4202         {
4203             uint ret = Interop.Actor.Actor_AddRenderer(swigCPtr, Renderer.getCPtr(renderer));
4204             if (NDalicPINVOKE.SWIGPendingException.Pending)
4205                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4206             return ret;
4207         }
4208
4209         /// <since_tizen> 3 </since_tizen>
4210         public Renderer GetRendererAt(uint index)
4211         {
4212             //to fix memory leak issue, match the handle count with native side.
4213             IntPtr cPtr = Interop.Actor.Actor_GetRendererAt(swigCPtr, index);
4214             HandleRef CPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
4215             Renderer ret = Registry.GetManagedBaseHandleFromNativePtr(CPtr.Handle) as Renderer;
4216             if (cPtr != null && ret == null)
4217             {
4218                 ret = new Renderer(cPtr, false);
4219                 if (NDalicPINVOKE.SWIGPendingException.Pending)
4220                     throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4221                 return ret;
4222             }
4223             Interop.BaseHandle.delete_BaseHandle(CPtr);
4224             CPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
4225
4226             if (NDalicPINVOKE.SWIGPendingException.Pending)
4227                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4228             return ret;
4229         }
4230
4231         /// <since_tizen> 3 </since_tizen>
4232         public void RemoveRenderer(Renderer renderer)
4233         {
4234             Interop.Actor.Actor_RemoveRenderer__SWIG_0(swigCPtr, Renderer.getCPtr(renderer));
4235             if (NDalicPINVOKE.SWIGPendingException.Pending)
4236                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4237         }
4238
4239         /// <since_tizen> 3 </since_tizen>
4240         public void RemoveRenderer(uint index)
4241         {
4242             Interop.Actor.Actor_RemoveRenderer__SWIG_1(swigCPtr, index);
4243             if (NDalicPINVOKE.SWIGPendingException.Pending)
4244                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4245         }
4246
4247         internal void Raise()
4248         {
4249             var parentChildren = GetParent()?.Children;
4250
4251             if (parentChildren != null)
4252             {
4253                 int currentIndex = parentChildren.IndexOf(this);
4254
4255                 // If the view is not already the last item in the list.
4256                 if (currentIndex >= 0 && currentIndex < parentChildren.Count - 1)
4257                 {
4258                     View temp = parentChildren[currentIndex + 1];
4259                     parentChildren[currentIndex + 1] = this;
4260                     parentChildren[currentIndex] = temp;
4261
4262                     Interop.NDalic.Raise(swigCPtr);
4263                     if (NDalicPINVOKE.SWIGPendingException.Pending)
4264                         throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4265                 }
4266             }
4267         }
4268
4269         internal void Lower()
4270         {
4271             var parentChildren = GetParent()?.Children;
4272
4273             if (parentChildren != null)
4274             {
4275                 int currentIndex = parentChildren.IndexOf(this);
4276
4277                 // If the view is not already the first item in the list.
4278                 if (currentIndex > 0 && currentIndex < parentChildren.Count)
4279                 {
4280                     View temp = parentChildren[currentIndex - 1];
4281                     parentChildren[currentIndex - 1] = this;
4282                     parentChildren[currentIndex] = temp;
4283
4284                     Interop.NDalic.Lower(swigCPtr);
4285                     if (NDalicPINVOKE.SWIGPendingException.Pending)
4286                         throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4287                 }
4288             }
4289         }
4290
4291         /// <summary>
4292         /// Raises the view to above the target view.
4293         /// </summary>
4294         /// <remarks>The sibling order of views within the parent will be updated automatically.
4295         /// Views on the level above the target view will still be shown above this view.
4296         /// Raising this view above views with the same sibling order as each other will raise this view above them.
4297         /// Once a raise or lower API is used that view will then have an exclusive sibling order independent of insertion.
4298         /// </remarks>
4299         /// <param name="target">Will be raised above this view.</param>
4300         internal void RaiseAbove(View target)
4301         {
4302             var parentChildren = GetParent()?.Children;
4303
4304             if (parentChildren != null)
4305             {
4306                 int currentIndex = parentChildren.IndexOf(this);
4307                 int targetIndex = parentChildren.IndexOf(target);
4308
4309                 if (currentIndex < 0 || targetIndex < 0 ||
4310                     currentIndex >= parentChildren.Count || targetIndex >= parentChildren.Count)
4311                 {
4312                     NUILog.Error("index should be bigger than 0 and less than children of layer count");
4313                     return;
4314                 }
4315                 // If the currentIndex is less than the target index and the target has the same parent.
4316                 if (currentIndex < targetIndex)
4317                 {
4318                     parentChildren.Remove(this);
4319                     parentChildren.Insert(targetIndex, this);
4320
4321                     Interop.NDalic.RaiseAbove(swigCPtr, View.getCPtr(target));
4322                     if (NDalicPINVOKE.SWIGPendingException.Pending)
4323                         throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4324                 }
4325             }
4326
4327         }
4328
4329         /// <summary>
4330         /// Lowers the view to below the target view.
4331         /// </summary>
4332         /// <remarks>The sibling order of views within the parent will be updated automatically.
4333         /// Lowering this view below views with the same sibling order as each other will lower this view above them.
4334         /// Once a raise or lower API is used that view will then have an exclusive sibling order independent of insertion.
4335         /// </remarks>
4336         /// <param name="target">Will be lowered below this view.</param>
4337         internal void LowerBelow(View target)
4338         {
4339             var parentChildren = GetParent()?.Children;
4340
4341             if (parentChildren != null)
4342             {
4343                 int currentIndex = parentChildren.IndexOf(this);
4344                 int targetIndex = parentChildren.IndexOf(target);
4345                 if (currentIndex < 0 || targetIndex < 0 ||
4346                    currentIndex >= parentChildren.Count || targetIndex >= parentChildren.Count)
4347                 {
4348                     NUILog.Error("index should be bigger than 0 and less than children of layer count");
4349                     return;
4350                 }
4351
4352                 // If the currentIndex is not already the 0th index and the target has the same parent.
4353                 if ((currentIndex != 0) && (targetIndex != -1) &&
4354                     (currentIndex > targetIndex))
4355                 {
4356                     parentChildren.Remove(this);
4357                     parentChildren.Insert(targetIndex, this);
4358
4359                     Interop.NDalic.LowerBelow(swigCPtr, View.getCPtr(target));
4360                     if (NDalicPINVOKE.SWIGPendingException.Pending)
4361                         throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4362                 }
4363             }
4364
4365         }
4366
4367         internal string GetName()
4368         {
4369             string ret = Interop.Actor.Actor_GetName(swigCPtr);
4370             if (NDalicPINVOKE.SWIGPendingException.Pending)
4371                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4372             return ret;
4373         }
4374
4375         internal void SetName(string name)
4376         {
4377             Interop.Actor.Actor_SetName(swigCPtr, name);
4378             if (NDalicPINVOKE.SWIGPendingException.Pending)
4379                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4380         }
4381
4382         internal uint GetId()
4383         {
4384             uint ret = Interop.Actor.Actor_GetId(swigCPtr);
4385             if (NDalicPINVOKE.SWIGPendingException.Pending)
4386                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4387             return ret;
4388         }
4389
4390         internal bool IsRoot()
4391         {
4392             bool ret = Interop.ActorInternal.Actor_IsRoot(swigCPtr);
4393             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4394             return ret;
4395         }
4396
4397         internal bool OnWindow()
4398         {
4399             bool ret = Interop.Actor.Actor_OnStage(swigCPtr);
4400             if (NDalicPINVOKE.SWIGPendingException.Pending)
4401                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4402             return ret;
4403         }
4404
4405         internal View FindChildById(uint id)
4406         {
4407             //to fix memory leak issue, match the handle count with native side.
4408             IntPtr cPtr = Interop.Actor.Actor_FindChildById(swigCPtr, id);
4409             HandleRef CPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
4410             View ret = Registry.GetManagedBaseHandleFromNativePtr(CPtr.Handle) as View;
4411             Interop.BaseHandle.delete_BaseHandle(CPtr);
4412             CPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
4413
4414             if (NDalicPINVOKE.SWIGPendingException.Pending)
4415                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4416             return ret;
4417         }
4418
4419         internal void SetParentOrigin(Vector3 origin)
4420         {
4421             Interop.ActorInternal.Actor_SetParentOrigin(swigCPtr, Vector3.getCPtr(origin));
4422             if (NDalicPINVOKE.SWIGPendingException.Pending)
4423                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4424         }
4425
4426         internal Vector3 GetCurrentParentOrigin()
4427         {
4428             Vector3 ret = new Vector3(Interop.ActorInternal.Actor_GetCurrentParentOrigin(swigCPtr), true);
4429             if (NDalicPINVOKE.SWIGPendingException.Pending)
4430                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4431             return ret;
4432         }
4433
4434         internal void SetAnchorPoint(Vector3 anchorPoint)
4435         {
4436             Interop.Actor.Actor_SetAnchorPoint(swigCPtr, Vector3.getCPtr(anchorPoint));
4437             if (NDalicPINVOKE.SWIGPendingException.Pending)
4438                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4439         }
4440
4441         internal Vector3 GetCurrentAnchorPoint()
4442         {
4443             Vector3 ret = new Vector3(Interop.ActorInternal.Actor_GetCurrentAnchorPoint(swigCPtr), true);
4444             if (NDalicPINVOKE.SWIGPendingException.Pending)
4445                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4446             return ret;
4447         }
4448
4449         internal void SetSize(float width, float height)
4450         {
4451             Interop.ActorInternal.Actor_SetSize__SWIG_0(swigCPtr, width, height);
4452             if (NDalicPINVOKE.SWIGPendingException.Pending)
4453                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4454         }
4455
4456         internal void SetSize(float width, float height, float depth)
4457         {
4458             Interop.ActorInternal.Actor_SetSize__SWIG_1(swigCPtr, width, height, depth);
4459             if (NDalicPINVOKE.SWIGPendingException.Pending)
4460                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4461         }
4462
4463         internal void SetSize(Vector2 size)
4464         {
4465             Interop.ActorInternal.Actor_SetSize__SWIG_2(swigCPtr, Vector2.getCPtr(size));
4466             if (NDalicPINVOKE.SWIGPendingException.Pending)
4467                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4468         }
4469
4470         internal void SetSize(Vector3 size)
4471         {
4472             Interop.ActorInternal.Actor_SetSize__SWIG_3(swigCPtr, Vector3.getCPtr(size));
4473             if (NDalicPINVOKE.SWIGPendingException.Pending)
4474                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4475         }
4476
4477         internal Vector3 GetTargetSize()
4478         {
4479             Vector3 ret = new Vector3(Interop.ActorInternal.Actor_GetTargetSize(swigCPtr), true);
4480             if (NDalicPINVOKE.SWIGPendingException.Pending)
4481                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4482             return ret;
4483         }
4484
4485         internal Size2D GetCurrentSize()
4486         {
4487             Size ret = new Size(Interop.Actor.Actor_GetCurrentSize(swigCPtr), true);
4488             if (NDalicPINVOKE.SWIGPendingException.Pending)
4489                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4490             Size2D size = new Size2D((int)ret.Width, (int)ret.Height);
4491             return size;
4492         }
4493
4494         internal Vector3 GetNaturalSize()
4495         {
4496             Vector3 ret = new Vector3(Interop.Actor.Actor_GetNaturalSize(swigCPtr), true);
4497             if (NDalicPINVOKE.SWIGPendingException.Pending)
4498                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4499             return ret;
4500         }
4501
4502         internal void SetPosition(float x, float y)
4503         {
4504             Interop.ActorInternal.Actor_SetPosition__SWIG_0(swigCPtr, x, y);
4505             if (NDalicPINVOKE.SWIGPendingException.Pending)
4506                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4507         }
4508
4509         internal void SetPosition(float x, float y, float z)
4510         {
4511             Interop.ActorInternal.Actor_SetPosition__SWIG_1(swigCPtr, x, y, z);
4512             if (NDalicPINVOKE.SWIGPendingException.Pending)
4513                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4514         }
4515
4516         internal void SetPosition(Vector3 position)
4517         {
4518             Interop.ActorInternal.Actor_SetPosition__SWIG_2(swigCPtr, Vector3.getCPtr(position));
4519             if (NDalicPINVOKE.SWIGPendingException.Pending)
4520                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4521         }
4522
4523         internal void SetX(float x)
4524         {
4525             Interop.ActorInternal.Actor_SetX(swigCPtr, x);
4526             if (NDalicPINVOKE.SWIGPendingException.Pending)
4527                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4528         }
4529
4530         internal void SetY(float y)
4531         {
4532             Interop.ActorInternal.Actor_SetY(swigCPtr, y);
4533             if (NDalicPINVOKE.SWIGPendingException.Pending)
4534                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4535         }
4536
4537         internal void SetZ(float z)
4538         {
4539             Interop.ActorInternal.Actor_SetZ(swigCPtr, z);
4540             if (NDalicPINVOKE.SWIGPendingException.Pending)
4541                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4542         }
4543
4544         internal void TranslateBy(Vector3 distance)
4545         {
4546             Interop.ActorInternal.Actor_TranslateBy(swigCPtr, Vector3.getCPtr(distance));
4547             if (NDalicPINVOKE.SWIGPendingException.Pending)
4548                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4549         }
4550
4551         internal Position GetCurrentPosition()
4552         {
4553             Position ret = new Position(Interop.Actor.Actor_GetCurrentPosition(swigCPtr), true);
4554             if (NDalicPINVOKE.SWIGPendingException.Pending)
4555                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4556             return ret;
4557         }
4558
4559         internal Vector3 GetCurrentWorldPosition()
4560         {
4561             Vector3 ret = new Vector3(Interop.ActorInternal.Actor_GetCurrentWorldPosition(swigCPtr), true);
4562             if (NDalicPINVOKE.SWIGPendingException.Pending)
4563                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4564             return ret;
4565         }
4566
4567         internal void SetInheritPosition(bool inherit)
4568         {
4569             Interop.ActorInternal.Actor_SetInheritPosition(swigCPtr, inherit);
4570             if (NDalicPINVOKE.SWIGPendingException.Pending)
4571                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4572         }
4573
4574         internal bool IsPositionInherited()
4575         {
4576             bool ret = Interop.ActorInternal.Actor_IsPositionInherited(swigCPtr);
4577             if (NDalicPINVOKE.SWIGPendingException.Pending)
4578                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4579             return ret;
4580         }
4581
4582         internal void SetOrientation(Degree angle, Vector3 axis)
4583         {
4584             Interop.ActorInternal.Actor_SetOrientation__SWIG_0(swigCPtr, Degree.getCPtr(angle), Vector3.getCPtr(axis));
4585             if (NDalicPINVOKE.SWIGPendingException.Pending)
4586                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4587         }
4588
4589         internal void SetOrientation(Radian angle, Vector3 axis)
4590         {
4591             Interop.ActorInternal.Actor_SetOrientation__SWIG_1(swigCPtr, Radian.getCPtr(angle), Vector3.getCPtr(axis));
4592             if (NDalicPINVOKE.SWIGPendingException.Pending)
4593                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4594         }
4595
4596         internal void SetOrientation(Rotation orientation)
4597         {
4598             Interop.ActorInternal.Actor_SetOrientation__SWIG_2(swigCPtr, Rotation.getCPtr(orientation));
4599             if (NDalicPINVOKE.SWIGPendingException.Pending)
4600                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4601         }
4602
4603         internal void RotateBy(Degree angle, Vector3 axis)
4604         {
4605             Interop.ActorInternal.Actor_RotateBy__SWIG_0(swigCPtr, Degree.getCPtr(angle), Vector3.getCPtr(axis));
4606             if (NDalicPINVOKE.SWIGPendingException.Pending)
4607                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4608         }
4609
4610         internal void RotateBy(Radian angle, Vector3 axis)
4611         {
4612             Interop.ActorInternal.Actor_RotateBy__SWIG_1(swigCPtr, Radian.getCPtr(angle), Vector3.getCPtr(axis));
4613             if (NDalicPINVOKE.SWIGPendingException.Pending)
4614                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4615         }
4616
4617         internal void RotateBy(Rotation relativeRotation)
4618         {
4619             Interop.ActorInternal.Actor_RotateBy__SWIG_2(swigCPtr, Rotation.getCPtr(relativeRotation));
4620             if (NDalicPINVOKE.SWIGPendingException.Pending)
4621                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4622         }
4623
4624         internal Rotation GetCurrentOrientation()
4625         {
4626             Rotation ret = new Rotation(Interop.ActorInternal.Actor_GetCurrentOrientation(swigCPtr), true);
4627             if (NDalicPINVOKE.SWIGPendingException.Pending)
4628                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4629             return ret;
4630         }
4631
4632         internal void SetInheritOrientation(bool inherit)
4633         {
4634             Interop.ActorInternal.Actor_SetInheritOrientation(swigCPtr, inherit);
4635             if (NDalicPINVOKE.SWIGPendingException.Pending)
4636                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4637         }
4638
4639         internal bool IsOrientationInherited()
4640         {
4641             bool ret = Interop.ActorInternal.Actor_IsOrientationInherited(swigCPtr);
4642             if (NDalicPINVOKE.SWIGPendingException.Pending)
4643                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4644             return ret;
4645         }
4646
4647         internal Rotation GetCurrentWorldOrientation()
4648         {
4649             Rotation ret = new Rotation(Interop.ActorInternal.Actor_GetCurrentWorldOrientation(swigCPtr), true);
4650             if (NDalicPINVOKE.SWIGPendingException.Pending)
4651                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4652             return ret;
4653         }
4654
4655         internal void SetScale(float scale)
4656         {
4657             Interop.ActorInternal.Actor_SetScale__SWIG_0(swigCPtr, scale);
4658             if (NDalicPINVOKE.SWIGPendingException.Pending)
4659                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4660         }
4661
4662         internal void SetScale(float scaleX, float scaleY, float scaleZ)
4663         {
4664             Interop.ActorInternal.Actor_SetScale__SWIG_1(swigCPtr, scaleX, scaleY, scaleZ);
4665             if (NDalicPINVOKE.SWIGPendingException.Pending)
4666                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4667         }
4668
4669         internal void SetScale(Vector3 scale)
4670         {
4671             Interop.ActorInternal.Actor_SetScale__SWIG_2(swigCPtr, Vector3.getCPtr(scale));
4672             if (NDalicPINVOKE.SWIGPendingException.Pending)
4673                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4674         }
4675
4676         internal void ScaleBy(Vector3 relativeScale)
4677         {
4678             Interop.ActorInternal.Actor_ScaleBy(swigCPtr, Vector3.getCPtr(relativeScale));
4679             if (NDalicPINVOKE.SWIGPendingException.Pending)
4680                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4681         }
4682
4683         internal Vector3 GetCurrentScale()
4684         {
4685             Vector3 ret = new Vector3(Interop.ActorInternal.Actor_GetCurrentScale(swigCPtr), true);
4686             if (NDalicPINVOKE.SWIGPendingException.Pending)
4687                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4688             return ret;
4689         }
4690
4691         internal Vector3 GetCurrentWorldScale()
4692         {
4693             Vector3 ret = new Vector3(Interop.ActorInternal.Actor_GetCurrentWorldScale(swigCPtr), true);
4694             if (NDalicPINVOKE.SWIGPendingException.Pending)
4695                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4696             return ret;
4697         }
4698
4699         internal void SetInheritScale(bool inherit)
4700         {
4701             Interop.ActorInternal.Actor_SetInheritScale(swigCPtr, inherit);
4702             if (NDalicPINVOKE.SWIGPendingException.Pending)
4703                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4704         }
4705
4706         internal bool IsScaleInherited()
4707         {
4708             bool ret = Interop.ActorInternal.Actor_IsScaleInherited(swigCPtr);
4709             if (NDalicPINVOKE.SWIGPendingException.Pending)
4710                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4711             return ret;
4712         }
4713
4714         internal Matrix GetCurrentWorldMatrix()
4715         {
4716             Matrix ret = new Matrix(Interop.ActorInternal.Actor_GetCurrentWorldMatrix(swigCPtr), true);
4717             if (NDalicPINVOKE.SWIGPendingException.Pending)
4718                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4719             return ret;
4720         }
4721
4722         internal void SetVisible(bool visible)
4723         {
4724             Interop.Actor.Actor_SetVisible(swigCPtr, visible);
4725             if (NDalicPINVOKE.SWIGPendingException.Pending)
4726                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4727         }
4728
4729         internal bool IsVisible()
4730         {
4731             bool ret = Interop.ActorInternal.Actor_IsVisible(swigCPtr);
4732             if (NDalicPINVOKE.SWIGPendingException.Pending)
4733                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4734             return ret;
4735         }
4736
4737         internal void SetOpacity(float opacity)
4738         {
4739             Interop.ActorInternal.Actor_SetOpacity(swigCPtr, opacity);
4740             if (NDalicPINVOKE.SWIGPendingException.Pending)
4741                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4742         }
4743
4744         internal float GetCurrentOpacity()
4745         {
4746             float ret = Interop.ActorInternal.Actor_GetCurrentOpacity(swigCPtr);
4747             if (NDalicPINVOKE.SWIGPendingException.Pending)
4748                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4749             return ret;
4750         }
4751
4752         internal void SetColor(Vector4 color)
4753         {
4754             Interop.ActorInternal.Actor_SetColor(swigCPtr, Vector4.getCPtr(color));
4755             if (NDalicPINVOKE.SWIGPendingException.Pending)
4756                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4757         }
4758
4759         internal Vector4 GetCurrentColor()
4760         {
4761             Vector4 ret = new Vector4(Interop.ActorInternal.Actor_GetCurrentColor(swigCPtr), true);
4762             if (NDalicPINVOKE.SWIGPendingException.Pending)
4763                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4764             return ret;
4765         }
4766
4767         internal void SetColorMode(ColorMode colorMode)
4768         {
4769             Interop.ActorInternal.Actor_SetColorMode(swigCPtr, (int)colorMode);
4770             if (NDalicPINVOKE.SWIGPendingException.Pending)
4771                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4772         }
4773
4774         internal ColorMode GetColorMode()
4775         {
4776             ColorMode ret = (ColorMode)Interop.ActorInternal.Actor_GetColorMode(swigCPtr);
4777             if (NDalicPINVOKE.SWIGPendingException.Pending)
4778                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4779             return ret;
4780         }
4781
4782         internal Vector4 GetCurrentWorldColor()
4783         {
4784             Vector4 ret = new Vector4(Interop.ActorInternal.Actor_GetCurrentWorldColor(swigCPtr), true);
4785             if (NDalicPINVOKE.SWIGPendingException.Pending)
4786                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4787             return ret;
4788         }
4789
4790         internal void SetDrawMode(DrawModeType drawMode)
4791         {
4792             Interop.ActorInternal.Actor_SetDrawMode(swigCPtr, (int)drawMode);
4793             if (NDalicPINVOKE.SWIGPendingException.Pending)
4794                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4795         }
4796
4797         internal DrawModeType GetDrawMode()
4798         {
4799             DrawModeType ret = (DrawModeType)Interop.ActorInternal.Actor_GetDrawMode(swigCPtr);
4800             if (NDalicPINVOKE.SWIGPendingException.Pending)
4801                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4802             return ret;
4803         }
4804
4805         internal void SetKeyboardFocusable(bool focusable)
4806         {
4807             Interop.ActorInternal.Actor_SetKeyboardFocusable(swigCPtr, focusable);
4808             if (NDalicPINVOKE.SWIGPendingException.Pending)
4809                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4810         }
4811
4812         internal bool IsKeyboardFocusable()
4813         {
4814             bool ret = Interop.ActorInternal.Actor_IsKeyboardFocusable(swigCPtr);
4815             if (NDalicPINVOKE.SWIGPendingException.Pending)
4816                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4817             return ret;
4818         }
4819
4820         internal void SetResizePolicy(ResizePolicyType policy, DimensionType dimension)
4821         {
4822             Interop.Actor.Actor_SetResizePolicy(swigCPtr, (int)policy, (int)dimension);
4823             if (NDalicPINVOKE.SWIGPendingException.Pending)
4824                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4825         }
4826
4827         internal ResizePolicyType GetResizePolicy(DimensionType dimension)
4828         {
4829             ResizePolicyType ret = (ResizePolicyType)Interop.Actor.Actor_GetResizePolicy(swigCPtr, (int)dimension);
4830             if (NDalicPINVOKE.SWIGPendingException.Pending)
4831                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4832             return ret;
4833         }
4834
4835         internal Vector3 GetSizeModeFactor()
4836         {
4837             Vector3 ret = new Vector3(Interop.Actor.Actor_GetSizeModeFactor(swigCPtr), true);
4838             if (NDalicPINVOKE.SWIGPendingException.Pending)
4839                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4840             return ret;
4841         }
4842
4843         internal void SetMinimumSize(Vector2 size)
4844         {
4845             Interop.ActorInternal.Actor_SetMinimumSize(swigCPtr, Vector2.getCPtr(size));
4846             if (NDalicPINVOKE.SWIGPendingException.Pending)
4847                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4848         }
4849
4850         internal Vector2 GetMinimumSize()
4851         {
4852             Vector2 ret = new Vector2(Interop.ActorInternal.Actor_GetMinimumSize(swigCPtr), true);
4853             if (NDalicPINVOKE.SWIGPendingException.Pending)
4854                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4855             return ret;
4856         }
4857
4858         internal void SetMaximumSize(Vector2 size)
4859         {
4860             Interop.ActorInternal.Actor_SetMaximumSize(swigCPtr, Vector2.getCPtr(size));
4861             if (NDalicPINVOKE.SWIGPendingException.Pending)
4862                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4863         }
4864
4865         internal Vector2 GetMaximumSize()
4866         {
4867             Vector2 ret = new Vector2(Interop.ActorInternal.Actor_GetMaximumSize(swigCPtr), true);
4868             if (NDalicPINVOKE.SWIGPendingException.Pending)
4869                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4870             return ret;
4871         }
4872
4873         internal int GetHierarchyDepth()
4874         {
4875             int ret = Interop.Actor.Actor_GetHierarchyDepth(swigCPtr);
4876             if (NDalicPINVOKE.SWIGPendingException.Pending)
4877                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4878             return ret;
4879         }
4880
4881         internal uint GetRendererCount()
4882         {
4883             uint ret = Interop.Actor.Actor_GetRendererCount(swigCPtr);
4884             if (NDalicPINVOKE.SWIGPendingException.Pending)
4885                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4886             return ret;
4887         }
4888
4889         internal TouchDataSignal TouchSignal()
4890         {
4891             TouchDataSignal ret = new TouchDataSignal(Interop.ActorSignal.Actor_TouchSignal(swigCPtr), false);
4892             if (NDalicPINVOKE.SWIGPendingException.Pending)
4893                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4894             return ret;
4895         }
4896
4897         internal HoverSignal HoveredSignal()
4898         {
4899             HoverSignal ret = new HoverSignal(Interop.ActorSignal.Actor_HoveredSignal(swigCPtr), false);
4900             if (NDalicPINVOKE.SWIGPendingException.Pending)
4901                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4902             return ret;
4903         }
4904
4905         internal WheelSignal WheelEventSignal()
4906         {
4907             WheelSignal ret = new WheelSignal(Interop.ActorSignal.Actor_WheelEventSignal(swigCPtr), false);
4908             if (NDalicPINVOKE.SWIGPendingException.Pending)
4909                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4910             return ret;
4911         }
4912
4913         internal ViewSignal OnWindowSignal()
4914         {
4915             ViewSignal ret = new ViewSignal(Interop.ActorSignal.Actor_OnStageSignal(swigCPtr), false);
4916             if (NDalicPINVOKE.SWIGPendingException.Pending)
4917                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4918             return ret;
4919         }
4920
4921         internal ViewSignal OffWindowSignal()
4922         {
4923             ViewSignal ret = new ViewSignal(Interop.ActorSignal.Actor_OffStageSignal(swigCPtr), false);
4924             if (NDalicPINVOKE.SWIGPendingException.Pending)
4925                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4926             return ret;
4927         }
4928
4929         internal ViewSignal OnRelayoutSignal()
4930         {
4931             ViewSignal ret = new ViewSignal(Interop.ActorSignal.Actor_OnRelayoutSignal(swigCPtr), false);
4932             if (NDalicPINVOKE.SWIGPendingException.Pending)
4933                 throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4934             return ret;
4935         }
4936
4937         internal ViewVisibilityChangedSignal VisibilityChangedSignal(View view)
4938         {
4939             ViewVisibilityChangedSignal ret = new ViewVisibilityChangedSignal(Interop.NDalic.VisibilityChangedSignal(View.getCPtr(view)), false);
4940             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4941             return ret;
4942         }
4943
4944         internal ViewLayoutDirectionChangedSignal LayoutDirectionChangedSignal(View view)
4945         {
4946             ViewLayoutDirectionChangedSignal ret = new ViewLayoutDirectionChangedSignal(Interop.Layout.LayoutDirectionChangedSignal(View.getCPtr(view)), false);
4947             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4948             return ret;
4949         }
4950
4951         internal ViewSignal ResourcesLoadedSignal()
4952         {
4953             ViewSignal ret = new ViewSignal(Interop.View.ResourceReadySignal(swigCPtr), false);
4954             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4955             return ret;
4956         }
4957
4958         internal static global::System.Runtime.InteropServices.HandleRef getCPtr(View obj)
4959         {
4960             return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
4961         }
4962
4963         internal bool IsTopLevelView()
4964         {
4965             if (GetParent() is Layer)
4966             {
4967                 return true;
4968             }
4969             return false;
4970         }
4971
4972         internal void SetKeyInputFocus()
4973         {
4974             Interop.ViewInternal.View_SetKeyInputFocus(swigCPtr);
4975             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4976         }
4977
4978         internal void ClearKeyInputFocus()
4979         {
4980             Interop.ViewInternal.View_ClearKeyInputFocus(swigCPtr);
4981             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4982         }
4983
4984         internal PinchGestureDetector GetPinchGestureDetector()
4985         {
4986             PinchGestureDetector ret = new PinchGestureDetector(Interop.ViewInternal.View_GetPinchGestureDetector(swigCPtr), true);
4987             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4988             return ret;
4989         }
4990
4991         internal PanGestureDetector GetPanGestureDetector()
4992         {
4993             PanGestureDetector ret = new PanGestureDetector(Interop.ViewInternal.View_GetPanGestureDetector(swigCPtr), true);
4994             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
4995             return ret;
4996         }
4997
4998         internal TapGestureDetector GetTapGestureDetector()
4999         {
5000             TapGestureDetector ret = new TapGestureDetector(Interop.ViewInternal.View_GetTapGestureDetector(swigCPtr), true);
5001             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
5002             return ret;
5003         }
5004
5005         internal LongPressGestureDetector GetLongPressGestureDetector()
5006         {
5007             LongPressGestureDetector ret = new LongPressGestureDetector(Interop.ViewInternal.View_GetLongPressGestureDetector(swigCPtr), true);
5008             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
5009             return ret;
5010         }
5011
5012         internal void SetBackgroundColor(Vector4 color)
5013         {
5014             Interop.ViewInternal.View_SetBackgroundColor(swigCPtr, Vector4.getCPtr(color));
5015             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
5016         }
5017
5018         internal Vector4 GetBackgroundColor()
5019         {
5020             Vector4 ret = new Vector4(Interop.ViewInternal.View_GetBackgroundColor(swigCPtr), true);
5021             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
5022             return ret;
5023         }
5024
5025         internal void SetBackgroundImage(Image image)
5026         {
5027             Interop.ViewInternal.View_SetBackgroundImage(swigCPtr, Image.getCPtr(image));
5028             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
5029         }
5030
5031         internal ControlKeySignal KeyEventSignal()
5032         {
5033             ControlKeySignal ret = new ControlKeySignal(Interop.ViewSignal.View_KeyEventSignal(swigCPtr), false);
5034             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
5035             return ret;
5036         }
5037
5038         internal KeyInputFocusSignal KeyInputFocusGainedSignal()
5039         {
5040             KeyInputFocusSignal ret = new KeyInputFocusSignal(Interop.ViewSignal.View_KeyInputFocusGainedSignal(swigCPtr), false);
5041             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
5042             return ret;
5043         }
5044
5045         internal KeyInputFocusSignal KeyInputFocusLostSignal()
5046         {
5047             KeyInputFocusSignal ret = new KeyInputFocusSignal(Interop.ViewSignal.View_KeyInputFocusLostSignal(swigCPtr), false);
5048             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
5049             return ret;
5050         }
5051
5052         internal IntPtr GetPtrfromView()
5053         {
5054             return (IntPtr)swigCPtr;
5055         }
5056
5057         internal void SetLayout(LayoutItem layout)
5058         {
5059             Interop.Layout.SetLayout__SWIG_1(View.getCPtr(this), LayoutItem.getCPtr(layout));
5060             layout.LayoutChildren.Clear();
5061             foreach (View view in Children)
5062             {
5063                 layout.LayoutChildren.Add(view.Layout);
5064             }
5065         }
5066
5067         internal ResourceLoadingStatusType GetBackgroundResourceStatus()
5068         {
5069             return (ResourceLoadingStatusType)Interop.View.View_GetVisualResourceStatus(this.swigCPtr, Property.BACKGROUND);
5070         }
5071
5072         /// <summary>
5073         /// you can override it to clean-up your own resources.
5074         /// </summary>
5075         /// <param name="type">DisposeTypes</param>
5076         /// <since_tizen> 3 </since_tizen>
5077         protected override void Dispose(DisposeTypes type)
5078         {
5079             if (disposed)
5080             {
5081                 return;
5082             }
5083
5084             if (type == DisposeTypes.Explicit)
5085             {
5086                 //Called by User
5087                 //Release your own managed resources here.
5088                 //You should release all of your own disposable objects here.
5089             }
5090
5091             //Release your own unmanaged resources here.
5092             //You should not access any managed member here except static instance.
5093             //because the execution order of Finalizes is non-deterministic.
5094             if (this != null)
5095             {
5096                 DisConnectFromSignals();
5097             }
5098
5099             if (swigCPtr.Handle != global::System.IntPtr.Zero)
5100             {
5101                 if (swigCMemOwn)
5102                 {
5103                     swigCMemOwn = false;
5104                     Interop.View.delete_View(swigCPtr);
5105                 }
5106                 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
5107             }
5108
5109             foreach (View view in Children)
5110             {
5111                 view.InternalParent = null;
5112             }
5113
5114             base.Dispose(type);
5115
5116         }
5117
5118         private void OnSize2DChanged(int width, int height)
5119         {
5120             Size2D = new Size2D(width, height);
5121         }
5122
5123         private void OnPosition2DChanged(int x, int y)
5124         {
5125             Position2D = new Position2D(x, y);
5126         }
5127
5128         private void DisConnectFromSignals()
5129         {
5130             // Save current CPtr.
5131             global::System.Runtime.InteropServices.HandleRef currentCPtr = swigCPtr;
5132
5133             // Use BaseHandle CPtr as current might have been deleted already in derived classes.
5134             swigCPtr = GetBaseHandleCPtrHandleRef;
5135
5136             if (_onRelayoutEventCallback != null)
5137             {
5138                 this.OnRelayoutSignal().Disconnect(_onRelayoutEventCallback);
5139             }
5140
5141             if (_offWindowEventCallback != null)
5142             {
5143                 this.OffWindowSignal().Disconnect(_offWindowEventCallback);
5144             }
5145
5146             if (_onWindowEventCallback != null)
5147             {
5148                 this.OnWindowSignal().Disconnect(_onWindowEventCallback);
5149             }
5150
5151             if (_wheelEventCallback != null)
5152             {
5153                 this.WheelEventSignal().Disconnect(_wheelEventCallback);
5154             }
5155
5156             if (_hoverEventCallback != null)
5157             {
5158                 this.HoveredSignal().Disconnect(_hoverEventCallback);
5159             }
5160
5161             if (_touchDataCallback != null)
5162             {
5163                 this.TouchSignal().Disconnect(_touchDataCallback);
5164             }
5165
5166             if (_ResourcesLoadedCallback != null)
5167             {
5168                 this.ResourcesLoadedSignal().Disconnect(_ResourcesLoadedCallback);
5169             }
5170
5171             if (_offWindowEventCallback != null)
5172             {
5173                 this.OffWindowSignal().Disconnect(_offWindowEventCallback);
5174             }
5175
5176             if (_onWindowEventCallback != null)
5177             {
5178                 this.OnWindowSignal().Disconnect(_onWindowEventCallback);
5179             }
5180
5181             if (_wheelEventCallback != null)
5182             {
5183                 this.WheelEventSignal().Disconnect(_wheelEventCallback);
5184             }
5185
5186             if (_hoverEventCallback != null)
5187             {
5188                 this.HoveredSignal().Disconnect(_hoverEventCallback);
5189             }
5190
5191             if (_touchDataCallback != null)
5192             {
5193                 this.TouchSignal().Disconnect(_touchDataCallback);
5194             }
5195
5196             if (_onRelayoutEventCallback != null)
5197             {
5198                 this.OnRelayoutSignal().Disconnect(_onRelayoutEventCallback);
5199             }
5200
5201             if (_keyCallback != null)
5202             {
5203                 this.KeyEventSignal().Disconnect(_keyCallback);
5204             }
5205
5206             if (_keyInputFocusLostCallback != null)
5207             {
5208                 this.KeyInputFocusLostSignal().Disconnect(_keyInputFocusLostCallback);
5209             }
5210
5211             if (_keyInputFocusGainedCallback != null)
5212             {
5213                 this.KeyInputFocusGainedSignal().Disconnect(_keyInputFocusGainedCallback);
5214             }
5215
5216             if (_backgroundResourceLoadedCallback != null)
5217             {
5218                 this.ResourcesLoadedSignal().Disconnect(_backgroundResourceLoadedCallback);
5219             }
5220
5221             if (_onWindowSendEventCallback != null)
5222             {
5223                 this.OnWindowSignal().Disconnect(_onWindowSendEventCallback);
5224             }
5225
5226             // BaseHandle CPtr is used in Registry and there is danger of deletion if we keep using it here.
5227             // Restore current CPtr.
5228             swigCPtr = currentCPtr;
5229         }
5230
5231         private void OnKeyInputFocusGained(IntPtr view)
5232         {
5233             if (_keyInputFocusGainedEventHandler != null)
5234             {
5235                 _keyInputFocusGainedEventHandler(this, null);
5236             }
5237         }
5238
5239         private void OnKeyInputFocusLost(IntPtr view)
5240         {
5241             if (_keyInputFocusLostEventHandler != null)
5242             {
5243                 _keyInputFocusLostEventHandler(this, null);
5244             }
5245         }
5246
5247         private bool OnKeyEvent(IntPtr view, IntPtr keyEvent)
5248         {
5249             if (keyEvent == global::System.IntPtr.Zero)
5250             {
5251                 NUILog.Error("keyEvent should not be null!");
5252                 return true;
5253             }
5254
5255             KeyEventArgs e = new KeyEventArgs();
5256
5257             bool result = false;
5258
5259             e.Key = Tizen.NUI.Key.GetKeyFromPtr(keyEvent);
5260
5261             if (_keyEventHandler != null)
5262             {
5263                 Delegate[] delegateList = _keyEventHandler.GetInvocationList();
5264
5265                 // Oring the result of each callback.
5266                 foreach (EventHandlerWithReturnType<object, KeyEventArgs, bool> del in delegateList)
5267                 {
5268                     result |= del(this, e);
5269                 }
5270             }
5271
5272             return result;
5273         }
5274
5275         // Callback for View OnRelayout signal
5276         private void OnRelayout(IntPtr data)
5277         {
5278             if (_onRelayoutEventHandler != null)
5279             {
5280                 _onRelayoutEventHandler(this, null);
5281             }
5282         }
5283
5284         // Callback for View TouchSignal
5285         private bool OnTouch(IntPtr view, IntPtr touchData)
5286         {
5287             if (touchData == global::System.IntPtr.Zero)
5288             {
5289                 NUILog.Error("touchData should not be null!");
5290                 return true;
5291             }
5292
5293             TouchEventArgs e = new TouchEventArgs();
5294
5295             e.Touch = Tizen.NUI.Touch.GetTouchFromPtr(touchData);
5296
5297             if (_touchDataEventHandler != null)
5298             {
5299                 return _touchDataEventHandler(this, e);
5300             }
5301             return false;
5302         }
5303
5304         // Callback for View Hover signal
5305         private bool OnHoverEvent(IntPtr view, IntPtr hoverEvent)
5306         {
5307             if (hoverEvent == global::System.IntPtr.Zero)
5308             {
5309                 NUILog.Error("hoverEvent should not be null!");
5310                 return true;
5311             }
5312
5313             HoverEventArgs e = new HoverEventArgs();
5314
5315             e.Hover = Tizen.NUI.Hover.GetHoverFromPtr(hoverEvent);
5316
5317             if (_hoverEventHandler != null)
5318             {
5319                 return _hoverEventHandler(this, e);
5320             }
5321             return false;
5322         }
5323
5324         // Callback for View Wheel signal
5325         private bool OnWheelEvent(IntPtr view, IntPtr wheelEvent)
5326         {
5327             if (wheelEvent == global::System.IntPtr.Zero)
5328             {
5329                 NUILog.Error("wheelEvent should not be null!");
5330                 return true;
5331             }
5332
5333             WheelEventArgs e = new WheelEventArgs();
5334
5335             e.Wheel = Tizen.NUI.Wheel.GetWheelFromPtr(wheelEvent);
5336
5337             if (_wheelEventHandler != null)
5338             {
5339                 return _wheelEventHandler(this, e);
5340             }
5341             return false;
5342         }
5343
5344         // Callback for View OnWindow signal
5345         private void OnWindow(IntPtr data)
5346         {
5347             if (_onWindowEventHandler != null)
5348             {
5349                 _onWindowEventHandler(this, null);
5350             }
5351         }
5352
5353         // Callback for View OffWindow signal
5354         private void OffWindow(IntPtr data)
5355         {
5356             if (_offWindowEventHandler != null)
5357             {
5358                 _offWindowEventHandler(this, null);
5359             }
5360         }
5361
5362         // Callback for View visibility change signal
5363         private void OnVisibilityChanged(IntPtr data, bool visibility, VisibilityChangeType type)
5364         {
5365             VisibilityChangedEventArgs e = new VisibilityChangedEventArgs();
5366             if (data != null)
5367             {
5368                 e.View = Registry.GetManagedBaseHandleFromNativePtr(data) as View;
5369             }
5370             e.Visibility = visibility;
5371             e.Type = type;
5372
5373             if (_visibilityChangedEventHandler != null)
5374             {
5375                 _visibilityChangedEventHandler(this, e);
5376             }
5377         }
5378
5379         // Callback for View layout direction change signal
5380         private void OnLayoutDirectionChanged(IntPtr data, ViewLayoutDirectionType type)
5381         {
5382             LayoutDirectionChangedEventArgs e = new LayoutDirectionChangedEventArgs();
5383             if (data != null)
5384             {
5385                 e.View = Registry.GetManagedBaseHandleFromNativePtr(data) as View;
5386             }
5387             e.Type = type;
5388
5389             if (_layoutDirectionChangedEventHandler != null)
5390             {
5391                 _layoutDirectionChangedEventHandler(this, e);
5392             }
5393         }
5394
5395         private void OnResourcesLoaded(IntPtr view)
5396         {
5397             if (_resourcesLoadedEventHandler != null)
5398             {
5399                 _resourcesLoadedEventHandler(this, null);
5400             }
5401         }
5402
5403         private View ConvertIdToView(uint id)
5404         {
5405             View view = null;
5406             if (GetParent() is View)
5407             {
5408                 View parentView = GetParent() as View;
5409                 view = parentView.FindChildById(id);
5410             }
5411
5412             if (!view)
5413             {
5414                 view = Window.Instance.GetRootLayer().FindChildById(id);
5415             }
5416
5417             return view;
5418         }
5419
5420         private void OnBackgroundResourceLoaded(IntPtr view)
5421         {
5422             BackgroundResourceLoadedEventArgs e = new BackgroundResourceLoadedEventArgs();
5423             e.Status = (ResourceLoadingStatusType)Interop.View.View_GetVisualResourceStatus(this.swigCPtr, Property.BACKGROUND);
5424
5425             if (_backgroundResourceLoadedEventHandler != null)
5426             {
5427                 _backgroundResourceLoadedEventHandler(this, e);
5428             }
5429         }
5430
5431         /// <summary>
5432         /// Event argument passed through the ChildAdded event.
5433         /// </summary>
5434         /// <since_tizen> 5 </since_tizen>
5435         public class ChildAddedEventArgs : EventArgs
5436         {
5437             /// <summary>
5438             /// Added child view at moment.
5439             /// </summary>
5440             /// <since_tizen> 5 </since_tizen>
5441             public View Added { get; set; }
5442         }
5443
5444         /// <summary>
5445         /// Event argument passed through the ChildRemoved event.
5446         /// </summary>
5447         /// <since_tizen> 5 </since_tizen>
5448         public class ChildRemovedEventArgs : EventArgs
5449         {
5450             /// <summary>
5451             /// Removed child view at moment.
5452             /// </summary>
5453             /// <since_tizen> 5 </since_tizen>
5454             public View Removed { get; set; }
5455         }
5456
5457         /// <summary>
5458         /// Event arguments that passed via the KeyEvent signal.
5459         /// </summary>
5460         /// <since_tizen> 3 </since_tizen>
5461         public class KeyEventArgs : EventArgs
5462         {
5463             private Key _key;
5464
5465             /// <summary>
5466             /// Key - is the key sent to the view.
5467             /// </summary>
5468             /// <since_tizen> 3 </since_tizen>
5469             public Key Key
5470             {
5471                 get
5472                 {
5473                     return _key;
5474                 }
5475                 set
5476                 {
5477                     _key = value;
5478                 }
5479             }
5480         }
5481
5482         /// <summary>
5483         /// Event arguments that passed via the touch signal.
5484         /// </summary>
5485         /// <since_tizen> 3 </since_tizen>
5486         public class TouchEventArgs : EventArgs
5487         {
5488             private Touch _touch;
5489
5490             /// <summary>
5491             /// Touch - contains the information of touch points.
5492             /// </summary>
5493             /// <since_tizen> 3 </since_tizen>
5494             public Touch Touch
5495             {
5496                 get
5497                 {
5498                     return _touch;
5499                 }
5500                 set
5501                 {
5502                     _touch = value;
5503                 }
5504             }
5505         }
5506
5507         /// <summary>
5508         /// Event arguments that passed via the hover signal.
5509         /// </summary>
5510         /// <since_tizen> 3 </since_tizen>
5511         public class HoverEventArgs : EventArgs
5512         {
5513             private Hover _hover;
5514
5515             /// <summary>
5516             /// Hover - contains touch points that represent the points that are currently being hovered or the points where a hover has stopped.
5517             /// </summary>
5518             /// <since_tizen> 3 </since_tizen>
5519             public Hover Hover
5520             {
5521                 get
5522                 {
5523                     return _hover;
5524                 }
5525                 set
5526                 {
5527                     _hover = value;
5528                 }
5529             }
5530         }
5531
5532         /// <summary>
5533         /// Event arguments that passed via the wheel signal.
5534         /// </summary>
5535         /// <since_tizen> 3 </since_tizen>
5536         public class WheelEventArgs : EventArgs
5537         {
5538             private Wheel _wheel;
5539
5540             /// <summary>
5541             /// WheelEvent - store a wheel rolling type: MOUSE_WHEEL or CUSTOM_WHEEL.
5542             /// </summary>
5543             /// <since_tizen> 3 </since_tizen>
5544             public Wheel Wheel
5545             {
5546                 get
5547                 {
5548                     return _wheel;
5549                 }
5550                 set
5551                 {
5552                     _wheel = value;
5553                 }
5554             }
5555         }
5556
5557         /// <summary>
5558         /// Event arguments of visibility changed.
5559         /// </summary>
5560         /// <since_tizen> 3 </since_tizen>
5561         public class VisibilityChangedEventArgs : EventArgs
5562         {
5563             private View _view;
5564             private bool _visibility;
5565             private VisibilityChangeType _type;
5566
5567             /// <summary>
5568             /// The view, or child of view, whose visibility has changed.
5569             /// </summary>
5570             /// <since_tizen> 3 </since_tizen>
5571             public View View
5572             {
5573                 get
5574                 {
5575                     return _view;
5576                 }
5577                 set
5578                 {
5579                     _view = value;
5580                 }
5581             }
5582
5583             /// <summary>
5584             /// Whether the view is now visible or not.
5585             /// </summary>
5586             /// <since_tizen> 3 </since_tizen>
5587             public bool Visibility
5588             {
5589                 get
5590                 {
5591                     return _visibility;
5592                 }
5593                 set
5594                 {
5595                     _visibility = value;
5596                 }
5597             }
5598
5599             /// <summary>
5600             /// Whether the view's visible property has changed or a parent's.
5601             /// </summary>
5602             /// <since_tizen> 3 </since_tizen>
5603             public VisibilityChangeType Type
5604             {
5605                 get
5606                 {
5607                     return _type;
5608                 }
5609                 set
5610                 {
5611                     _type = value;
5612                 }
5613             }
5614         }
5615
5616         /// <summary>
5617         /// Event arguments of layout direction changed.
5618         /// </summary>
5619         /// <since_tizen> 4 </since_tizen>
5620         public class LayoutDirectionChangedEventArgs : EventArgs
5621         {
5622             private View _view;
5623             private ViewLayoutDirectionType _type;
5624
5625             /// <summary>
5626             /// The view, or child of view, whose layout direction has changed.
5627             /// </summary>
5628             /// <since_tizen> 4 </since_tizen>
5629             public View View
5630             {
5631                 get
5632                 {
5633                     return _view;
5634                 }
5635                 set
5636                 {
5637                     _view = value;
5638                 }
5639             }
5640
5641             /// <summary>
5642             /// Whether the view's layout direction property has changed or a parent's.
5643             /// </summary>
5644             /// <since_tizen> 4 </since_tizen>
5645             public ViewLayoutDirectionType Type
5646             {
5647                 get
5648                 {
5649                     return _type;
5650                 }
5651                 set
5652                 {
5653                     _type = value;
5654                 }
5655             }
5656         }
5657
5658         internal class BackgroundResourceLoadedEventArgs : EventArgs
5659         {
5660             private ResourceLoadingStatusType status = ResourceLoadingStatusType.Invalid;
5661             public ResourceLoadingStatusType Status
5662             {
5663                 get
5664                 {
5665                     return status;
5666                 }
5667                 set
5668                 {
5669                     status = value;
5670                 }
5671             }
5672         }
5673
5674         internal class Property
5675         {
5676             internal static readonly int TOOLTIP = Interop.ViewProperty.View_Property_TOOLTIP_get();
5677             internal static readonly int STATE = Interop.ViewProperty.View_Property_STATE_get();
5678             internal static readonly int SUB_STATE = Interop.ViewProperty.View_Property_SUB_STATE_get();
5679             internal static readonly int LEFT_FOCUSABLE_VIEW_ID = Interop.ViewProperty.View_Property_LEFT_FOCUSABLE_ACTOR_ID_get();
5680             internal static readonly int RIGHT_FOCUSABLE_VIEW_ID = Interop.ViewProperty.View_Property_RIGHT_FOCUSABLE_ACTOR_ID_get();
5681             internal static readonly int UP_FOCUSABLE_VIEW_ID = Interop.ViewProperty.View_Property_UP_FOCUSABLE_ACTOR_ID_get();
5682             internal static readonly int DOWN_FOCUSABLE_VIEW_ID = Interop.ViewProperty.View_Property_DOWN_FOCUSABLE_ACTOR_ID_get();
5683             internal static readonly int STYLE_NAME = Interop.ViewProperty.View_Property_STYLE_NAME_get();
5684             internal static readonly int BACKGROUND = Interop.ViewProperty.View_Property_BACKGROUND_get();
5685             internal static readonly int SIBLING_ORDER = Interop.ActorProperty.Actor_Property_SIBLING_ORDER_get();
5686             internal static readonly int OPACITY = Interop.ActorProperty.Actor_Property_OPACITY_get();
5687             internal static readonly int SCREEN_POSITION = Interop.ActorProperty.Actor_Property_SCREEN_POSITION_get();
5688             internal static readonly int POSITION_USES_ANCHOR_POINT = Interop.ActorProperty.Actor_Property_POSITION_USES_ANCHOR_POINT_get();
5689             internal static readonly int PARENT_ORIGIN = Interop.ActorProperty.Actor_Property_PARENT_ORIGIN_get();
5690             internal static readonly int PARENT_ORIGIN_X = Interop.ActorProperty.Actor_Property_PARENT_ORIGIN_X_get();
5691             internal static readonly int PARENT_ORIGIN_Y = Interop.ActorProperty.Actor_Property_PARENT_ORIGIN_Y_get();
5692             internal static readonly int PARENT_ORIGIN_Z = Interop.ActorProperty.Actor_Property_PARENT_ORIGIN_Z_get();
5693             internal static readonly int ANCHOR_POINT = Interop.ActorProperty.Actor_Property_ANCHOR_POINT_get();
5694             internal static readonly int ANCHOR_POINT_X = Interop.ActorProperty.Actor_Property_ANCHOR_POINT_X_get();
5695             internal static readonly int ANCHOR_POINT_Y = Interop.ActorProperty.Actor_Property_ANCHOR_POINT_Y_get();
5696             internal static readonly int ANCHOR_POINT_Z = Interop.ActorProperty.Actor_Property_ANCHOR_POINT_Z_get();
5697             internal static readonly int SIZE = Interop.ActorProperty.Actor_Property_SIZE_get();
5698             internal static readonly int SIZE_WIDTH = Interop.ActorProperty.Actor_Property_SIZE_WIDTH_get();
5699             internal static readonly int SIZE_HEIGHT = Interop.ActorProperty.Actor_Property_SIZE_HEIGHT_get();
5700             internal static readonly int SIZE_DEPTH = Interop.ActorProperty.Actor_Property_SIZE_DEPTH_get();
5701             internal static readonly int POSITION = Interop.ActorProperty.Actor_Property_POSITION_get();
5702             internal static readonly int POSITION_X = Interop.ActorProperty.Actor_Property_POSITION_X_get();
5703             internal static readonly int POSITION_Y = Interop.ActorProperty.Actor_Property_POSITION_Y_get();
5704             internal static readonly int POSITION_Z = Interop.ActorProperty.Actor_Property_POSITION_Z_get();
5705             internal static readonly int WORLD_POSITION = Interop.ActorProperty.Actor_Property_WORLD_POSITION_get();
5706             internal static readonly int WORLD_POSITION_X = Interop.ActorProperty.Actor_Property_WORLD_POSITION_X_get();
5707             internal static readonly int WORLD_POSITION_Y = Interop.ActorProperty.Actor_Property_WORLD_POSITION_Y_get();
5708             internal static readonly int WORLD_POSITION_Z = Interop.ActorProperty.Actor_Property_WORLD_POSITION_Z_get();
5709             internal static readonly int ORIENTATION = Interop.ActorProperty.Actor_Property_ORIENTATION_get();
5710             internal static readonly int WORLD_ORIENTATION = Interop.ActorProperty.Actor_Property_WORLD_ORIENTATION_get();
5711             internal static readonly int SCALE = Interop.ActorProperty.Actor_Property_SCALE_get();
5712             internal static readonly int SCALE_X = Interop.ActorProperty.Actor_Property_SCALE_X_get();
5713             internal static readonly int SCALE_Y = Interop.ActorProperty.Actor_Property_SCALE_Y_get();
5714             internal static readonly int SCALE_Z = Interop.ActorProperty.Actor_Property_SCALE_Z_get();
5715             internal static readonly int WORLD_SCALE = Interop.ActorProperty.Actor_Property_WORLD_SCALE_get();
5716             internal static readonly int VISIBLE = Interop.ActorProperty.Actor_Property_VISIBLE_get();
5717             internal static readonly int WORLD_COLOR = Interop.ActorProperty.Actor_Property_WORLD_COLOR_get();
5718             internal static readonly int WORLD_MATRIX = Interop.ActorProperty.Actor_Property_WORLD_MATRIX_get();
5719             internal static readonly int NAME = Interop.ActorProperty.Actor_Property_NAME_get();
5720             internal static readonly int SENSITIVE = Interop.ActorProperty.Actor_Property_SENSITIVE_get();
5721             internal static readonly int LEAVE_REQUIRED = Interop.ActorProperty.Actor_Property_LEAVE_REQUIRED_get();
5722             internal static readonly int INHERIT_ORIENTATION = Interop.ActorProperty.Actor_Property_INHERIT_ORIENTATION_get();
5723             internal static readonly int INHERIT_SCALE = Interop.ActorProperty.Actor_Property_INHERIT_SCALE_get();
5724             internal static readonly int DRAW_MODE = Interop.ActorProperty.Actor_Property_DRAW_MODE_get();
5725             internal static readonly int SIZE_MODE_FACTOR = Interop.ActorProperty.Actor_Property_SIZE_MODE_FACTOR_get();
5726             internal static readonly int WIDTH_RESIZE_POLICY = Interop.ActorProperty.Actor_Property_WIDTH_RESIZE_POLICY_get();
5727             internal static readonly int HEIGHT_RESIZE_POLICY = Interop.ActorProperty.Actor_Property_HEIGHT_RESIZE_POLICY_get();
5728             internal static readonly int SIZE_SCALE_POLICY = Interop.ActorProperty.Actor_Property_SIZE_SCALE_POLICY_get();
5729             internal static readonly int WIDTH_FOR_HEIGHT = Interop.ActorProperty.Actor_Property_WIDTH_FOR_HEIGHT_get();
5730             internal static readonly int HEIGHT_FOR_WIDTH = Interop.ActorProperty.Actor_Property_HEIGHT_FOR_WIDTH_get();
5731             internal static readonly int MINIMUM_SIZE = Interop.ActorProperty.Actor_Property_MINIMUM_SIZE_get();
5732             internal static readonly int MAXIMUM_SIZE = Interop.ActorProperty.Actor_Property_MAXIMUM_SIZE_get();
5733             internal static readonly int INHERIT_POSITION = Interop.ActorProperty.Actor_Property_INHERIT_POSITION_get();
5734             internal static readonly int CLIPPING_MODE = Interop.ActorProperty.Actor_Property_CLIPPING_MODE_get();
5735             internal static readonly int INHERIT_LAYOUT_DIRECTION = Interop.ActorProperty.Actor_Property_INHERIT_LAYOUT_DIRECTION_get();
5736             internal static readonly int LAYOUT_DIRECTION = Interop.ActorProperty.Actor_Property_LAYOUT_DIRECTION_get();
5737             internal static readonly int MARGIN = Interop.ViewProperty.View_Property_MARGIN_get();
5738             internal static readonly int PADDING = Interop.ViewProperty.View_Property_PADDING_get();
5739         }
5740     }
5741 }