[NUI] Remove upcast
[platform/core/csapi/tizenfx.git] / src / Tizen.NUI / src / public / BaseComponents / View.cs
1 /*
2  * Copyright(c) 2020 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.Collections.Generic;
19 using System.ComponentModel;
20 using System.Runtime.InteropServices;
21 using Tizen.NUI.Binding;
22 using Tizen.NUI.Components;
23
24 namespace Tizen.NUI.BaseComponents
25 {
26     /// <summary>
27     /// View is the base class for all views.
28     /// </summary>
29     /// <since_tizen> 3 </since_tizen>
30     public partial class View : Container, IResourcesProvider
31     {
32         internal BackgroundExtraData backgroundExtraData;
33
34         private bool layoutSet = false;
35         private LayoutItem layout; // Exclusive layout assigned to this View.
36
37         // List of transitions paired with the condition that uses the transition.
38         private Dictionary<TransitionCondition, TransitionList> layoutTransitions;
39         private int widthPolicy = LayoutParamPolicies.WrapContent; // Layout width policy
40         private int heightPolicy = LayoutParamPolicies.WrapContent; // Layout height policy
41         private float weight = 0.0f; // Weighting of child View in a Layout
42         private bool backgroundImageSynchronosLoading = false;
43         private Dictionary<string, Transition> transDictionary = new Dictionary<string, Transition>();
44         private bool controlStatePropagation = false;
45         private ViewStyle viewStyle;
46         private bool themeChangeSensitive = false;
47         private bool excludeLayouting = false;
48         private LayoutTransition layoutTransition;
49
50         private ControlState controlStates = ControlState.Normal;
51
52         static View() { }
53
54         /// <summary>
55         /// Creates a new instance of a view.
56         /// </summary>
57         /// <since_tizen> 3 </since_tizen>
58         public View() : this(Interop.View.New(), true)
59         {
60             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
61         }
62
63         /// This will be public opened in next release of tizen after ACR done. Before ACR, it is used as HiddenAPI (InhouseAPI).
64         [EditorBrowsable(EditorBrowsableState.Never)]
65         public View(ViewStyle viewStyle) : this(Interop.View.New(), true, viewStyle)
66         {
67         }
68
69         /// <summary>
70         /// Create a new instance of a View with setting the status of shown or hidden.
71         /// </summary>
72         /// <param name="shown">false : Not displayed (hidden), true : displayed (shown)</param>
73         /// This will be public opened in next release of tizen after ACR done. Before ACR, it is used as HiddenAPI (InhouseAPI).
74         [EditorBrowsable(EditorBrowsableState.Never)]
75         public View(bool shown) : this(Interop.View.New(), true)
76         {
77             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
78             SetVisible(shown);
79         }
80
81         internal View(View uiControl, bool shown = true) : this(Interop.View.NewView(View.getCPtr(uiControl)), true)
82         {
83             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
84             if (!shown)
85             {
86                 SetVisible(false);
87             }
88
89             backgroundExtraData = uiControl.backgroundExtraData == null ? null : new BackgroundExtraData(uiControl.backgroundExtraData);
90         }
91
92         internal View(global::System.IntPtr cPtr, bool cMemoryOwn, ViewStyle viewStyle, bool shown = true) : this(cPtr, cMemoryOwn, shown)
93         {
94             InitializeStyle(viewStyle);
95         }
96
97         internal View(global::System.IntPtr cPtr, bool cMemoryOwn, bool shown = true) : base(cPtr, cMemoryOwn)
98         {
99             if (HasBody())
100             {
101                 PositionUsesPivotPoint = false;
102             }
103
104             //ToDo: this has memory leak and this is not used currently. will be fixed soon by using Event subscribing pattern.
105             //_onWindowSendEventCallback = SendViewAddedEventToWindow;
106             //this.OnWindowSignal().Connect(_onWindowSendEventCallback);
107
108             if (!shown)
109             {
110                 SetVisible(false);
111             }
112         }
113
114         internal View(ViewImpl implementation, bool shown = true) : this(Interop.View.NewViewInternal(ViewImpl.getCPtr(implementation)), true)
115         {
116             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
117
118             if (!shown)
119             {
120                 SetVisible(false);
121             }
122         }
123
124         /// <summary>
125         /// The event that is triggered when the View's ControlState is changed.
126         /// </summary>
127         [EditorBrowsable(EditorBrowsableState.Never)]
128         public event EventHandler<ControlStateChangedEventArgs> ControlStateChangedEvent;
129
130         internal event EventHandler<ControlStateChangedEventArgs> ControlStateChangeEventInternal;
131
132
133         /// <summary>
134         /// Flag to indicate if layout set explicitly via API call or View was automatically given a Layout.
135         /// </summary>
136         /// This will be public opened in tizen_5.5 after ACR done. Before ACR, need to be hidden as inhouse API.
137         [EditorBrowsable(EditorBrowsableState.Never)]
138         public bool LayoutSet
139         {
140             get
141             {
142                 return layoutSet;
143             }
144         }
145
146         /// <summary>
147         /// Flag to allow Layouting to be disabled for Views.
148         /// Once a View has a Layout set then any children added to Views from then on will receive
149         /// automatic Layouts.
150         /// </summary>
151         /// This will be public opened in tizen_5.5 after ACR done. Before ACR, need to be hidden as inhouse API.
152         [EditorBrowsable(EditorBrowsableState.Never)]
153         public static bool LayoutingDisabled { get; set; } = true;
154
155         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
156         [EditorBrowsable(EditorBrowsableState.Never)]
157         public ViewStyle ViewStyle
158         {
159             get
160             {
161                 if (null == viewStyle)
162                 {
163                     ApplyStyle(CreateViewStyle());
164                 }
165
166                 return viewStyle;
167             }
168         }
169
170         /// <summary>
171         /// Get/Set the control state.
172         /// </summary>
173         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
174         [EditorBrowsable(EditorBrowsableState.Never)]
175         public ControlState ControlState
176         {
177             get
178             {
179                 return controlStates;
180             }
181             protected set
182             {
183                 if (controlStates == value)
184                 {
185                     return;
186                 }
187
188                 var prevState = controlStates;
189
190                 controlStates = value;
191
192                 var changeInfo = new ControlStateChangedEventArgs(prevState, value);
193
194                 ControlStateChangeEventInternal?.Invoke(this, changeInfo);
195
196                 if (controlStatePropagation)
197                 {
198                     foreach (View child in Children)
199                     {
200                         child.ControlState = value;
201                     }
202                 }
203
204                 OnControlStateChanged(changeInfo);
205
206                 ControlStateChangedEvent?.Invoke(this, changeInfo);
207             }
208         }
209
210         /// This will be public opened in tizen_6.5 after ACR done. Before ACR, need to be hidden as inhouse API.
211         [EditorBrowsable(EditorBrowsableState.Never)]
212         public bool ExcludeLayouting
213         {
214             get
215             {
216                 return excludeLayouting;
217             }
218             set
219             {
220                 excludeLayouting = value;
221                 if (Layout != null && Layout.SetPositionByLayout == value)
222                 {
223                     Layout.SetPositionByLayout = !value;
224                     Layout.RequestLayout();
225                 }
226             }
227         }
228
229         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
230         [EditorBrowsable(EditorBrowsableState.Never)]
231         public bool IsResourcesCreated
232         {
233             get
234             {
235                 return Application.Current.IsResourcesCreated;
236             }
237         }
238
239         /// This will be public opened in tizen_5.0 after ACR done. Before ACR, need to be hidden as inhouse API.
240         [EditorBrowsable(EditorBrowsableState.Never)]
241         public ResourceDictionary XamlResources
242         {
243             get
244             {
245                 return Application.Current.XamlResources;
246             }
247             set
248             {
249                 Application.Current.XamlResources = value;
250             }
251         }
252
253         /// <summary>
254         /// The StyleName, type string.
255         /// The value indicates DALi style name defined in json theme file.
256         /// </summary>
257         /// <since_tizen> 3 </since_tizen>
258         public string StyleName
259         {
260             get
261             {
262                 return (string)GetValue(StyleNameProperty);
263             }
264             set
265             {
266                 SetValue(StyleNameProperty, value);
267                 NotifyPropertyChanged();
268             }
269         }
270
271         /// <summary>
272         /// The KeyInputFocus, type bool.
273         /// </summary>
274         [EditorBrowsable(EditorBrowsableState.Never)]
275         public bool KeyInputFocus
276         {
277             get
278             {
279                 return (bool)GetValue(KeyInputFocusProperty);
280             }
281             set
282             {
283                 SetValue(KeyInputFocusProperty, value);
284                 NotifyPropertyChanged();
285             }
286         }
287
288         /// <summary>
289         /// The mutually exclusive with "backgroundImage" and "background" type Vector4.
290         /// </summary>
291         /// <remarks>
292         /// The property cascade chaining set is possible. For example, this (view.BackgroundColor.X = 0.1f;) is possible.
293         /// </remarks>
294         /// <since_tizen> 3 </since_tizen>
295         public Color BackgroundColor
296         {
297             get
298             {
299                 Color temp = (Color)GetValue(BackgroundColorProperty);
300                 return new Color(OnBackgroundColorChanged, temp.R, temp.G, temp.B, temp.A);
301             }
302             set
303             {
304                 SetValue(BackgroundColorProperty, value);
305                 if (selectorData != null)
306                 {
307                     selectorData.BackgroundImage.Reset(this);
308                     selectorData.BackgroundColor.UpdateIfNeeds(this, value);
309                 }
310                 NotifyPropertyChanged();
311             }
312         }
313
314         /// <summary>
315         /// The mutually exclusive with "backgroundColor" and "background" type Map.
316         /// </summary>
317         /// <since_tizen> 3 </since_tizen>
318         public string BackgroundImage
319         {
320             get
321             {
322                 return (string)GetValue(BackgroundImageProperty);
323             }
324             set
325             {
326                 SetValue(BackgroundImageProperty, value);
327                 if (selectorData != null)
328                 {
329                     selectorData.BackgroundColor.Reset(this);
330                     selectorData.BackgroundImage.UpdateIfNeeds(this, value);
331                 }
332                 NotifyPropertyChanged();
333             }
334         }
335
336         /// <summary>
337         /// Get or set the border of background image.
338         /// </summary>
339         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
340         [EditorBrowsable(EditorBrowsableState.Never)]
341         public Rectangle BackgroundImageBorder
342         {
343             get
344             {
345                 return (Rectangle)GetValue(BackgroundImageBorderProperty);
346             }
347             set
348             {
349                 SetValue(BackgroundImageBorderProperty, value);
350                 selectorData?.BackgroundImageBorder.UpdateIfNeeds(this, value);
351                 NotifyPropertyChanged();
352             }
353         }
354
355         /// <summary>
356         /// The background of view.
357         /// </summary>
358         /// <since_tizen> 3 </since_tizen>
359         public Tizen.NUI.PropertyMap Background
360         {
361             get
362             {
363                 return (PropertyMap)GetValue(BackgroundProperty);
364             }
365             set
366             {
367                 SetValue(BackgroundProperty, value);
368                 NotifyPropertyChanged();
369             }
370         }
371
372         /// <summary>
373         /// Describes a shadow as an image for a View.
374         /// It is null by default.
375         /// </summary>
376         /// <remarks>
377         /// Getter returns copied instance of current shadow.
378         /// </remarks>
379         /// <remarks>
380         /// The mutually exclusive with "BoxShadow".
381         /// </remarks>
382         [EditorBrowsable(EditorBrowsableState.Never)]
383         public ImageShadow ImageShadow
384         {
385             get
386             {
387                 return (ImageShadow)GetValue(ImageShadowProperty);
388             }
389             set
390             {
391                 SetValue(ImageShadowProperty, value);
392                 if (selectorData != null)
393                 {
394                     selectorData.BoxShadow.Reset(this);
395                     selectorData.ImageShadow.UpdateIfNeeds(this, value);
396                 }
397                 NotifyPropertyChanged();
398             }
399         }
400
401         /// <summary>
402         /// Describes a box shaped shadow drawing for a View.
403         /// It is null by default.
404         /// </summary>
405         /// <remarks>
406         /// Gettter returns copied instance of current shadow.
407         /// </remarks>
408         /// <remarks>
409         /// The mutually exclusive with "ImageShadow".
410         /// </remarks>
411         [EditorBrowsable(EditorBrowsableState.Never)]
412         public Shadow BoxShadow
413         {
414             get
415             {
416                 return (Shadow)GetValue(BoxShadowProperty);
417             }
418             set
419             {
420                 SetValue(BoxShadowProperty, value);
421                 if (selectorData != null)
422                 {
423                     selectorData.ImageShadow.Reset(this);
424                     selectorData.BoxShadow.UpdateIfNeeds(this, value);
425                 }
426                 NotifyPropertyChanged();
427             }
428         }
429
430         /// <summary>
431         /// The radius for the rounded corners of the View.
432         /// This will rounds background and shadow edges.
433         /// Note that, an image background (or shadow) may not have rounded corners if it uses a Border property.
434         /// </summary>
435         [EditorBrowsable(EditorBrowsableState.Never)]
436         public float CornerRadius
437         {
438             get
439             {
440                 return (float)GetValue(CornerRadiusProperty);
441             }
442             set
443             {
444                 SetValue(CornerRadiusProperty, value);
445                 selectorData?.CornerRadius.UpdateIfNeeds(this, value);
446                 NotifyPropertyChanged();
447             }
448         }
449
450         /// <summary>
451         /// Whether the CornerRadius property value is relative (percentage [0.0f to 1.0f] of the view size) or absolute (in world units).
452         /// It is absolute by default.
453         /// When the policy is relative, the corner radius is relative to the smaller of the view's width and height.
454         /// </summary>
455         [EditorBrowsable(EditorBrowsableState.Never)]
456         public VisualTransformPolicyType CornerRadiusPolicy
457         {
458             get => (VisualTransformPolicyType)GetValue(CornerRadiusPolicyProperty);
459             set => SetValue(CornerRadiusPolicyProperty, value);
460         }
461
462         /// <summary>
463         /// The current state of the view.
464         /// </summary>
465         /// <since_tizen> 3 </since_tizen>
466         public States State
467         {
468             get
469             {
470                 return (States)GetValue(StateProperty);
471             }
472             set
473             {
474                 SetValue(StateProperty, value);
475                 NotifyPropertyChanged();
476             }
477         }
478
479         /// <summary>
480         /// The current sub state of the view.
481         /// </summary>
482         /// <since_tizen> 3 </since_tizen>
483         public States SubState
484         {
485             get
486             {
487                 return (States)GetValue(SubStateProperty);
488             }
489             set
490             {
491                 SetValue(SubStateProperty, value);
492                 NotifyPropertyChanged();
493             }
494         }
495
496         /// <summary>
497         /// Displays a tooltip
498         /// </summary>
499         /// <since_tizen> 3 </since_tizen>
500         public Tizen.NUI.PropertyMap Tooltip
501         {
502             get
503             {
504                 return (PropertyMap)GetValue(TooltipProperty);
505             }
506             set
507             {
508                 SetValue(TooltipProperty, value);
509                 NotifyPropertyChanged();
510             }
511         }
512
513         /// <summary>
514         /// Displays a tooltip as a text.
515         /// </summary>
516         /// <since_tizen> 3 </since_tizen>
517         public string TooltipText
518         {
519             get
520             {
521                 using (var propertyValue = GetProperty(Property.TOOLTIP))
522                 {
523                     if (propertyValue != null && propertyValue.Get(out string retrivedValue))
524                     {
525                         return retrivedValue;
526                     }
527                     NUILog.Error($"[ERROR] Fail to get TooltipText! Return error MSG (error to get TooltipText)!");
528                     return "error to get TooltipText";
529                 }
530             }
531             set
532             {
533                 var temp = new Tizen.NUI.PropertyValue(value);
534                 SetProperty(View.Property.TOOLTIP, temp);
535                 temp.Dispose();
536                 NotifyPropertyChanged();
537             }
538         }
539
540         /// <summary>
541         /// The Child property of FlexContainer.<br />
542         /// The proportion of the free space in the container, the flex item will receive.<br />
543         /// If all items in the container set this property, their sizes will be proportional to the specified flex factor.<br />
544         /// </summary>
545         /// <since_tizen> 3 </since_tizen>
546         [Obsolete("Deprecated in API8, will be removed in API10.")]
547         public float Flex
548         {
549             get
550             {
551                 return (float)GetValue(FlexProperty);
552             }
553             set
554             {
555                 SetValue(FlexProperty, value);
556                 NotifyPropertyChanged();
557             }
558         }
559
560         /// <summary>
561         /// The Child property of FlexContainer.<br />
562         /// The alignment of the flex item along the cross axis, which, if set, overides the default alignment for all items in the container.<br />
563         /// </summary>
564         /// <since_tizen> 3 </since_tizen>
565         [Obsolete("Deprecated in API8, will be removed in API10.")]
566         public int AlignSelf
567         {
568             get
569             {
570                 return (int)GetValue(AlignSelfProperty);
571             }
572             set
573             {
574                 SetValue(AlignSelfProperty, value);
575                 NotifyPropertyChanged();
576             }
577         }
578
579         /// <summary>
580         /// The Child property of FlexContainer.<br />
581         /// The space around the flex item.<br />
582         /// </summary>
583         /// <remarks>
584         /// The property cascade chaining set is possible. For example, this (view.FlexMargin.X = 0.1f;) is possible.
585         /// </remarks>
586         /// <since_tizen> 3 </since_tizen>
587         [Obsolete("Deprecated in API8, will be removed in API10.")]
588         public Vector4 FlexMargin
589         {
590             get
591             {
592                 Vector4 temp = (Vector4)GetValue(FlexMarginProperty);
593                 return new Vector4(OnFlexMarginChanged, temp.X, temp.Y, temp.Z, temp.W);
594             }
595             set
596             {
597                 SetValue(FlexMarginProperty, value);
598                 NotifyPropertyChanged();
599             }
600         }
601
602         /// <summary>
603         /// The top-left cell this child occupies, if not set, the first available cell is used.
604         /// </summary>
605         /// <remarks>
606         /// The property cascade chaining set is possible. For example, this (view.CellIndex.X = 0.1f;) is possible.
607         /// </remarks>
608         /// <since_tizen> 3 </since_tizen>
609         public Vector2 CellIndex
610         {
611             get
612             {
613                 Vector2 temp = (Vector2)GetValue(CellIndexProperty);
614                 return new Vector2(OnCellIndexChanged, temp.X, temp.Y);
615             }
616             set
617             {
618                 SetValue(CellIndexProperty, value);
619                 NotifyPropertyChanged();
620             }
621         }
622
623         /// <summary>
624         /// The number of rows this child occupies, if not set, the default value is 1.
625         /// </summary>
626         /// <since_tizen> 3 </since_tizen>
627         public float RowSpan
628         {
629             get
630             {
631                 return (float)GetValue(RowSpanProperty);
632             }
633             set
634             {
635                 SetValue(RowSpanProperty, value);
636                 NotifyPropertyChanged();
637             }
638         }
639
640         /// <summary>
641         /// The number of columns this child occupies, if not set, the default value is 1.
642         /// </summary>
643         /// <since_tizen> 3 </since_tizen>
644         public float ColumnSpan
645         {
646             get
647             {
648                 return (float)GetValue(ColumnSpanProperty);
649             }
650             set
651             {
652                 SetValue(ColumnSpanProperty, value);
653                 NotifyPropertyChanged();
654             }
655         }
656
657         /// <summary>
658         /// The horizontal alignment of this child inside the cells, if not set, the default value is 'left'.
659         /// </summary>
660         /// <since_tizen> 3 </since_tizen>
661         public Tizen.NUI.HorizontalAlignmentType CellHorizontalAlignment
662         {
663             get
664             {
665                 return (HorizontalAlignmentType)GetValue(CellHorizontalAlignmentProperty);
666             }
667             set
668             {
669                 SetValue(CellHorizontalAlignmentProperty, value);
670                 NotifyPropertyChanged();
671             }
672         }
673
674         /// <summary>
675         /// The vertical alignment of this child inside the cells, if not set, the default value is 'top'.
676         /// </summary>
677         /// <since_tizen> 3 </since_tizen>
678         public Tizen.NUI.VerticalAlignmentType CellVerticalAlignment
679         {
680             get
681             {
682                 return (VerticalAlignmentType)GetValue(CellVerticalAlignmentProperty);
683             }
684             set
685             {
686                 SetValue(CellVerticalAlignmentProperty, value);
687                 NotifyPropertyChanged();
688             }
689         }
690
691         /// <summary>
692         /// The left focusable view.<br />
693         /// This will return null if not set.<br />
694         /// This will also return null if the specified left focusable view is not on a window.<br />
695         /// </summary>
696         /// <since_tizen> 3 </since_tizen>
697         public View LeftFocusableView
698         {
699             // As native side will be only storing IDs so need a logic to convert View to ID and vice-versa.
700             get
701             {
702                 return (View)GetValue(LeftFocusableViewProperty);
703             }
704             set
705             {
706                 SetValue(LeftFocusableViewProperty, value);
707                 NotifyPropertyChanged();
708             }
709         }
710
711         /// <summary>
712         /// The right focusable view.<br />
713         /// This will return null if not set.<br />
714         /// This will also return null if the specified right focusable view is not on a window.<br />
715         /// </summary>
716         /// <since_tizen> 3 </since_tizen>
717         public View RightFocusableView
718         {
719             // As native side will be only storing IDs so need a logic to convert View to ID and vice-versa.
720             get
721             {
722                 return (View)GetValue(RightFocusableViewProperty);
723             }
724             set
725             {
726                 SetValue(RightFocusableViewProperty, value);
727                 NotifyPropertyChanged();
728             }
729         }
730
731         /// <summary>
732         /// The up focusable view.<br />
733         /// This will return null if not set.<br />
734         /// This will also return null if the specified up focusable view is not on a window.<br />
735         /// </summary>
736         /// <since_tizen> 3 </since_tizen>
737         public View UpFocusableView
738         {
739             // As native side will be only storing IDs so need a logic to convert View to ID and vice-versa.
740             get
741             {
742                 return (View)GetValue(UpFocusableViewProperty);
743             }
744             set
745             {
746                 SetValue(UpFocusableViewProperty, value);
747                 NotifyPropertyChanged();
748             }
749         }
750
751         /// <summary>
752         /// The down focusable view.<br />
753         /// This will return null if not set.<br />
754         /// This will also return null if the specified down focusable view is not on a window.<br />
755         /// </summary>
756         /// <since_tizen> 3 </since_tizen>
757         public View DownFocusableView
758         {
759             // As native side will be only storing IDs so need a logic to convert View to ID and vice-versa.
760             get
761             {
762                 return (View)GetValue(DownFocusableViewProperty);
763             }
764             set
765             {
766                 SetValue(DownFocusableViewProperty, value);
767                 NotifyPropertyChanged();
768             }
769         }
770
771         /// <summary>
772         /// Whether the view should be focusable by keyboard navigation.
773         /// </summary>
774         /// <since_tizen> 3 </since_tizen>
775         public bool Focusable
776         {
777             set
778             {
779                 SetValue(FocusableProperty, value);
780                 NotifyPropertyChanged();
781             }
782             get
783             {
784                 return (bool)GetValue(FocusableProperty);
785             }
786         }
787
788         /// <summary>
789         ///  Retrieves the position of the view.<br />
790         ///  The coordinates are relative to the view's parent.<br />
791         /// </summary>
792         /// <since_tizen> 3 </since_tizen>
793         public Position CurrentPosition
794         {
795             get
796             {
797                 return GetCurrentPosition();
798             }
799         }
800
801         /// <summary>
802         /// Sets the size of a view for the width and the height.<br />
803         /// Geometry can be scaled to fit within this area.<br />
804         /// This does not interfere with the view's scale factor.<br />
805         /// The views default depth is the minimum of width and height.<br />
806         /// </summary>
807         /// <remarks>
808         /// This NUI object (Size2D) typed property can be configured by multiple cascade setting. <br />
809         /// For example, this code ( view.Size2D.Width = 100; view.Size2D.Height = 100; ) is equivalent to this ( view.Size2D = new Size2D(100, 100); ). <br />
810         /// </remarks>
811         /// <since_tizen> 3 </since_tizen>
812         public Size2D Size2D
813         {
814             get
815             {
816                 Size2D temp = (Size2D)GetValue(Size2DProperty);
817                 int width = temp.Width;
818                 int height = temp.Height;
819
820                 if (this.Layout == null)
821                 {
822                     if (width < 0) { width = 0; }
823                     if (height < 0) { height = 0; }
824                 }
825
826                 return new Size2D(OnSize2DChanged, width, height);
827             }
828             set
829             {
830                 SetValue(Size2DProperty, value);
831
832                 NotifyPropertyChanged();
833             }
834         }
835
836         /// <summary>
837         ///  Retrieves the size of the view.<br />
838         ///  The coordinates are relative to the view's parent.<br />
839         /// </summary>
840         /// <since_tizen> 3 </since_tizen>
841         public Size2D CurrentSize
842         {
843             get
844             {
845                 return GetCurrentSize();
846             }
847         }
848
849         /// <summary>
850         /// Retrieves and sets the view's opacity.<br />
851         /// </summary>
852         /// <since_tizen> 3 </since_tizen>
853         public float Opacity
854         {
855             get
856             {
857                 return (float)GetValue(OpacityProperty);
858             }
859             set
860             {
861                 SetValue(OpacityProperty, value);
862                 selectorData?.Opacity.UpdateIfNeeds(this, value);
863                 NotifyPropertyChanged();
864             }
865         }
866
867         /// <summary>
868         /// Sets the position of the view for X and Y.<br />
869         /// By default, sets the position vector between the parent origin and the pivot point (default).<br />
870         /// If the position inheritance is disabled, sets the world position.<br />
871         /// </summary>
872         /// <remarks>
873         /// This NUI object (Position2D) typed property can be configured by multiple cascade setting. <br />
874         /// For example, this code ( view.Position2D.X = 100; view.Position2D.Y = 100; ) is equivalent to this ( view.Position2D = new Position2D(100, 100); ). <br />
875         /// </remarks>
876         /// <since_tizen> 3 </since_tizen>
877         public Position2D Position2D
878         {
879             get
880             {
881                 Position2D temp = (Position2D)GetValue(Position2DProperty);
882                 return new Position2D(OnPosition2DChanged, temp.X, temp.Y);
883             }
884             set
885             {
886                 SetValue(Position2DProperty, value);
887                 NotifyPropertyChanged();
888             }
889         }
890
891         /// <summary>
892         /// Retrieves the screen postion of the view.<br />
893         /// </summary>
894         /// <since_tizen> 3 </since_tizen>
895         public Vector2 ScreenPosition
896         {
897             get
898             {
899                 Vector2 temp = new Vector2(0.0f, 0.0f);
900                 var pValue = GetProperty(View.Property.ScreenPosition);
901                 pValue.Get(temp);
902                 pValue.Dispose();
903                 return temp;
904             }
905         }
906
907         /// <summary>
908         /// Determines whether the pivot point should be used to determine the position of the view.
909         /// This is false by default.
910         /// </summary>
911         /// <remarks>If false, then the top-left of the view is used for the position.
912         /// Setting this to false will allow scaling or rotation around the pivot point without affecting the view's position.
913         /// </remarks>
914         /// <since_tizen> 3 </since_tizen>
915         public bool PositionUsesPivotPoint
916         {
917             get
918             {
919                 return (bool)GetValue(PositionUsesPivotPointProperty);
920             }
921             set
922             {
923                 SetValue(PositionUsesPivotPointProperty, value);
924                 NotifyPropertyChanged();
925             }
926         }
927
928         /// <summary>
929         /// Deprecated in API5; Will be removed in API8. Please use PositionUsesPivotPoint instead!
930         /// </summary>
931         /// <since_tizen> 3 </since_tizen>
932         [Obsolete("Deprecated in API5; Will be removed in API8. Please use PositionUsesPivotPoint instead! " +
933             "Like: " +
934             "View view = new View(); " +
935             "view.PivotPoint = PivotPoint.Center; " +
936             "view.PositionUsesPivotPoint = true;" +
937             " Deprecated in API5: Will be removed in API8")]
938         [EditorBrowsable(EditorBrowsableState.Never)]
939         public bool PositionUsesAnchorPoint
940         {
941             get
942             {
943                 bool temp = false;
944                 var pValue = GetProperty(View.Property.PositionUsesAnchorPoint);
945                 pValue.Get(out temp);
946                 pValue.Dispose();
947                 return temp;
948             }
949             set
950             {
951                 var temp = new Tizen.NUI.PropertyValue(value);
952                 SetProperty(View.Property.PositionUsesAnchorPoint, temp);
953                 temp.Dispose();
954                 NotifyPropertyChanged();
955             }
956         }
957
958         /// <summary>
959         /// Queries whether the view is connected to the stage.<br />
960         /// When a view is connected, it will be directly or indirectly parented to the root view.<br />
961         /// </summary>
962         /// <since_tizen> 3 </since_tizen>
963         public bool IsOnWindow
964         {
965             get
966             {
967                 return OnWindow();
968             }
969         }
970
971         /// <summary>
972         /// Gets the depth in the hierarchy for the view.
973         /// </summary>
974         /// <since_tizen> 3 </since_tizen>
975         public int HierarchyDepth
976         {
977             get
978             {
979                 return GetHierarchyDepth();
980             }
981         }
982
983         /// <summary>
984         /// Sets the sibling order of the view so the depth position can be defined within the same parent.
985         /// </summary>
986         /// <remarks>
987         /// Note the initial value is 0. SiblingOrder should be bigger than 0 or equal to 0.
988         /// Raise, Lower, RaiseToTop, LowerToBottom, RaiseAbove, and LowerBelow will override the sibling order.
989         /// The values set by this property will likely change.
990         /// </remarks>
991         /// <since_tizen> 3 </since_tizen>
992         public int SiblingOrder
993         {
994             get
995             {
996                 return (int)GetValue(SiblingOrderProperty);
997             }
998             set
999             {
1000                 SetValue(SiblingOrderProperty, value);
1001
1002                 LayoutGroup layout = Layout as LayoutGroup;
1003                 layout?.ChangeLayoutSiblingOrder(value);
1004
1005                 NotifyPropertyChanged();
1006             }
1007         }
1008
1009         /// <summary>
1010         /// Returns the natural size of the view.
1011         /// </summary>
1012         /// <remarks>
1013         /// Deriving classes stipulate the natural size and by default a view has a zero natural size.
1014         /// </remarks>
1015         /// <since_tizen> 5 </since_tizen>
1016         public Vector3 NaturalSize
1017         {
1018             get
1019             {
1020                 Vector3 ret = new Vector3(Interop.Actor.GetNaturalSize(SwigCPtr), true);
1021                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw new InvalidOperationException("FATAL: get Exception", NDalicPINVOKE.SWIGPendingException.Retrieve());
1022                 return ret;
1023             }
1024         }
1025
1026         /// <summary>
1027         /// Returns the natural size (Size2D) of the view.
1028         /// </summary>
1029         /// <remarks>
1030         /// Deriving classes stipulate the natural size and by default a view has a zero natural size.
1031         /// </remarks>
1032         /// <since_tizen> 4 </since_tizen>
1033         public Size2D NaturalSize2D
1034         {
1035             get
1036             {
1037                 Vector3 temp = new Vector3(Interop.Actor.GetNaturalSize(SwigCPtr), true);
1038                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw new InvalidOperationException("FATAL: get Exception", NDalicPINVOKE.SWIGPendingException.Retrieve());
1039
1040                 Size2D sz = new Size2D((int)temp.Width, (int)temp.Height);
1041                 temp.Dispose();
1042                 return sz;
1043             }
1044         }
1045
1046         /// <summary>
1047         /// Gets or sets the origin of a view within its parent's area.<br />
1048         /// 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 />
1049         /// The default parent-origin is ParentOrigin.TopLeft (0.0, 0.0, 0.5).<br />
1050         /// A view's position is the distance between this origin and the view's anchor-point.<br />
1051         /// </summary>
1052         /// <pre>The view has been initialized.</pre>
1053         /// <since_tizen> 3 </since_tizen>
1054         public Position ParentOrigin
1055         {
1056             get
1057             {
1058                 Position tmp = (Position)GetValue(ParentOriginProperty);
1059                 return new Position(OnParentOriginChanged, tmp.X, tmp.Y, tmp.Z);
1060             }
1061             set
1062             {
1063                 SetValue(ParentOriginProperty, value);
1064                 NotifyPropertyChanged();
1065             }
1066         }
1067
1068         /// <summary>
1069         /// Gets or sets the anchor-point of a view.<br />
1070         /// 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 />
1071         /// The default pivot point is PivotPoint.Center (0.5, 0.5, 0.5).<br />
1072         /// A view position is the distance between its parent-origin and this anchor-point.<br />
1073         /// A view's orientation is the rotation from its default orientation, the rotation is centered around its anchor-point.<br />
1074         /// <pre>The view has been initialized.</pre>
1075         /// </summary>
1076         /// <remarks>
1077         /// The property cascade chaining set is possible. For example, this (view.PivotPoint.X = 0.1f;) is possible.
1078         /// </remarks>
1079         /// <since_tizen> 3 </since_tizen>
1080         public Position PivotPoint
1081         {
1082             get
1083             {
1084                 Position tmp = (Position)GetValue(PivotPointProperty);
1085                 return new Position(OnPivotPointChanged, tmp.X, tmp.Y, tmp.Z);
1086             }
1087             set
1088             {
1089                 SetValue(PivotPointProperty, value);
1090                 NotifyPropertyChanged();
1091             }
1092         }
1093
1094         /// <summary>
1095         /// Gets or sets the size width of the view.
1096         /// </summary>
1097         /// <remarks>
1098         /// <para>
1099         /// Animatable - This property can be animated using <c>Animation</c> class.
1100         /// </para>
1101         /// </remarks>
1102         /// <since_tizen> 3 </since_tizen>
1103         public float SizeWidth
1104         {
1105             get
1106             {
1107                 return (float)GetValue(SizeWidthProperty);
1108             }
1109             set
1110             {
1111                 SetValue(SizeWidthProperty, value);
1112                 NotifyPropertyChanged();
1113             }
1114         }
1115
1116         /// <summary>
1117         /// Gets or sets the size height of the view.
1118         /// </summary>
1119         /// <remarks>
1120         /// <para>
1121         /// Animatable - This property can be animated using <c>Animation</c> class.
1122         /// </para>
1123         /// </remarks>
1124         /// <since_tizen> 3 </since_tizen>
1125         public float SizeHeight
1126         {
1127             get
1128             {
1129                 return (float)GetValue(SizeHeightProperty);
1130             }
1131             set
1132             {
1133                 SetValue(SizeHeightProperty, value);
1134                 NotifyPropertyChanged();
1135             }
1136         }
1137
1138         /// <summary>
1139         /// Gets or sets the position of the view.<br />
1140         /// By default, sets the position vector between the parent origin and pivot point (default).<br />
1141         /// If the position inheritance is disabled, sets the world position.<br />
1142         /// </summary>
1143         /// <remarks>
1144         /// <para>
1145         /// Animatable - This property can be animated using <c>Animation</c> class.
1146         /// </para>
1147         /// The property cascade chaining set is possible. For example, this (view.Position.X = 1.0f;) is possible.
1148         /// </remarks>
1149         /// <since_tizen> 3 </since_tizen>
1150         public Position Position
1151         {
1152             get
1153             {
1154                 Position tmp = (Position)GetValue(PositionProperty);
1155                 return new Position(OnPositionChanged, tmp.X, tmp.Y, tmp.Z);
1156             }
1157             set
1158             {
1159                 SetValue(PositionProperty, value);
1160                 NotifyPropertyChanged();
1161             }
1162         }
1163
1164         /// <summary>
1165         /// Gets or sets the position X of the view.
1166         /// </summary>
1167         /// <remarks>
1168         /// <para>
1169         /// Animatable - This property can be animated using <c>Animation</c> class.
1170         /// </para>
1171         /// </remarks>
1172         /// <since_tizen> 3 </since_tizen>
1173         public float PositionX
1174         {
1175             get
1176             {
1177                 return (float)GetValue(PositionXProperty);
1178             }
1179             set
1180             {
1181                 SetValue(PositionXProperty, value);
1182                 NotifyPropertyChanged();
1183             }
1184         }
1185
1186         /// <summary>
1187         /// Gets or sets the position Y of the view.
1188         /// </summary>
1189         /// <remarks>
1190         /// <para>
1191         /// Animatable - This property can be animated using <c>Animation</c> class.
1192         /// </para>
1193         /// </remarks>
1194         /// <since_tizen> 3 </since_tizen>
1195         public float PositionY
1196         {
1197             get
1198             {
1199                 return (float)GetValue(PositionYProperty);
1200             }
1201             set
1202             {
1203                 SetValue(PositionYProperty, value);
1204                 NotifyPropertyChanged();
1205             }
1206         }
1207
1208         /// <summary>
1209         /// Gets or sets the position Z of the view.
1210         /// </summary>
1211         /// <remarks>
1212         /// <para>
1213         /// Animatable - This property can be animated using <c>Animation</c> class.
1214         /// </para>
1215         /// </remarks>
1216         /// <since_tizen> 3 </since_tizen>
1217         public float PositionZ
1218         {
1219             get
1220             {
1221                 return (float)GetValue(PositionZProperty);
1222             }
1223             set
1224             {
1225                 SetValue(PositionZProperty, value);
1226                 NotifyPropertyChanged();
1227             }
1228         }
1229
1230         /// <summary>
1231         /// Gets or sets the world position of the view.
1232         /// </summary>
1233         /// <since_tizen> 3 </since_tizen>
1234         public Vector3 WorldPosition
1235         {
1236             get
1237             {
1238                 Vector3 temp = new Vector3(0.0f, 0.0f, 0.0f);
1239                 var pValue = GetProperty(View.Property.WorldPosition);
1240                 pValue.Get(temp);
1241                 pValue.Dispose();
1242                 return temp;
1243             }
1244         }
1245
1246         /// <summary>
1247         /// Gets or sets the orientation of the view.<br />
1248         /// The view's orientation is the rotation from its default orientation, and the rotation is centered around its anchor-point.<br />
1249         /// </summary>
1250         /// <remarks>
1251         /// <para>
1252         /// This is an asynchronous method.
1253         /// </para>
1254         /// <para>
1255         /// Animatable - This property can be animated using <c>Animation</c> class.
1256         /// </para>
1257         /// </remarks>
1258         /// <since_tizen> 3 </since_tizen>
1259         public Rotation Orientation
1260         {
1261             get
1262             {
1263                 return (Rotation)GetValue(OrientationProperty);
1264             }
1265             set
1266             {
1267                 SetValue(OrientationProperty, value);
1268                 NotifyPropertyChanged();
1269             }
1270         }
1271
1272         /// <summary>
1273         /// Gets or sets the world orientation of the view.<br />
1274         /// </summary>
1275         /// <since_tizen> 3 </since_tizen>
1276         public Rotation WorldOrientation
1277         {
1278             get
1279             {
1280                 Rotation temp = new Rotation();
1281                 var pValue = GetProperty(View.Property.WorldOrientation);
1282                 pValue.Get(temp);
1283                 pValue.Dispose();
1284                 return temp;
1285             }
1286         }
1287
1288         /// <summary>
1289         /// Gets or sets the scale factor applied to the view.<br />
1290         /// </summary>
1291         /// <remarks>
1292         /// <para>
1293         /// Animatable - This property can be animated using <c>Animation</c> class.
1294         /// </para>
1295         /// The property cascade chaining set is possible. For example, this (view.Scale.X = 0.1f;) is possible.
1296         /// </remarks>
1297         /// <since_tizen> 3 </since_tizen>
1298         public Vector3 Scale
1299         {
1300             get
1301             {
1302                 Vector3 temp = (Vector3)GetValue(ScaleProperty);
1303                 return new Vector3(OnScaleChanged, temp.X, temp.Y, temp.Z);
1304             }
1305             set
1306             {
1307                 SetValue(ScaleProperty, value);
1308                 NotifyPropertyChanged();
1309             }
1310         }
1311
1312         /// <summary>
1313         /// Gets or sets the scale X factor applied to the view.
1314         /// </summary>
1315         /// <remarks>
1316         /// <para>
1317         /// Animatable - This property can be animated using <c>Animation</c> class.
1318         /// </para>
1319         /// </remarks>
1320         /// <since_tizen> 3 </since_tizen>
1321         public float ScaleX
1322         {
1323             get
1324             {
1325                 return (float)GetValue(ScaleXProperty);
1326             }
1327             set
1328             {
1329                 SetValue(ScaleXProperty, value);
1330                 NotifyPropertyChanged();
1331             }
1332         }
1333
1334         /// <summary>
1335         /// Gets or sets the scale Y factor applied to the view.
1336         /// </summary>
1337         /// <remarks>
1338         /// <para>
1339         /// Animatable - This property can be animated using <c>Animation</c> class.
1340         /// </para>
1341         /// </remarks>
1342         /// <since_tizen> 3 </since_tizen>
1343         public float ScaleY
1344         {
1345             get
1346             {
1347                 return (float)GetValue(ScaleYProperty);
1348             }
1349             set
1350             {
1351                 SetValue(ScaleYProperty, value);
1352                 NotifyPropertyChanged();
1353             }
1354         }
1355
1356         /// <summary>
1357         /// Gets or sets the scale Z factor applied to the view.
1358         /// </summary>
1359         /// <remarks>
1360         /// <para>
1361         /// Animatable - This property can be animated using <c>Animation</c> class.
1362         /// </para>
1363         /// </remarks>
1364         /// <since_tizen> 3 </since_tizen>
1365         public float ScaleZ
1366         {
1367             get
1368             {
1369                 return (float)GetValue(ScaleZProperty);
1370             }
1371             set
1372             {
1373                 SetValue(ScaleZProperty, value);
1374                 NotifyPropertyChanged();
1375             }
1376         }
1377
1378         /// <summary>
1379         /// Gets the world scale of the view.
1380         /// </summary>
1381         /// <since_tizen> 3 </since_tizen>
1382         public Vector3 WorldScale
1383         {
1384             get
1385             {
1386                 Vector3 temp = new Vector3(0.0f, 0.0f, 0.0f);
1387                 var pValue = GetProperty(View.Property.WorldScale);
1388                 pValue.Get(temp);
1389                 pValue.Dispose();
1390                 return temp;
1391             }
1392         }
1393
1394         /// <summary>
1395         /// Retrieves the visibility flag of the view.
1396         /// </summary>
1397         /// <remarks>
1398         /// <para>
1399         /// If the view is not visible, then the view and its children will not be rendered.
1400         /// 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.
1401         /// </para>
1402         /// <para>
1403         /// Animatable - This property can be animated using <c>Animation</c> class.
1404         /// </para>
1405         /// </remarks>
1406         /// <since_tizen> 3 </since_tizen>
1407         public bool Visibility
1408         {
1409             get
1410             {
1411                 bool temp = false;
1412                 var pValue = GetProperty(View.Property.VISIBLE);
1413                 pValue.Get(out temp);
1414                 pValue.Dispose();
1415                 return temp;
1416             }
1417         }
1418
1419         /// <summary>
1420         /// Gets the view's world color.
1421         /// </summary>
1422         /// <since_tizen> 3 </since_tizen>
1423         public Vector4 WorldColor
1424         {
1425             get
1426             {
1427                 Vector4 temp = new Vector4(0.0f, 0.0f, 0.0f, 0.0f);
1428                 var pValue = GetProperty(View.Property.WorldColor);
1429                 pValue.Get(temp);
1430                 pValue.Dispose();
1431                 return temp;
1432             }
1433         }
1434
1435         /// <summary>
1436         /// Gets or sets the view's name.
1437         /// </summary>
1438         /// <since_tizen> 3 </since_tizen>
1439         public string Name
1440         {
1441             get
1442             {
1443                 return (string)GetValue(NameProperty);
1444             }
1445             set
1446             {
1447                 SetValue(NameProperty, value);
1448                 NotifyPropertyChanged();
1449             }
1450         }
1451
1452         /// <summary>
1453         /// Get the number of children held by the view.
1454         /// </summary>
1455         /// <since_tizen> 3 </since_tizen>
1456         public new uint ChildCount
1457         {
1458             get
1459             {
1460                 return Convert.ToUInt32(Children.Count);
1461             }
1462         }
1463
1464         /// <summary>
1465         /// Gets the view's ID.
1466         /// Readonly
1467         /// </summary>
1468         /// <since_tizen> 3 </since_tizen>
1469         public uint ID
1470         {
1471             get
1472             {
1473                 return GetId();
1474             }
1475         }
1476
1477         /// <summary>
1478         /// Gets or sets the status of whether the view should emit touch or hover signals.
1479         /// </summary>
1480         /// <since_tizen> 3 </since_tizen>
1481         public bool Sensitive
1482         {
1483             get
1484             {
1485                 return (bool)GetValue(SensitiveProperty);
1486             }
1487             set
1488             {
1489                 SetValue(SensitiveProperty, value);
1490                 NotifyPropertyChanged();
1491             }
1492         }
1493
1494         /// <summary>
1495         /// 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.
1496         /// </summary>
1497         /// <since_tizen> 3 </since_tizen>
1498         public bool LeaveRequired
1499         {
1500             get
1501             {
1502                 return (bool)GetValue(LeaveRequiredProperty);
1503             }
1504             set
1505             {
1506                 SetValue(LeaveRequiredProperty, value);
1507                 NotifyPropertyChanged();
1508             }
1509         }
1510
1511         /// <summary>
1512         /// Gets or sets the status of whether a child view inherits it's parent's orientation.
1513         /// </summary>
1514         /// <since_tizen> 3 </since_tizen>
1515         public bool InheritOrientation
1516         {
1517             get
1518             {
1519                 return (bool)GetValue(InheritOrientationProperty);
1520             }
1521             set
1522             {
1523                 SetValue(InheritOrientationProperty, value);
1524                 NotifyPropertyChanged();
1525             }
1526         }
1527
1528         /// <summary>
1529         /// Gets or sets the status of whether a child view inherits it's parent's scale.
1530         /// </summary>
1531         /// <since_tizen> 3 </since_tizen>
1532         public bool InheritScale
1533         {
1534             get
1535             {
1536                 return (bool)GetValue(InheritScaleProperty);
1537             }
1538             set
1539             {
1540                 SetValue(InheritScaleProperty, value);
1541                 NotifyPropertyChanged();
1542             }
1543         }
1544
1545         /// <summary>
1546         /// Gets or sets the status of how the view and its children should be drawn.<br />
1547         /// Not all views are renderable, but DrawMode can be inherited from any view.<br />
1548         /// 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 />
1549         /// If DrawMode.Overlay2D is used, the view and its children will be drawn as a 2D overlay.<br />
1550         /// Overlay views are drawn in a separate pass, after all non-overlay views within the layer.<br />
1551         /// For overlay views, the drawing order is with respect to tree levels of views, and depth-testing will not be used.<br />
1552         /// </summary>
1553         /// <since_tizen> 3 </since_tizen>
1554         public DrawModeType DrawMode
1555         {
1556             get
1557             {
1558                 return (DrawModeType)GetValue(DrawModeProperty);
1559             }
1560             set
1561             {
1562                 SetValue(DrawModeProperty, value);
1563                 NotifyPropertyChanged();
1564             }
1565         }
1566
1567         /// <summary>
1568         /// Gets or sets the relative to parent size factor of the view.<br />
1569         /// This factor is only used when ResizePolicyType is set to either: ResizePolicyType.SizeRelativeToParent or ResizePolicyType.SizeFixedOffsetFromParent.<br />
1570         /// This view's size is set to the view's size multiplied by or added to this factor, depending on ResizePolicyType.<br />
1571         /// </summary>
1572         /// <remarks>
1573         /// The property cascade chaining set is possible. For example, this (view.DecorationBoundingBox.X = 0.1f;) is possible.
1574         /// </remarks>
1575         /// <since_tizen> 3 </since_tizen>
1576         public Vector3 SizeModeFactor
1577         {
1578             get
1579             {
1580                 Vector3 temp = (Vector3)GetValue(SizeModeFactorProperty);
1581                 return new Vector3(OnSizeModeFactorChanged, temp.X, temp.Y, temp.Z);
1582             }
1583             set
1584             {
1585                 SetValue(SizeModeFactorProperty, value);
1586                 NotifyPropertyChanged();
1587             }
1588         }
1589
1590         /// <summary>
1591         /// Gets or sets the width resize policy to be used.
1592         /// </summary>
1593         /// <since_tizen> 3 </since_tizen>
1594         public ResizePolicyType WidthResizePolicy
1595         {
1596             get
1597             {
1598                 return (ResizePolicyType)GetValue(WidthResizePolicyProperty);
1599             }
1600             set
1601             {
1602                 SetValue(WidthResizePolicyProperty, value);
1603                 NotifyPropertyChanged();
1604             }
1605         }
1606
1607         /// <summary>
1608         /// Gets or sets the height resize policy to be used.
1609         /// </summary>
1610         /// <since_tizen> 3 </since_tizen>
1611         public ResizePolicyType HeightResizePolicy
1612         {
1613             get
1614             {
1615                 return (ResizePolicyType)GetValue(HeightResizePolicyProperty);
1616             }
1617             set
1618             {
1619                 SetValue(HeightResizePolicyProperty, value);
1620                 NotifyPropertyChanged();
1621             }
1622         }
1623
1624         /// <summary>
1625         /// Gets or sets the policy to use when setting size with size negotiation.<br />
1626         /// Defaults to SizeScalePolicyType.UseSizeSet.<br />
1627         /// </summary>
1628         /// <since_tizen> 3 </since_tizen>
1629         public SizeScalePolicyType SizeScalePolicy
1630         {
1631             get
1632             {
1633                 return (SizeScalePolicyType)GetValue(SizeScalePolicyProperty);
1634             }
1635             set
1636             {
1637                 SetValue(SizeScalePolicyProperty, value);
1638                 NotifyPropertyChanged();
1639             }
1640         }
1641
1642         /// <summary>
1643         ///  Gets or sets the status of whether the width size is dependent on the height size.
1644         /// </summary>
1645         /// <since_tizen> 3 </since_tizen>
1646         public bool WidthForHeight
1647         {
1648             get
1649             {
1650                 return (bool)GetValue(WidthForHeightProperty);
1651             }
1652             set
1653             {
1654                 SetValue(WidthForHeightProperty, value);
1655                 NotifyPropertyChanged();
1656             }
1657         }
1658
1659         /// <summary>
1660         /// Gets or sets the status of whether the height size is dependent on the width size.
1661         /// </summary>
1662         /// <since_tizen> 3 </since_tizen>
1663         public bool HeightForWidth
1664         {
1665             get
1666             {
1667                 return (bool)GetValue(HeightForWidthProperty);
1668             }
1669             set
1670             {
1671                 SetValue(HeightForWidthProperty, value);
1672                 NotifyPropertyChanged();
1673             }
1674         }
1675
1676         /// <summary>
1677         /// Gets or sets the padding for use in layout.
1678         /// </summary>
1679         /// <remarks>
1680         /// The property cascade chaining set is possible. For example, this (view.Padding.X = 0.1f;) is possible.
1681         /// </remarks>
1682         /// <since_tizen> 5 </since_tizen>
1683         public Extents Padding
1684         {
1685             get
1686             {
1687                 // If View has a Layout then padding in stored in the base Layout class
1688                 if (Layout != null)
1689                 {
1690                     return Layout.Padding;
1691                 }
1692                 else
1693                 {
1694                     Extents temp = (Extents)GetValue(PaddingProperty);
1695                     return new Extents(OnPaddingChanged, temp.Start, temp.End, temp.Top, temp.Bottom);
1696                 }
1697                 // Two return points to prevent creating a zeroed Extent native object before assignment
1698             }
1699             set
1700             {
1701                 Extents padding = value;
1702                 if (Layout != null)
1703                 {
1704                     // Layout set so store Padding in LayoutItem instead of in View.
1705                     // If View stores the Padding value then Legacy Size Negotiation will overwrite
1706                     // the position and sizes measure in the Layouting.
1707                     Layout.Padding = value;
1708                     // If Layout is a LayoutItem then it could be a View that handles it's own padding.
1709                     // Let the View keeps it's padding.  Still store Padding in Layout to reduce code paths.
1710                     if (typeof(LayoutGroup).IsAssignableFrom(Layout.GetType())) // If a Layout container of some kind.
1711                     {
1712                         padding = new Extents(0, 0, 0, 0); // Reset value stored in View.
1713                     }
1714                 }
1715
1716                 SetValue(PaddingProperty, padding);
1717                 NotifyPropertyChanged();
1718             }
1719         }
1720
1721         /// <summary>
1722         /// Gets or sets the minimum size the view can be assigned in size negotiation.
1723         /// </summary>
1724         /// <exception cref="ArgumentNullException"> Thrown when value is null. </exception>
1725         /// <remarks>
1726         /// The property cascade chaining set is possible. For example, this (view.MinimumSize.Width = 1;) is possible.
1727         /// </remarks>
1728         /// <since_tizen> 3 </since_tizen>
1729         public Size2D MinimumSize
1730         {
1731             get
1732             {
1733                 Size2D tmp = (Size2D)GetValue(MinimumSizeProperty);
1734                 return new Size2D(OnMinimumSizeChanged, tmp.Width, tmp.Height);
1735             }
1736             set
1737             {
1738                 if (value == null)
1739                 {
1740                     throw new ArgumentNullException(nameof(value));
1741                 }
1742                 if (layout != null)
1743                 {
1744                     // Note: it only works if minimum size is >= than natural size.
1745                     // To force the size it should be done through the width&height spec or Size2D.
1746                     layout.MinimumWidth = new Tizen.NUI.LayoutLength(value.Width);
1747                     layout.MinimumHeight = new Tizen.NUI.LayoutLength(value.Height);
1748                     layout.RequestLayout();
1749                 }
1750                 SetValue(MinimumSizeProperty, value);
1751                 NotifyPropertyChanged();
1752             }
1753         }
1754
1755         /// <summary>
1756         /// Gets or sets the maximum size the view can be assigned in size negotiation.
1757         /// </summary>
1758         /// <remarks>
1759         /// The property cascade chaining set is possible. For example, this (view.MaximumSize.Width = 1;) is possible.
1760         /// </remarks>
1761         /// <since_tizen> 3 </since_tizen>
1762         public Size2D MaximumSize
1763         {
1764             get
1765             {
1766                 Size2D tmp = (Size2D)GetValue(MaximumSizeProperty);
1767                 return new Size2D(OnMaximumSizeChanged, tmp.Width, tmp.Height);
1768             }
1769             set
1770             {
1771                 // We don't have Layout.Maximum(Width|Height) so we cannot apply it to layout.
1772                 // MATCH_PARENT spec + parent container size can be used to limit
1773                 if (layout != null)
1774                 {
1775                     layout.RequestLayout();
1776                 }
1777                 SetValue(MaximumSizeProperty, value);
1778                 NotifyPropertyChanged();
1779             }
1780         }
1781
1782         /// <summary>
1783         /// Gets or sets whether a child view inherits it's parent's position.<br />
1784         /// Default is to inherit.<br />
1785         /// 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 />
1786         /// </summary>
1787         /// <since_tizen> 3 </since_tizen>
1788         public bool InheritPosition
1789         {
1790             get
1791             {
1792                 return (bool)GetValue(InheritPositionProperty);
1793             }
1794             set
1795             {
1796                 SetValue(InheritPositionProperty, value);
1797                 NotifyPropertyChanged();
1798             }
1799         }
1800
1801         /// <summary>
1802         /// Gets or sets the clipping behavior (mode) of it's children.
1803         /// </summary>
1804         /// <since_tizen> 3 </since_tizen>
1805         public ClippingModeType ClippingMode
1806         {
1807             get
1808             {
1809                 return (ClippingModeType)GetValue(ClippingModeProperty);
1810             }
1811             set
1812             {
1813                 SetValue(ClippingModeProperty, value);
1814                 NotifyPropertyChanged();
1815             }
1816         }
1817
1818         /// <summary>
1819         /// Gets the number of renderers held by the view.
1820         /// </summary>
1821         /// <since_tizen> 3 </since_tizen>
1822         public uint RendererCount
1823         {
1824             get
1825             {
1826                 return GetRendererCount();
1827             }
1828         }
1829
1830         /// <summary>
1831         /// Deprecated in API5; Will be removed in API8. Please use PivotPoint instead!
1832         /// </summary>
1833         /// <remarks>
1834         /// The property cascade chaining set is possible. For example, this (view.AnchorPoint.X = 0.1f;) is possible.
1835         /// </remarks>
1836         /// <since_tizen> 3 </since_tizen>
1837         [Obsolete("Deprecated in API5; Will be removed in API8. Please use PivotPoint instead! " +
1838             "Like: " +
1839             "View view = new View(); " +
1840             "view.PivotPoint = PivotPoint.Center; " +
1841             "view.PositionUsesPivotPoint = true;")]
1842         [EditorBrowsable(EditorBrowsableState.Never)]
1843         public Position AnchorPoint
1844         {
1845             get
1846             {
1847                 Position temp = new Position(0.0f, 0.0f, 0.0f);
1848                 var pValue = GetProperty(View.Property.AnchorPoint);
1849                 pValue.Get(temp);
1850                 pValue.Dispose();
1851                 Position ret = new Position(OnAnchorPointChanged, temp.X, temp.Y, temp.Z);
1852                 temp.Dispose();
1853                 return ret;
1854             }
1855             set
1856             {
1857                 var temp = new Tizen.NUI.PropertyValue(value);
1858                 SetProperty(View.Property.AnchorPoint, temp);
1859                 temp.Dispose();
1860                 NotifyPropertyChanged();
1861             }
1862         }
1863
1864         /// <summary>
1865         /// Sets the size of a view for the width, the height and the depth.<br />
1866         /// Geometry can be scaled to fit within this area.<br />
1867         /// This does not interfere with the view's scale factor.<br />
1868         /// The views default depth is the minimum of width and height.<br />
1869         /// </summary>
1870         /// <remarks>
1871         /// <para>
1872         /// Animatable - This property can be animated using <c>Animation</c> class.
1873         /// </para>
1874         /// The property cascade chaining set is possible. For example, this (view.Size.Width = 1.0f;) is possible.
1875         /// </remarks>
1876         /// <since_tizen> 5 </since_tizen>
1877         public Size Size
1878         {
1879             get
1880             {
1881                 Size tmp = (Size)GetValue(SizeProperty);
1882                 return new Size(OnSizeChanged, tmp.Width, tmp.Height, tmp.Depth);
1883             }
1884             set
1885             {
1886                 SetValue(SizeProperty, value);
1887                 NotifyPropertyChanged();
1888             }
1889         }
1890
1891         /// <summary>
1892         /// Deprecated in API5; Will be removed in API8. Please use 'Container GetParent() for derived class' instead!
1893         /// </summary>
1894         /// <since_tizen> 3 </since_tizen>
1895         [Obsolete("Deprecated in API5; Will be removed in API8. Please use 'Container GetParent() for derived class' instead! " +
1896             "Like: " +
1897             "Container parent =  view.GetParent(); " +
1898             "View view = parent as View;")]
1899         [EditorBrowsable(EditorBrowsableState.Never)]
1900         public new View Parent
1901         {
1902             get
1903             {
1904                 View ret;
1905                 IntPtr cPtr = Interop.Actor.GetParent(SwigCPtr);
1906                 HandleRef CPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
1907                 BaseHandle basehandle = Registry.GetManagedBaseHandleFromNativePtr(CPtr.Handle);
1908
1909                 if (basehandle is Layer layer)
1910                 {
1911                     ret = new View(Layer.getCPtr(layer).Handle, false);
1912                     NUILog.Error("This Parent property is deprecated, shoud do not be used");
1913                 }
1914                 else
1915                 {
1916                     ret = basehandle as View;
1917                 }
1918
1919                 Interop.BaseHandle.DeleteBaseHandle(CPtr);
1920                 CPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
1921
1922                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw new InvalidOperationException("FATAL: get Exception", NDalicPINVOKE.SWIGPendingException.Retrieve());
1923                 return ret;
1924             }
1925         }
1926
1927         /// <summary>
1928         /// Gets/Sets whether inherit parent's the layout Direction.
1929         /// </summary>
1930         /// <since_tizen> 4 </since_tizen>
1931         public bool InheritLayoutDirection
1932         {
1933             get
1934             {
1935                 return (bool)GetValue(InheritLayoutDirectionProperty);
1936             }
1937             set
1938             {
1939                 SetValue(InheritLayoutDirectionProperty, value);
1940                 NotifyPropertyChanged();
1941             }
1942         }
1943
1944         /// <summary>
1945         /// Gets/Sets the layout Direction.
1946         /// </summary>
1947         /// <since_tizen> 4 </since_tizen>
1948         public ViewLayoutDirectionType LayoutDirection
1949         {
1950             get
1951             {
1952                 return (ViewLayoutDirectionType)GetValue(LayoutDirectionProperty);
1953             }
1954             set
1955             {
1956                 SetValue(LayoutDirectionProperty, value);
1957                 NotifyPropertyChanged();
1958                 layout?.RequestLayout();
1959             }
1960         }
1961
1962         /// <summary>
1963         /// Gets or sets the Margin for use in layout.
1964         /// </summary>
1965         /// <remarks>
1966         /// Margin property is supported by Layout algorithms and containers.
1967         /// Please Set Layout if you want to use Margin property.
1968         /// The property cascade chaining set is possible. For example, this (view.Margin.X = 0.1f;) is possible.
1969         /// </remarks>
1970         /// <since_tizen> 4 </since_tizen>
1971         public Extents Margin
1972         {
1973             get
1974             {
1975                 // If View has a Layout then margin is stored in Layout.
1976                 if (Layout != null)
1977                 {
1978                     return Layout.Margin;
1979                 }
1980                 else
1981                 {
1982                     // If Layout not set then return margin stored in View.
1983                     Extents temp = (Extents)GetValue(MarginProperty);
1984                     return new Extents(OnMarginChanged, temp.Start, temp.End, temp.Top, temp.Bottom);
1985                 }
1986                 // Two return points to prevent creating a zeroed Extent native object before assignment
1987             }
1988             set
1989             {
1990                 if (Layout != null)
1991                 {
1992                     // Layout set so store Margin in LayoutItem instead of View.
1993                     // If View stores the Margin too then the Legacy Size Negotiation will
1994                     // overwrite the position and size values measured in the Layouting.
1995                     Layout.Margin = value;
1996                     SetValue(MarginProperty, new Extents(0, 0, 0, 0));
1997                     layout?.RequestLayout();
1998                 }
1999                 else
2000                 {
2001                     SetValue(MarginProperty, value);
2002                 }
2003                 NotifyPropertyChanged();
2004                 layout?.RequestLayout();
2005             }
2006         }
2007
2008         ///<summary>
2009         /// The required policy for this dimension, LayoutParamPolicies enum or exact value.
2010         ///</summary>
2011         /// <since_tizen> 6 </since_tizen>
2012         public int WidthSpecification
2013         {
2014             get
2015             {
2016                 return widthPolicy;
2017             }
2018             set
2019             {
2020                 if (value == widthPolicy)
2021                     return;
2022
2023                 widthPolicy = value;
2024                 if (widthPolicy >= 0)
2025                 {
2026                     if (heightPolicy >= 0) // Policy an exact value
2027                     {
2028                         // Create Size2D only both _widthPolicy and _heightPolicy are set.
2029                         Size2D = new Size2D(widthPolicy, heightPolicy);
2030                     }
2031                 }
2032                 layout?.RequestLayout();
2033             }
2034         }
2035
2036         ///<summary>
2037         /// The required policy for this dimension, LayoutParamPolicies enum or exact value.
2038         ///</summary>
2039         /// <since_tizen> 6 </since_tizen>
2040         public int HeightSpecification
2041         {
2042             get
2043             {
2044                 return heightPolicy;
2045             }
2046             set
2047             {
2048                 if (value == heightPolicy)
2049                     return;
2050
2051                 heightPolicy = value;
2052                 if (heightPolicy >= 0)
2053                 {
2054                     if (widthPolicy >= 0) // Policy an exact value
2055                     {
2056                         // Create Size2D only both _widthPolicy and _heightPolicy are set.
2057                         Size2D = new Size2D(widthPolicy, heightPolicy);
2058                     }
2059                 }
2060                 layout?.RequestLayout();
2061             }
2062         }
2063
2064         ///<summary>
2065         /// Gets the List of transitions for this View.
2066         ///</summary>
2067         /// <since_tizen> 6 </since_tizen>
2068         public Dictionary<TransitionCondition, TransitionList> LayoutTransitions
2069         {
2070             get
2071             {
2072                 if (layoutTransitions == null)
2073                 {
2074                     layoutTransitions = new Dictionary<TransitionCondition, TransitionList>();
2075                 }
2076                 return layoutTransitions;
2077             }
2078         }
2079
2080         ///<summary>
2081         /// Set a layout transitions for this View.
2082         ///</summary>
2083         /// <exception cref="ArgumentNullException"> Thrown when value is null. </exception>
2084         /// <remarks>
2085         /// Use LayoutTransitions to receive a collection of LayoutTransitions set on the View.
2086         /// </remarks>
2087         /// <since_tizen> 6 </since_tizen>
2088         public LayoutTransition LayoutTransition
2089         {
2090             get
2091             {
2092                 return layoutTransition;
2093             }
2094             set
2095             {
2096                 if (value == null)
2097                 {
2098                     throw new global::System.ArgumentNullException(nameof(value));
2099                 }
2100                 if (layoutTransitions == null)
2101                 {
2102                     layoutTransitions = new Dictionary<TransitionCondition, TransitionList>();
2103                 }
2104
2105                 LayoutTransitionsHelper.AddTransitionForCondition(layoutTransitions, value.Condition, value, true);
2106
2107                 AttachTransitionsToChildren(value);
2108
2109                 layoutTransition = value;
2110             }
2111         }
2112
2113         /// <summary>
2114         /// Deprecated in API5; Will be removed in API8. Please use Padding instead.
2115         /// </summary>
2116         /// <remarks>
2117         /// The property cascade chaining set is possible. For example, this (view.DecorationBoundingBox.X = 0.1f;) is possible.
2118         /// </remarks>
2119         /// <since_tizen> 4 </since_tizen>
2120         [Obsolete("Deprecated in API5; Will be removed in API8. Please use Padding instead.")]
2121         [EditorBrowsable(EditorBrowsableState.Never)]
2122         public Extents PaddingEX
2123         {
2124             get
2125             {
2126                 Extents temp = new Extents(0, 0, 0, 0);
2127                 var pValue = GetProperty(View.Property.PADDING);
2128                 pValue.Get(temp);
2129                 pValue.Dispose();
2130                 Extents ret = new Extents(OnPaddingEXChanged, temp.Start, temp.End, temp.Top, temp.Bottom);
2131                 temp.Dispose();
2132                 return ret;
2133             }
2134             set
2135             {
2136                 var temp = new Tizen.NUI.PropertyValue(value);
2137                 SetProperty(View.Property.PADDING, temp);
2138                 temp.Dispose();
2139                 NotifyPropertyChanged();
2140                 layout?.RequestLayout();
2141             }
2142         }
2143
2144         /// <summary>
2145         /// The Color of View. This is an RGBA value.
2146         /// </summary>
2147         /// <remarks>
2148         /// <para>
2149         /// Animatable - This property can be animated using <c>Animation</c> class.
2150         /// </para>
2151         /// The property cascade chaining set is possible. For example, this (view.Color.X = 0.1f;) is possible.
2152         /// </remarks>
2153         /// This will be public opened in tizen_5.5 after ACR done. Before ACR, need to be hidden as inhouse API.
2154         [EditorBrowsable(EditorBrowsableState.Never)]
2155         public Color Color
2156         {
2157             get
2158             {
2159                 Color temp = (Color)GetValue(ColorProperty);
2160                 return new Color(OnColorChanged, temp.R, temp.G, temp.B, temp.A);
2161             }
2162             set
2163             {
2164                 SetValue(ColorProperty, value);
2165                 selectorData?.Color.UpdateIfNeeds(this, value);
2166                 NotifyPropertyChanged();
2167             }
2168         }
2169
2170         /// <summary>
2171         /// Set the layout on this View. Replaces any existing Layout.
2172         /// </summary>
2173         /// <since_tizen> 6 </since_tizen>
2174         public LayoutItem Layout
2175         {
2176             get
2177             {
2178                 return layout;
2179             }
2180             set
2181             {
2182                 // Do nothing if layout provided is already set on this View.
2183                 if (value == layout)
2184                 {
2185                     return;
2186                 }
2187
2188                 LayoutingDisabled = false;
2189                 layoutSet = true;
2190
2191                 // If new layout being set already has a owner then that owner receives a replacement default layout.
2192                 // First check if the layout to be set already has a owner.
2193                 if (value?.Owner != null)
2194                 {
2195                     // Previous owner of the layout gets a default layout as a replacement.
2196                     value.Owner.Layout = new AbsoluteLayout();
2197
2198                     // Copy Margin and Padding to replacement LayoutGroup.
2199                     if (value.Owner.Layout != null)
2200                     {
2201                         value.Owner.Layout.Margin = value.Margin;
2202                         value.Owner.Layout.Padding = value.Padding;
2203                     }
2204                 }
2205
2206                 // Copy Margin and Padding to new layout being set or restore padding and margin back to
2207                 // View if no replacement. Previously margin and padding values would have been moved from
2208                 // the View to the layout.
2209                 if (layout != null) // Existing layout
2210                 {
2211                     if (value != null)
2212                     {
2213                         // Existing layout being replaced so copy over margin and padding values.
2214                         value.Margin = layout.Margin;
2215                         value.Padding = layout.Padding;
2216                     }
2217                     else
2218                     {
2219                         // Layout not being replaced so restore margin and padding to View.
2220                         SetValue(MarginProperty, layout.Margin);
2221                         SetValue(PaddingProperty, layout.Padding);
2222                         NotifyPropertyChanged();
2223                     }
2224                 }
2225                 else
2226                 {
2227                     // First Layout to be added to the View hence copy
2228
2229                     // Do not try to set Margins or Padding on a null Layout (when a layout is being removed from a View)
2230                     if (value != null)
2231                     {
2232                         if (Margin.Top != 0 || Margin.Bottom != 0 || Margin.Start != 0 || Margin.End != 0)
2233                         {
2234                             // If View already has a margin set then store it in Layout instead.
2235                             value.Margin = Margin;
2236                             SetValue(MarginProperty, new Extents(0, 0, 0, 0));
2237                             NotifyPropertyChanged();
2238                         }
2239
2240                         if (Padding.Top != 0 || Padding.Bottom != 0 || Padding.Start != 0 || Padding.End != 0)
2241                         {
2242                             // If View already has a padding set then store it in Layout instead.
2243                             value.Padding = Padding;
2244                             SetValue(PaddingProperty, new Extents(0, 0, 0, 0));
2245                             NotifyPropertyChanged();
2246                         }
2247                     }
2248                 }
2249
2250                 // Remove existing layout from it's parent layout group.
2251                 layout?.Unparent();
2252
2253                 value.SetPositionByLayout = !excludeLayouting;
2254
2255                 // Set layout to this view
2256                 SetLayout(value);
2257             }
2258         }
2259
2260         /// <summary>
2261         /// The weight of the View, used to share available space in a layout with siblings.
2262         /// </summary>
2263         /// <since_tizen> 6 </since_tizen>
2264         public float Weight
2265         {
2266             get
2267             {
2268                 return weight;
2269             }
2270             set
2271             {
2272                 weight = value;
2273                 layout?.RequestLayout();
2274             }
2275         }
2276
2277         /// <summary>
2278         ///  Whether to load the BackgroundImage synchronously.
2279         ///  If not specified, the default is false, i.e. the BackgroundImage is loaded asynchronously.
2280         ///  Note: For Normal Quad images only.
2281         /// </summary>
2282         /// This will be public opened in tizen_5.5 after ACR done. Before ACR, need to be hidden as inhouse API.
2283         [EditorBrowsable(EditorBrowsableState.Never)]
2284         public bool BackgroundImageSynchronosLoading
2285         {
2286             get
2287             {
2288                 return backgroundImageSynchronosLoading;
2289             }
2290             set
2291             {
2292                 backgroundImageSynchronosLoading = value;
2293
2294                 string bgUrl = null;
2295                 var pValue = Background.Find(ImageVisualProperty.URL);
2296                 pValue?.Get(out bgUrl);
2297                 pValue?.Dispose();
2298
2299                 if (!string.IsNullOrEmpty(bgUrl))
2300                 {
2301                     PropertyMap bgMap = this.Background;
2302                     var temp = new PropertyValue(backgroundImageSynchronosLoading);
2303                     bgMap.Add("synchronousLoading", temp);
2304                     temp.Dispose();
2305                     Background = bgMap;
2306                 }
2307             }
2308         }
2309
2310         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
2311         [EditorBrowsable(EditorBrowsableState.Never)]
2312         public Vector2 UpdateSizeHint
2313         {
2314             get
2315             {
2316                 return (Vector2)GetValue(UpdateSizeHintProperty);
2317             }
2318             set
2319             {
2320                 SetValue(UpdateSizeHintProperty, value);
2321                 NotifyPropertyChanged();
2322             }
2323         }
2324
2325         /// <summary>
2326         /// Enable/Disable ControlState propagation for children.
2327         /// It is false by default.
2328         /// If the View needs to share ControlState with descendants, please set it true.
2329         /// Please note that, changing the value will also changes children's EnableControlStatePropagation value recursively.
2330         /// </summary>
2331         [EditorBrowsable(EditorBrowsableState.Never)]
2332         public bool EnableControlStatePropagation
2333         {
2334             get => controlStatePropagation;
2335             set
2336             {
2337                 controlStatePropagation = value;
2338
2339                 foreach (View child in Children)
2340                 {
2341                     child.EnableControlStatePropagation = value;
2342                 }
2343             }
2344         }
2345
2346         /// <summary>
2347         /// If this property is set to true, the View can have a touch related ControlState (such as Pressed) when touch.
2348         /// By default, it is false in View, true in Control.
2349         /// Note that if the value is true, the View will be a touch receptor.
2350         /// </summary>
2351         [EditorBrowsable(EditorBrowsableState.Never)]
2352         public bool EnableControlState
2353         {
2354             get
2355             {
2356                 return (bool)GetValue(EnableControlStateProperty);
2357             }
2358             set
2359             {
2360                 SetValue(EnableControlStateProperty, value);
2361             }
2362         }
2363
2364         /// <summary>
2365         /// Whether the actor grab all touches even if touch leaves its boundary.
2366         /// </summary>
2367         /// <returns>true, if it grab all touch after start</returns>
2368         [EditorBrowsable(EditorBrowsableState.Never)]
2369         public bool GrabTouchAfterLeave
2370         {
2371             get
2372             {
2373                 bool temp = false;
2374                 var pValue = GetProperty(View.Property.CaptureAllTouchAfterStart);
2375                 pValue.Get(out temp);
2376                 pValue.Dispose();
2377                 return temp;
2378             }
2379             set
2380             {
2381                 var temp = new Tizen.NUI.PropertyValue(value);
2382                 SetProperty(View.Property.CaptureAllTouchAfterStart, temp);
2383                 temp.Dispose();
2384                 NotifyPropertyChanged();
2385             }
2386         }
2387
2388         /// <summary>
2389         /// Determines which blend equation will be used to render renderers of this actor.
2390         /// </summary>
2391         /// <returns>blend equation enum currently assigned</returns>
2392         /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API.
2393         [EditorBrowsable(EditorBrowsableState.Never)]
2394         public BlendEquationType BlendEquation
2395         {
2396             get
2397             {
2398                 int temp = 0;
2399                 var pValue = GetProperty(View.Property.BlendEquation);
2400                 pValue.Get(out temp);
2401                 pValue.Dispose();
2402                 return (BlendEquationType)temp;
2403             }
2404             set
2405             {
2406                 var temp = new Tizen.NUI.PropertyValue((int)value);
2407                 SetProperty(View.Property.BlendEquation, temp);
2408                 temp.Dispose();
2409                 NotifyPropertyChanged();
2410             }
2411         }
2412
2413         /// <summary>
2414         /// If the value is true, the View will change its style as the theme changes.
2415         /// It is false by default, but turned to true when setting StyleName (by setting property or using specified constructor).
2416         /// </summary>
2417         [EditorBrowsable(EditorBrowsableState.Never)]
2418         public bool ThemeChangeSensitive
2419         {
2420             get => (bool)GetValue(ThemeChangeSensitiveProperty);
2421             set => SetValue(ThemeChangeSensitiveProperty, value);
2422         }
2423
2424         /// <summary>
2425         /// Create Style, it is abstract function and must be override.
2426         /// </summary>
2427         [EditorBrowsable(EditorBrowsableState.Never)]
2428         protected virtual ViewStyle CreateViewStyle()
2429         {
2430             return new ViewStyle();
2431         }
2432
2433         /// <summary>
2434         /// Called after the View's ControlStates changed.
2435         /// </summary>
2436         /// <param name="controlStateChangedInfo">The information including state changed variables.</param>
2437         [EditorBrowsable(EditorBrowsableState.Never)]
2438         protected virtual void OnControlStateChanged(ControlStateChangedEventArgs controlStateChangedInfo)
2439         {
2440         }
2441
2442         /// <summary>
2443         /// </summary>
2444         [EditorBrowsable(EditorBrowsableState.Never)]
2445         protected virtual void OnThemeChanged(object sender, ThemeChangedEventArgs e)
2446         {
2447             UpdateStyle();
2448         }
2449
2450         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
2451         [EditorBrowsable(EditorBrowsableState.Never)]
2452         public virtual void ApplyStyle(ViewStyle viewStyle)
2453         {
2454             if (null == viewStyle || this.viewStyle == viewStyle) return;
2455
2456             this.viewStyle = viewStyle;
2457
2458             Dictionary<string, BindableProperty> bindablePropertyOfView;
2459             Type viewType = GetType();
2460
2461             Dictionary<string, BindableProperty> bindablePropertyOfStyle;
2462             Type styleType = viewStyle.GetType();
2463
2464             BindableProperty.GetBindablePropertysOfType(viewType, out bindablePropertyOfView);
2465             BindableProperty.GetBindablePropertysOfType(styleType, out bindablePropertyOfStyle);
2466
2467             if (null != bindablePropertyOfView && null != bindablePropertyOfStyle)
2468             {
2469                 foreach (KeyValuePair<string, BindableProperty> keyValuePair in bindablePropertyOfStyle)
2470                 {
2471                     BindableProperty viewProperty;
2472                     bindablePropertyOfView.TryGetValue(keyValuePair.Key, out viewProperty);
2473
2474                     if (null != viewProperty && viewProperty != StyleNameProperty)
2475                     {
2476                         object value = viewStyle.GetValue(keyValuePair.Value);
2477
2478                         if (null != value)
2479                         {
2480                             SetValue(viewProperty, value);
2481                         }
2482                     }
2483                 }
2484             }
2485         }
2486
2487         /// <summary>
2488         /// Used to restore the transition.
2489         /// </summary>
2490         [EditorBrowsable(EditorBrowsableState.Never)]
2491         public IList<Transition> TransitionList
2492         {
2493             get;
2494         } = new List<Transition>();
2495     }
2496 }